Context.java 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161
  1. /* Context.java --
  2. Copyright (C) 2000 Free Software Foundation, Inc.
  3. This file is part of GNU Classpath.
  4. GNU Classpath is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 2, or (at your option)
  7. any later version.
  8. GNU Classpath is distributed in the hope that it will be useful, but
  9. WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  11. General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with GNU Classpath; see the file COPYING. If not, write to the
  14. Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
  15. 02111-1307 USA.
  16. Linking this library statically or dynamically with other modules is
  17. making a combined work based on this library. Thus, the terms and
  18. conditions of the GNU General Public License cover the whole
  19. combination.
  20. As a special exception, the copyright holders of this library give you
  21. permission to link this library with independent modules to produce an
  22. executable, regardless of the license terms of these independent
  23. modules, and to copy and distribute the resulting executable under
  24. terms of your choice, provided that you also meet, for each linked
  25. independent module, the terms and conditions of the license of that
  26. module. An independent module is a module which is not derived from
  27. or based on this library. If you modify this library, you may extend
  28. this exception to your version of the library, but you are not
  29. obligated to do so. If you do not wish to do so, delete this
  30. exception statement from your version. */
  31. package javax.naming;
  32. import java.util.Hashtable;
  33. public interface Context
  34. {
  35. // Property with name of the inital context factory to use
  36. public static final String INITIAL_CONTEXT_FACTORY
  37. = "java.naming.factory.initial";
  38. // Property with colon-separated list of object factories to use.
  39. public static final String OBJECT_FACTORIES
  40. = "java.naming.factory.object";
  41. // Property with colon-separated list of state factories to use.
  42. public static final String STATE_FACTORIES
  43. = "java.naming.factory.state";
  44. // Property with colon-separated list of package prefixes to use.
  45. public static final String URL_PKG_PREFIXES
  46. = "java.naming.factory.url.pkgs";
  47. // Property with URL specifying configuration for the service
  48. // provider to use.
  49. public static final String PROVIDER_URL
  50. = "java.naming.provider.url";
  51. // Property with the DNS host and domain names to use.
  52. public static final String DNS_URL
  53. = "java.naming.dns.url";
  54. // Property with the authoritativeness of the service requested.
  55. public static final String AUTHORITATIVE
  56. = "java.naming.authoritative";
  57. // Property with the batch size to use when returning data via the
  58. // service's protocol.
  59. public static final String BATCHSIZE
  60. = "java.naming.batchsize";
  61. // Property defining how referrals encountered by the service
  62. // provider are to be processed.
  63. public static final String REFERRAL
  64. = "java.naming.referral";
  65. // Property specifying the security protocol to use.
  66. public static final String SECURITY_PROTOCOL
  67. = "java.naming.security.protocol";
  68. // Property specifying the security level to use.
  69. public static final String SECURITY_AUTHENTICATION
  70. = "java.naming.security.authentication";
  71. // Property for the identity of the principal for authenticating
  72. // the caller to the service.
  73. public static final String SECURITY_PRINCIPAL
  74. = "java.naming.security.principal";
  75. // Property specifying the credentials of the principal for
  76. // authenticating the caller to the service.
  77. public static final String SECURITY_CREDENTIALS
  78. = "java.naming.security.credentials";
  79. // Property for specifying the preferred language to use with the
  80. // service.
  81. public static final String LANGUAGE
  82. = "java.naming.language";
  83. // Property for the initial context constructor to use when searching
  84. // for other properties.
  85. public static final String APPLET
  86. = "java.naming.applet";
  87. public void bind (Name name, Object obj) throws NamingException;
  88. public void bind (String name, Object obj) throws NamingException;
  89. public Object lookup (Name name) throws NamingException;
  90. public Object lookup (String name) throws NamingException;
  91. public void rebind (Name name, Object obj) throws NamingException;
  92. public void rebind (String name, Object obj) throws NamingException;
  93. public void unbind (Name name) throws NamingException;
  94. public void unbind (String name) throws NamingException;
  95. public void rename (Name oldName, Name newName) throws NamingException;
  96. public void rename (String oldName, String newName) throws NamingException;
  97. public NamingEnumeration list (Name name) throws NamingException;
  98. public NamingEnumeration list (String name) throws NamingException;
  99. public NamingEnumeration listBindings (Name name) throws NamingException;
  100. public NamingEnumeration listBindings (String name) throws NamingException;
  101. public void destroySubcontext (Name name) throws NamingException;
  102. public void destroySubcontext (String name) throws NamingException;
  103. public Context createSubcontext (Name name) throws NamingException;
  104. public Context createSubcontext (String name) throws NamingException;
  105. public Object lookupLink (Name name) throws NamingException;
  106. public Object lookupLink (String name) throws NamingException;
  107. public NameParser getNameParser (Name name) throws NamingException;
  108. public NameParser getNameParser (String name) throws NamingException;
  109. public Name composeName (Name name, Name prefix) throws NamingException;
  110. public String composeName (String name,
  111. String prefix) throws NamingException;
  112. public Object addToEnvironment (String propName,
  113. Object propVal) throws NamingException;
  114. public Object removeFromEnvironment (String propName) throws NamingException;
  115. public Hashtable getEnvironment () throws NamingException;
  116. public void close () throws NamingException;
  117. public String getNameInNamespace () throws NamingException;
  118. }