org.cip4.jdflib.util.file
Class RollingDateFile
java.lang.Object
java.io.File
org.cip4.jdflib.util.file.RollingFile
org.cip4.jdflib.util.file.RollingDateFile
- All Implemented Interfaces:
- Serializable, Comparable<File>
public class RollingDateFile
- extends RollingFile
File that gets a new file whenever time and date changes
- Author:
- rainer prosi
- See Also:
- Serialized Form
| 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, toString, toURI, toURL |
DD
public static final String DD
- See Also:
- Constant Field Values
DDHH
public static final String DDHH
- See Also:
- Constant Field Values
RollingDateFile
public RollingDateFile(String pathname,
String baseName)
- Parameters:
pathname - baseName -
getNewFileName
protected String getNewFileName()
- Overrides:
getNewFileName in class RollingFile
- Returns:
- the file to write, i.e. this
getNewFileName
protected String getNewFileName(long t)
calcPos
protected void calcPos()
- Overrides:
calcPos in class RollingFile
- See Also:
RollingFile.calcPos()
getFormat
public String getFormat()
- Getter for format attribute.
- Returns:
- the format
setFormat
public void setFormat(String format)
- Setter for format attribute used to format the file names
- Parameters:
format - the format to set
getNewFile
public File getNewFile(long t)
- Parameters:
t - the time in milliseconds that applies to this file
- Returns:
- the file to write, null if error occurred
init
public void init(File file)
- initialization routine for a new file
- Parameters:
file -
Copyright © 2013. All Rights Reserved.