Package javax.naming

Examples of javax.naming.Context.list()


      }
      catch (CannotProceedException cpe)
      {
         cpe.setEnvironment(refEnv);
         Context cctx = NamingManager.getContinuationContext(cpe);
         return cctx.list(cpe.getRemainingName());
      }
      catch (IOException e)
      {
         naming = null;
         removeServer(refEnv);
View Full Code Here


            while ( e.skipReferral() )
            {
                try
                {
                    Context ctx2 = e.getReferralContext();
                    ctx2.list( "" );
                }
                catch ( NamingException ne )
                {
                    if ( ne instanceof ReferralException )
                    {
View Full Code Here

    public NamingEnumeration<NameClassPair> list(final Name name) throws NamingException {
        try {
            return namingEnumeration(namingStore.list(getAbsoluteName(name)));
        } catch(CannotProceedException cpe) {
            final Context continuationContext = NamingManager.getContinuationContext(cpe);
            return continuationContext.list(cpe.getRemainingName());
        }
    }

    /** {@inheritDoc} */
    public NamingEnumeration<NameClassPair> list(final String name) throws NamingException {
View Full Code Here

      }
      catch (CannotProceedException cpe)
      {
         cpe.setEnvironment(refEnv);
         Context cctx = NamingManager.getContinuationContext(cpe);
         return cctx.list(cpe.getRemainingName());
      }
      catch (IOException e)
      {
         naming = null;
         removeServer(refEnv);
View Full Code Here

      }
      catch (CannotProceedException cpe)
      {
         cpe.setEnvironment(refEnv);
         Context cctx = NamingManager.getContinuationContext(cpe);
         return cctx.list(cpe.getRemainingName());
      }
      catch (IOException e)
      {
         naming = null;
         removeServer(refEnv);
View Full Code Here

      }
      catch (CannotProceedException cpe)
      {
         cpe.setEnvironment(refEnv);
         Context cctx = NamingManager.getContinuationContext(cpe);
         return cctx.list(cpe.getRemainingName());
      }
      catch (IOException e)
      {
         naming = null;
         removeServer(refEnv);
View Full Code Here

    public NamingEnumeration<Binding> listBindings(String name) throws NamingException {
        Object o = lookup(name);
        if (o instanceof Context) {
            Context context = (Context) o;
            NamingEnumeration<NameClassPair> enumeration = context.list("");
            List<NameClassPair> bindings = new ArrayList<NameClassPair>();

            while (enumeration.hasMoreElements()) {
                NameClassPair pair = enumeration.nextElement();
                bindings.add(new LazyBinding(pair.getName(), pair.getClassName(), context));
View Full Code Here

     *
     */
    private void printCompEnv() throws NamingException {
        log.warn("Printing java:comp/env/jms context: ");
        Context c = (Context) new InitialContext().lookup("java:comp/env/jms");
        NamingEnumeration iter = c.list("");
        while (iter.hasMoreElements()) {
            NameClassPair pair = (NameClassPair) iter.next();
            log.warn("'" + pair.getName() + "'");
            /*
             * Object obj = ctx.lookup(node.getName()); if ( obj instanceof
View Full Code Here

  /**  
         * Enumerates the names bound in the named context, along with the class names of objects bound to them.
         */  
  public NamingEnumeration list(Name name) throws NamingException {
    Context ctx = getImpl();
    return ctx.list(name);
  }


  /**  
         * Enumerates the names bound in the named context, along with the class names of objects bound to them.
View Full Code Here

  /**  
         * Enumerates the names bound in the named context, along with the class names of objects bound to them.
         */  
  public NamingEnumeration list(String name) throws NamingException {
    Context ctx = getImpl();
    return ctx.list(name);
  }


  /**  
         * Enumerates the names bound in the named context, along with the objects bound to them.
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.