Package dk.netarkivet.common.utils.cdx
Class ARCFilenameCDXRecordFilter
- java.lang.Object
-
- dk.netarkivet.common.utils.cdx.SimpleCDXRecordFilter
-
- dk.netarkivet.common.utils.cdx.ARCFilenameCDXRecordFilter
-
- All Implemented Interfaces:
CDXRecordFilter
,java.io.Serializable
public class ARCFilenameCDXRecordFilter extends SimpleCDXRecordFilter
A filter to use in CDXReader when finding CDXRecords matching a filename-pattern.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ARCFilenameCDXRecordFilter(java.lang.String arcfilenamepattern, java.lang.String filtername)
Class constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getFilenamePattern()
Get the filename pattern used by this filter.boolean
process(CDXRecord cdxrec)
Process one CDXRecord - return true/false.-
Methods inherited from class dk.netarkivet.common.utils.cdx.SimpleCDXRecordFilter
getFilterName
-
-
-
-
Constructor Detail
-
ARCFilenameCDXRecordFilter
public ARCFilenameCDXRecordFilter(java.lang.String arcfilenamepattern, java.lang.String filtername) throws ArgumentNotValid
Class constructor.- Parameters:
arcfilenamepattern
- The filename pattern to be used by this filterfiltername
- The name of this filter- Throws:
ArgumentNotValid
- If any argument are null or an empty string.
-
-
Method Detail
-
getFilenamePattern
public java.lang.String getFilenamePattern()
Get the filename pattern used by this filter.- Returns:
- the filename pattern used by this filter.
-
process
public boolean process(CDXRecord cdxrec)
Description copied from interface:CDXRecordFilter
Process one CDXRecord - return true/false.- Specified by:
process
in interfaceCDXRecordFilter
- Specified by:
process
in classSimpleCDXRecordFilter
- Parameters:
cdxrec
- the CDXRecord to be processed.- Returns:
- true or false on whether the processed CDXRecord is "valid" according to this filter implementation. true means this CDXRecord is valid!
-
-