org.inria.ns.reflex.modules.io.ldap
Class LDAPFileName

java.lang.Object
  extended by org.apache.commons.vfs.provider.AbstractFileName
      extended by org.apache.commons.vfs.provider.GenericFileName
          extended by org.inria.ns.reflex.modules.io.ldap.LDAPFileName
All Implemented Interfaces:
Comparable, FileName

public class LDAPFileName
extends GenericFileName

LDAPFileName is the file name of an URL which scheme is "ldap", including the query part.

Author:
Philippe Poulard

Field Summary
 
Fields inherited from interface org.apache.commons.vfs.FileName
ROOT_PATH, SEPARATOR, SEPARATOR_CHAR
 
Method Summary
 FileName createName(String absPath)
          Create a new LDAP file name from a path.
static LDAPFileName parseURI(String uri, int defaultPort)
          Return the file name from an XML:DB URI.
 
Methods inherited from class org.apache.commons.vfs.provider.GenericFileName
createName, getDefaultPort, getHostName, getPassword, getPort, getUserName
 
Methods inherited from class org.apache.commons.vfs.provider.AbstractFileName
checkName, compareTo, equals, getBaseName, getDepth, getExtension, getFriendlyURI, getParent, getPath, getPathDecoded, getRelativeName, getRoot, getRootURI, getScheme, getType, getURI, hashCode, isAncestor, isDescendent, isDescendent, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

parseURI

public static LDAPFileName parseURI(String uri,
                                    int defaultPort)
                             throws FileSystemException
Return the file name from an XML:DB URI.

Parameters:
uri - The URI "xmldb:provider://host:port/path".
Returns:
The XMLDBFileName of this URI.
Throws:
FileSystemException - If the URI can't be parsed.

createName

public FileName createName(String absPath)
Create a new LDAP file name from a path.

Parameters:
ldapQuery - The canonicalized LDAP query, /dc=foo,dc=acme,dc=fr??sub?sn=doe.
Returns:
The file name that endorsed the same components as this file name, except the path.
See Also:
org.apache.commons.vfs.provider.AbstractFileName#createName(java.lang.String)