Methods Summary |
---|
public void | bind(javax.naming.Name name, java.lang.Object obj, javax.naming.directory.Attributes attrs)
DirContextNamePair res = getTargetContext(name);
res.getDirContext().bind(res.getName(), obj, attrs);
|
public void | bind(java.lang.String name, java.lang.Object obj, javax.naming.directory.Attributes attrs)
DirContextStringPair res = getTargetContext(name);
res.getDirContext().bind(res.getString(), obj, attrs);
|
public javax.naming.directory.DirContext | createSubcontext(javax.naming.Name name, javax.naming.directory.Attributes attrs)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().createSubcontext(res.getName(), attrs);
|
public javax.naming.directory.DirContext | createSubcontext(java.lang.String name, javax.naming.directory.Attributes attrs)
DirContextStringPair res = getTargetContext(name);
return
res.getDirContext().createSubcontext(res.getString(), attrs);
|
public javax.naming.directory.Attributes | getAttributes(java.lang.String name)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().getAttributes(res.getString());
|
public javax.naming.directory.Attributes | getAttributes(java.lang.String name, java.lang.String[] attrIds)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().getAttributes(res.getString(), attrIds);
|
public javax.naming.directory.Attributes | getAttributes(javax.naming.Name name)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().getAttributes(res.getName());
|
public javax.naming.directory.Attributes | getAttributes(javax.naming.Name name, java.lang.String[] attrIds)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().getAttributes(res.getName(), attrIds);
|
public javax.naming.directory.DirContext | getSchema(java.lang.String name)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().getSchema(res.getString());
|
public javax.naming.directory.DirContext | getSchema(javax.naming.Name name)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().getSchema(res.getName());
|
public javax.naming.directory.DirContext | getSchemaClassDefinition(java.lang.String name)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().getSchemaClassDefinition(res.getString());
|
public javax.naming.directory.DirContext | getSchemaClassDefinition(javax.naming.Name name)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().getSchemaClassDefinition(res.getName());
|
protected javax.naming.spi.DirContextNamePair | getTargetContext(javax.naming.Name name)
if (cpe.getResolvedObj() == null)
throw (NamingException)cpe.fillInStackTrace();
Context ctx = NamingManager.getContext(cpe.getResolvedObj(),
cpe.getAltName(),
cpe.getAltNameCtx(),
env);
if (ctx == null)
throw (NamingException)cpe.fillInStackTrace();
if (ctx instanceof DirContext)
return new DirContextNamePair((DirContext)ctx, name);
if (ctx instanceof Resolver) {
Resolver res = (Resolver)ctx;
ResolveResult rr = res.resolveToClass(name, DirContext.class);
// Reached a DirContext; return result.
DirContext dctx = (DirContext)rr.getResolvedObj();
return (new DirContextNamePair(dctx, rr.getRemainingName()));
}
// Resolve all the way using lookup(). This may allow the operation
// to succeed if it doesn't require the penultimate context.
Object ultimate = ctx.lookup(name);
if (ultimate instanceof DirContext) {
return (new DirContextNamePair((DirContext)ultimate,
new CompositeName()));
}
throw (NamingException)cpe.fillInStackTrace();
|
protected javax.naming.spi.DirContextStringPair | getTargetContext(java.lang.String name)
if (cpe.getResolvedObj() == null)
throw (NamingException)cpe.fillInStackTrace();
Context ctx = NamingManager.getContext(cpe.getResolvedObj(),
cpe.getAltName(),
cpe.getAltNameCtx(),
env);
if (ctx instanceof DirContext)
return new DirContextStringPair((DirContext)ctx, name);
if (ctx instanceof Resolver) {
Resolver res = (Resolver)ctx;
ResolveResult rr = res.resolveToClass(name, DirContext.class);
// Reached a DirContext; return result.
DirContext dctx = (DirContext)rr.getResolvedObj();
Name tmp = rr.getRemainingName();
String remains = (tmp != null) ? tmp.toString() : "";
return (new DirContextStringPair(dctx, remains));
}
// Resolve all the way using lookup(). This may allow the operation
// to succeed if it doesn't require the penultimate context.
Object ultimate = ctx.lookup(name);
if (ultimate instanceof DirContext) {
return (new DirContextStringPair((DirContext)ultimate, ""));
}
throw (NamingException)cpe.fillInStackTrace();
|
public void | modifyAttributes(javax.naming.Name name, javax.naming.directory.ModificationItem[] mods)
DirContextNamePair res = getTargetContext(name);
res.getDirContext().modifyAttributes(res.getName(), mods);
|
public void | modifyAttributes(java.lang.String name, javax.naming.directory.ModificationItem[] mods)
DirContextStringPair res = getTargetContext(name);
res.getDirContext().modifyAttributes(res.getString(), mods);
|
public void | modifyAttributes(javax.naming.Name name, int mod_op, javax.naming.directory.Attributes attrs)
DirContextNamePair res = getTargetContext(name);
res.getDirContext().modifyAttributes(res.getName(), mod_op, attrs);
|
public void | modifyAttributes(java.lang.String name, int mod_op, javax.naming.directory.Attributes attrs)
DirContextStringPair res = getTargetContext(name);
res.getDirContext().modifyAttributes(res.getString(), mod_op, attrs);
|
public void | rebind(javax.naming.Name name, java.lang.Object obj, javax.naming.directory.Attributes attrs)
DirContextNamePair res = getTargetContext(name);
res.getDirContext().rebind(res.getName(), obj, attrs);
|
public void | rebind(java.lang.String name, java.lang.Object obj, javax.naming.directory.Attributes attrs)
DirContextStringPair res = getTargetContext(name);
res.getDirContext().rebind(res.getString(), obj, attrs);
|
public javax.naming.NamingEnumeration | search(javax.naming.Name name, javax.naming.directory.Attributes matchingAttributes, java.lang.String[] attributesToReturn)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().search(res.getName(), matchingAttributes,
attributesToReturn);
|
public javax.naming.NamingEnumeration | search(java.lang.String name, javax.naming.directory.Attributes matchingAttributes, java.lang.String[] attributesToReturn)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().search(res.getString(),
matchingAttributes,
attributesToReturn);
|
public javax.naming.NamingEnumeration | search(javax.naming.Name name, javax.naming.directory.Attributes matchingAttributes)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().search(res.getName(), matchingAttributes);
|
public javax.naming.NamingEnumeration | search(java.lang.String name, javax.naming.directory.Attributes matchingAttributes)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().search(res.getString(),
matchingAttributes);
|
public javax.naming.NamingEnumeration | search(javax.naming.Name name, java.lang.String filter, javax.naming.directory.SearchControls cons)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().search(res.getName(), filter, cons);
|
public javax.naming.NamingEnumeration | search(java.lang.String name, java.lang.String filter, javax.naming.directory.SearchControls cons)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().search(res.getString(), filter, cons);
|
public javax.naming.NamingEnumeration | search(javax.naming.Name name, java.lang.String filterExpr, java.lang.Object[] args, javax.naming.directory.SearchControls cons)
DirContextNamePair res = getTargetContext(name);
return res.getDirContext().search(res.getName(), filterExpr, args,
cons);
|
public javax.naming.NamingEnumeration | search(java.lang.String name, java.lang.String filterExpr, java.lang.Object[] args, javax.naming.directory.SearchControls cons)
DirContextStringPair res = getTargetContext(name);
return res.getDirContext().search(res.getString(), filterExpr, args,
cons);
|