01: /*
02: * CharacterSequence.java
03: *
04: * This file is part of SQL Workbench/J, http://www.sql-workbench.net
05: *
06: * Copyright 2002-2008, Thomas Kellerer
07: * No part of this code maybe reused without the permission of the author
08: *
09: * To contact the author please send an email to: support@sql-workbench.net
10: *
11: */
12: package workbench.interfaces;
13:
14: /**
15: * An interface to get parts of a character source.
16: *
17: * I'm not using CharSequence because I need the {@link #done()} method
18: * to cleanup any resource that were used by the sequence.
19: *
20: * The IteratingParser uses a FileMappedSequence which used NIO
21: * to read the characters and this implementation needs a cleanup
22: * method to close the file handles, which would not be offered by
23: * the CharSequence interface.
24: *
25: * @author support@sql-workbench.net
26: */
27: public interface CharacterSequence extends CharSequence {
28:
29: /**
30: * Release any resources used by the CharacterSequence
31: */
32: void done();
33: }
|