Created
May 20, 2013 19:23
-
-
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
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class CSVCustomerReader implements Reader<CSVRecord, Customer> { | |
public Customer read(CSVRecord source) { | |
// TODO implement me :) | |
return null; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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