Package org.cip4.jdflib.util.file
Class RollingFile
java.lang.Object
java.io.File
org.cip4.jdflib.util.file.RollingFile
- All Implemented Interfaces:
Serializable,Comparable<File>
- Direct Known Subclasses:
RollingDateFile
- See Also:
-
Field Summary
Fields inherited from class java.io.File
pathSeparator, pathSeparatorChar, separator, separatorChar -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.io.File
canExecute, canRead, canWrite, compareTo, createNewFile, createTempFile, createTempFile, delete, deleteOnExit, equals, exists, getAbsoluteFile, getAbsolutePath, getCanonicalFile, getCanonicalPath, getFreeSpace, getName, getParent, getParentFile, getPath, getTotalSpace, getUsableSpace, hashCode, isAbsolute, isDirectory, isFile, isHidden, lastModified, length, list, list, listFiles, listFiles, listFiles, listRoots, mkdir, mkdirs, renameTo, setExecutable, setExecutable, setLastModified, setReadable, setReadable, setReadOnly, setWritable, setWritable, toPath, toString, toURI, toURL
-
Constructor Details
-
RollingFile
- Parameters:
pathname- the base filenamebaseName- the name of the base file,
if a filename with double "." , e.g. xxx..txt is specified, the algorithm will generate names such as xxx.000001.txt,
if a single "." e.g. xxx.txt is specified, the algorithm will generate names such as xxx000001.txt,
-
-
Method Details
-
calcPos
protected int calcPos()- Returns:
-
readAll
read all matching files from this- Returns:
- array of all matching files
-
getFileExpression
- Returns:
-
getNewFile
- Returns:
- the file to write, null if error occurred
-
getNewFileName
- Returns:
- the file to write, i.e. this
-
setDigits
public void setDigits(int digits) - Parameters:
digits- the digits to set
-