Skip to content

Instantly share code, notes, and snippets.

@britter
Created May 20, 2013 19:23
Show Gist options
  • Save britter/5614747 to your computer and use it in GitHub Desktop.
Save britter/5614747 to your computer and use it in GitHub Desktop.
Definition of a reader interface and a corresponding implementation that reads Customer objects from CSVRecords
public class CSVCustomerReader implements Reader<CSVRecord, Customer> {
public Customer read(CSVRecord source) {
// TODO implement me :)
return null;
}
}
public interface Reader<S, T> {
T read(S source);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment