@ApplicationScoped public class DefaultFileNameValidator extends Object implements FileNameValidator
Constructor and Description |
---|
DefaultFileNameValidator() |
Modifier and Type | Method and Description |
---|---|
boolean |
accept(Path path)
Indicates if the current parameter path matched the current validator
|
boolean |
accept(String fileName)
Indicates if the current parameter path matched the current validator
|
int |
getPriority()
Defines the validator priority in terms of validator resolution.
|
boolean |
isValid(String value)
Validate the value
|
public int getPriority()
FileNameValidator
getPriority
in interface FileNameValidator
public boolean accept(String fileName)
FileNameValidator
accept
in interface FileNameValidator
fileName
- File name to validate (including extension)public boolean accept(Path path)
FileNameValidator
accept
in interface FileNameValidator
path
- Path to validatepublic boolean isValid(String value)
FileNameValidator
isValid
in interface FileNameValidator
value
- Value to be validatedCopyright © 2012–2019 JBoss by Red Hat. All rights reserved.