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