01: /*
02: * This is free software, licensed under the Gnu Public License (GPL)
03: * get a copy from <http://www.gnu.org/licenses/gpl.html>
04: *
05: * author: Henner Zeller <H.Zeller@acm.org>
06: */
07: package henplus.importparser;
08:
09: import java.util.Calendar;
10:
11: /**
12: * A Recipient of a value parsed by the TypeParser.
13: */
14: public interface ValueRecipient {
15: void setLong(int fieldNumber, long value) throws Exception;
16:
17: void setString(int fieldNumber, String value) throws Exception;
18:
19: void setDate(int fieldNumber, Calendar cal) throws Exception;
20:
21: /**
22: * Signal the Value Recipient, that a complete row
23: * has been read.
24: *
25: * @return true, if the ValueRecipient has read all
26: * rows and does not want to receive further
27: * rows.
28: */
29: boolean finishRow() throws Exception;
30: }
|