01: package com.coldcore.coloradoftp.filter;
02:
03: import java.util.Set;
04:
05: /**
06: * Data filter factory (creates all available data filters).
07: *
08: * Filter factories are used to get filters that must be applied to data channels
09: * upon uload or download.
10: *
11: * Commands like TYPE, MODE and STRU use this factory to list all available filters
12: * user can apply to the data channel. When a user wants to make upload or download
13: * the filter applicator applies required filters to server's data channel.
14: *
15: *
16: * ColoradoFTP - The Open Source FTP Server (http://cftp.coldcore.com)
17: */
18: public interface DataFilterFactory {
19:
20: /** List all available filter names (name match command's agrument filter was created for)
21: * @return Filter names (copy of the original set)
22: */
23: public Set<String> listNames();
24:
25: /** Create filter object
26: * @param name Filter name
27: * @return If found then filter object, if filter name exists but no value is
28: * set then NULL (no filter required), otherwise throws an exception
29: */
30: public DataFilter create(String name);
31: }
|