Class FileVerification
java.lang.Object
net.sourceforge.argparse4j.impl.type.FileVerification
Verifies properties of files. This can be used by argument types to add extra validation to the file or directory paths that they accept.
To use it, create an instance, enable the desired verifications and call
verify(ArgumentParser, Argument, File).
- Since:
- 0.8.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanboolean -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleancanExecute(File file) protected booleanprotected booleanprotected booleanprotected booleanisDirectory(File file) protected booleanor()voidverify(ArgumentParser parser, Argument arg, File file)
-
Field Details
-
verifyExists
public boolean verifyExists -
verifyNotExists
public boolean verifyNotExists -
verifyIsFile
public boolean verifyIsFile -
verifyIsDirectory
public boolean verifyIsDirectory -
verifyCanRead
public boolean verifyCanRead -
verifyCanWrite
public boolean verifyCanWrite -
verifyCanWriteParent
public boolean verifyCanWriteParent -
verifyCanCreate
public boolean verifyCanCreate -
verifyCanExecute
public boolean verifyCanExecute -
verifyIsAbsolute
public boolean verifyIsAbsolute
-
-
Constructor Details
-
FileVerification
public FileVerification()
-
-
Method Details
-
or
-
verify
- Throws:
ArgumentParserException
-
exists
-
isDirectory
-
isFile
-
canRead
-
canWrite
-
canExecute
-