Examples of lookupLink()


Examples of javax.naming.Context.lookupLink()

    public Object lookupLink(String name) throws NamingException {
        ResolveResult result = getRootURLContext(name, environment);
        Context context = (Context) result.getResolvedObj();

        try {
            return context.lookupLink(result.getRemainingName());
        } finally {
            context.close();
        }
    }
View Full Code Here

Examples of javax.naming.Context.lookupLink()

        if (name.size() == 1) {
            return lookupLink(name.get(0));
        }
        Context context = getContinuationContext(name);
        try {
            return context.lookupLink(name.getSuffix(1));
        } finally {
            context.close();
        }
    }
View Full Code Here

Examples of javax.naming.Context.lookupLink()

    public Object lookupLink(String name) throws NamingException {
        ResolveResult result = getRootURLContext(name, environment);
        Context context = (Context) result.getResolvedObj();

        try {
            return context.lookupLink(result.getRemainingName());
        } finally {
            context.close();
        }
    }
View Full Code Here

Examples of javax.naming.Context.lookupLink()

        Context context = EnterpriseNamingContext.createEnterpriseNamingContext(map);

        Name stringName = context.getNameParser("").parse("string");
        assertEquals(STRING_VAL, context.lookup("string"));
        assertEquals(STRING_VAL, context.lookup(stringName));
        assertEquals(STRING_VAL, context.lookupLink("string"));
        assertEquals(STRING_VAL, context.lookupLink(stringName));

        Name nestedContextStringName = context.getNameParser("").parse("nested/context/string");
        assertEquals(STRING_VAL, context.lookup("nested/context/string"));
        assertEquals(STRING_VAL, context.lookup(nestedContextStringName));
View Full Code Here

Examples of javax.naming.Context.lookupLink()

        Name stringName = context.getNameParser("").parse("string");
        assertEquals(STRING_VAL, context.lookup("string"));
        assertEquals(STRING_VAL, context.lookup(stringName));
        assertEquals(STRING_VAL, context.lookupLink("string"));
        assertEquals(STRING_VAL, context.lookupLink(stringName));

        Name nestedContextStringName = context.getNameParser("").parse("nested/context/string");
        assertEquals(STRING_VAL, context.lookup("nested/context/string"));
        assertEquals(STRING_VAL, context.lookup(nestedContextStringName));
        assertEquals(STRING_VAL, context.lookupLink("nested/context/string"));
View Full Code Here

Examples of javax.naming.Context.lookupLink()

        assertEquals(STRING_VAL, context.lookupLink(stringName));

        Name nestedContextStringName = context.getNameParser("").parse("nested/context/string");
        assertEquals(STRING_VAL, context.lookup("nested/context/string"));
        assertEquals(STRING_VAL, context.lookup(nestedContextStringName));
        assertEquals(STRING_VAL, context.lookupLink("nested/context/string"));
        assertEquals(STRING_VAL, context.lookupLink(nestedContextStringName));
    }

    public void testList() throws Exception {
        Map map = new HashMap();
View Full Code Here

Examples of javax.naming.Context.lookupLink()

        Name nestedContextStringName = context.getNameParser("").parse("nested/context/string");
        assertEquals(STRING_VAL, context.lookup("nested/context/string"));
        assertEquals(STRING_VAL, context.lookup(nestedContextStringName));
        assertEquals(STRING_VAL, context.lookupLink("nested/context/string"));
        assertEquals(STRING_VAL, context.lookupLink(nestedContextStringName));
    }

    public void testList() throws Exception {
        Map map = new HashMap();
        map.put("one", new Integer(1));
View Full Code Here

Examples of javax.naming.Context.lookupLink()

      catch (NameNotFoundException e)
      {
         Context haCtx = InitialContextFactory.getHAContext(jndiContext);
         if(haCtx == null)
            throw e;
         object = haCtx.lookupLink(binding);
      }
     
      return object;
   }
}
View Full Code Here

Examples of javax.naming.InitialContext.lookupLink()

      redeployNaming();
     
      Context ctx2 = new InitialContext(env);
      try
      {
         Object obj = ctx2.lookupLink(ObjectBinder.NAME);
         if (obj instanceof MarshalledValuePair)
            obj = ((MarshalledValuePair) obj).get();
         assertEquals(ObjectBinder.VALUE, obj);
      }
      catch (NamingException e)
View Full Code Here

Examples of javax.naming.InitialContext.lookupLink()

      redeployNaming();
     
      Context ctx2 = new InitialContext(env);
      try
      {
         Object obj = ctx2.lookupLink(ObjectBinder.NAME);
         if (obj instanceof MarshalledValuePair)
            obj = ((MarshalledValuePair) obj).get();
         assertEquals(ObjectBinder.VALUE, obj);
      }
      catch (NamingException e)
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.