Using a URL as a Name to the Initial Context : Name « JNDI LDAP « Java






Using a URL as a Name to the Initial Context

  
import javax.naming.InitialContext;

public class Main {
  public static void main(String[] argv) throws Exception {
    Object obj = new InitialContext().lookup("iiop://localhost/Sample");
  }
}

   
    
  








Related examples in the same category

1.Getting an Object's Fully Qualified Name
2.Parsing a JNDI Composite Name
3.Parsing a JNDI Compound Name
4.Show only the common name (cn) and e-mail address (mail) attributes
5.Replace the placeholders in the filter with the proper values from the userName