public final class PackageValidator extends Object
Modifier and Type | Method and Description |
---|---|
protected static ValidationResult |
checkACHandling(ValidationOptions options,
org.apache.jackrabbit.vault.packaging.VaultPackage pack) |
protected static ValidationResult |
checkDeniedPathInclusion(ValidationOptions options,
org.apache.jackrabbit.vault.packaging.VaultPackage pack) |
protected static ValidationResult |
checkFilter(ValidationOptions options,
WspFilter archiveFilter) |
protected static ValidationResult |
checkForbiddenExtensions(JarFile jarFile,
List<String> forbiddenExtensions) |
protected static ValidationResult |
checkForbiddenFilterRootPrefix(ValidationOptions options,
org.apache.jackrabbit.vault.packaging.VaultPackage pack) |
static org.apache.jackrabbit.vault.fs.api.WorkspaceFilter |
convertToWorkspaceFilter(WspFilter wspFilter) |
protected static boolean |
hasRequiredRules(WspFilter.Root coveringRoot,
WspFilter.Root archiveRoot) |
static ValidationResult |
validate(File file,
ValidationOptions options)
Validates a package file against a workspace filter.
|
protected static ValidationResult |
validatePackage(File file,
ValidationOptions options) |
public static ValidationResult validate(File file, ValidationOptions options)
PackageManager.open(java.io.File, boolean)
4. Call VaultPackage.isValid()
5. Check package WorkspaceFilter
against validation WorkspaceFilter
file
- the package file to be validatedoptions
- the validation optionsprotected static ValidationResult validatePackage(File file, ValidationOptions options)
protected static ValidationResult checkACHandling(ValidationOptions options, org.apache.jackrabbit.vault.packaging.VaultPackage pack)
protected static ValidationResult checkForbiddenFilterRootPrefix(ValidationOptions options, org.apache.jackrabbit.vault.packaging.VaultPackage pack)
protected static ValidationResult checkDeniedPathInclusion(ValidationOptions options, org.apache.jackrabbit.vault.packaging.VaultPackage pack)
protected static ValidationResult checkFilter(ValidationOptions options, WspFilter archiveFilter)
protected static ValidationResult checkForbiddenExtensions(JarFile jarFile, List<String> forbiddenExtensions) throws IOException
IOException
protected static boolean hasRequiredRules(WspFilter.Root coveringRoot, WspFilter.Root archiveRoot)
public static org.apache.jackrabbit.vault.fs.api.WorkspaceFilter convertToWorkspaceFilter(WspFilter wspFilter)
Copyright © 2013-2017. All Rights Reserved.