public NamingEnumeration listBindings(Name name) throws NamingException { if (name.isEmpty()) { return new NamingContextBindingsEnumeration(list(base).iterator(), this); } VirtualFile entry = treeLookup(name); if (entry == null) throw new NamingException(sm.getString("resources.notFound", name)); return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ @Override protected NamingEnumeration<Binding> doListBindings(String name) throws NamingException { File file = file(name); if (file == null) return null; return new NamingContextBindingsEnumeration(list(file).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ @Override protected NamingEnumeration<Binding> doListBindings(String name) throws NamingException { File file = file(name); if (file == null) return null; return new NamingContextBindingsEnumeration(list(file).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ @Override protected NamingEnumeration<Binding> doListBindings(String name) throws NamingException { File file = file(name); if (file == null) return null; return new NamingContextBindingsEnumeration(list(file).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ public NamingEnumeration listBindings(Name name) throws NamingException { if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) throw new NamingException (MESSAGES.resourceNotFound(name.toString())); return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ public NamingEnumeration listBindings(String name) throws NamingException { File file = file(name); if (file == null) throw new NamingException (MESSAGES.resourceNotFound(name)); return new NamingContextBindingsEnumeration(list(file).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ public NamingEnumeration listBindings(Name name) throws NamingException { if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) throw new NamingException (sm.getString("resources.notFound", name)); return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ public NamingEnumeration listBindings(Name name) throws NamingException { if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) throw new NamingException (MESSAGES.resourceNotFound(name.toString())); return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ public NamingEnumeration listBindings(Name name) throws NamingException { if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) throw new NamingException (sm.getString("resources.notFound", name)); return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param name the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ public NamingEnumeration listBindings(String name) throws NamingException { File file = file(name); if (file == null) throw new NamingException (sm.getString("resources.notFound", name)); return new NamingContextBindingsEnumeration(list(file).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param strName the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ @Override protected NamingEnumeration<Binding> doListBindings(String strName) throws NamingException { Name name = getEscapedJndiName(strName); if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) return null; return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param strName the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ @Override protected NamingEnumeration<Binding> doListBindings(String strName) throws NamingException { Name name = getEscapedJndiName(strName); if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) return null; return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
/** * Enumerates the names bound in the named context, along with the * objects bound to them. The contents of any subcontexts are not * included. * <p> * If a binding is added to or removed from this context, its effect on * an enumeration previously returned is undefined. * * @param strName the name of the context to list * @return an enumeration of the bindings in this context. * Each element of the enumeration is of type Binding. * @exception NamingException if a naming exception is encountered */ @Override protected NamingEnumeration<Binding> doListBindings(String strName) throws NamingException { Name name = getEscapedJndiName(strName); if (name.isEmpty()) return new NamingContextBindingsEnumeration(list(entries).iterator(), this); Entry entry = treeLookup(name); if (entry == null) return null; return new NamingContextBindingsEnumeration(list(entry).iterator(), this); }
name = name.getSuffix(1); if (name.isEmpty()) { return new NamingContextBindingsEnumeration(bindings.values().iterator(), this);
name = name.getSuffix(1); if (name.isEmpty()) { return new NamingContextBindingsEnumeration(bindings.values().iterator(), this);
name = name.getSuffix(1); if (name.isEmpty()) { return new NamingContextBindingsEnumeration(bindings.values().iterator(), this);
name = name.getSuffix(1); if (name.isEmpty()) { return new NamingContextBindingsEnumeration(bindings.values().iterator(), this);
name = name.getSuffix(1); if (name.isEmpty()) { return new NamingContextBindingsEnumeration(bindings.values().iterator(), this);
name = name.getSuffix(1); if (name.isEmpty()) { return new NamingContextBindingsEnumeration(bindings.values().iterator(), this);
@SuppressWarnings("unchecked") public NamingEnumeration<Binding> listBindings(String name) throws NamingException { if (log_.isDebugEnabled()) { log_.debug("listBindings: " + name); } Element<T> ei = getElement(name); if (!ei.canRead()) { throw new NameNotFoundException(name + " not found"); } else if (!ei.isCollection()) { throw new NotContextException(name + " cannot be listed"); } return new NamingContextBindingsEnumeration(listElement(ei).iterator(), this); }