Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.runtime.jboss.deployer.structure
Class PathPattern

java.lang.Object
  extended by org.nuxeo.runtime.jboss.deployer.structure.PathPattern
Direct Known Subclasses:
PathPattern.CompositePattern, PathPattern.ExactMatchPattern, PathPattern.PrefixPattern, PathPattern.SuffixPattern, PathPattern.WildcardPattern

public abstract class PathPattern
extends Object

All path p[atterns are relative to the deployment root file. Supported patterns are:

Note that only a single wildcard character can be used in a pattern. Also, wildcards can be used only on file names - not on directory path segments. Invalid patterns: dir/*file*.jar *dir/file.jar

Author:
Bogdan Stefanescu

Nested Class Summary
static class PathPattern.CompositePattern
           
static class PathPattern.ExactMatchPattern
           
static class PathPattern.PrefixPattern
           
static class PathPattern.SuffixPattern
           
static class PathPattern.WildcardPattern
           
 
Method Summary
abstract  boolean doMatch(String name)
          Match the name of the given path.
 org.jboss.virtual.VirtualFile findFile(org.jboss.virtual.VirtualFile root)
           
 String findFirstMatchingPath(org.jboss.virtual.VirtualFile root)
           
 PathPattern getNext()
           
 String getPath()
          Get the determined part of the path.
 boolean isExactMatch()
           
 boolean match(String name)
           
static PathPattern parse(String pattern)
           
 void setNext(PathPattern next)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

setNext

public void setNext(PathPattern next)

getNext

public PathPattern getNext()

isExactMatch

public boolean isExactMatch()

getPath

public String getPath()
Get the determined part of the path. For exact match this is the exact file path, for wildcard match this is the exact parent path.


findFile

public org.jboss.virtual.VirtualFile findFile(org.jboss.virtual.VirtualFile root)
                                       throws IOException
Throws:
IOException

findFirstMatchingPath

public String findFirstMatchingPath(org.jboss.virtual.VirtualFile root)
                             throws IOException
Throws:
IOException

match

public boolean match(String name)

doMatch

public abstract boolean doMatch(String name)
Match the name of the given path. (Only name segment is matched).


parse

public static PathPattern parse(String pattern)

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.