Posts

Showing posts from 2009

Java Annotations Example

When I design and implement a new API, I always like to make the API easy to use. I was implementing a set of classes for usage in a Tree and a TreeTable. The only thing I wanted the user to implement is a class that defines the Node Data. For the Tree Table case I also needed information on getting the column count and whether the column was editable. My first implementation was to make it part of an interface public interface ColumnData { public void setData(int index, Object value); public Object getData(int index); public String[] getColumn(int index); public boolean isEditable(int index); } The column list and whether it was editable was really static information for the class but I wanted to keep ColumnData as an interface instead of a class, so I created an annotation for defining the column information as show below @Retention(RetentionPolicy.RUNTIME) public @interface ColumnAttributes { public String name(); public boolean editable() default false; } Be...

Scala

Blog on Scala , which is a functional programming language that runs on the JVM

R Programming Language

The R Programming Language is used for Statistics. See Introduction to R for programmers coming for other languages

Good tutorial on Oracle SQL Model

The Oracle SQL Model allows you to do a lot more things in SQL that you would normally have done in PL/SQL. You can find a good tutorial here

Richard Feynman lecture on Physics video

Bill Gates has posted lecture on Physics by Richard Feynman at the Microsoft Research website. You need IE to view these lectures