|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.openorb.util.NamingUtils
The functions in this class perform various tranlations on stringified CosNaming names.
Constructor Summary | |
NamingUtils()
|
Method Summary | |
static java.lang.String |
decodeRFC2396(java.lang.String enc)
Decodes an RFC2396 encoded string. |
static void |
deepBind(NamingContext context,
NameComponent[] name,
Object obj)
Binds a objet to a name, creating any required subcontexts. |
static void |
deepBind(NamingContext context,
java.lang.String name,
Object obj)
Binds a objet to a name, creating any required subcontexts. |
static void |
deepRebind(NamingContext context,
NameComponent[] name,
Object obj)
Binds a objet to a name, creating any required subcontexts. |
static void |
deepRebind(NamingContext context,
java.lang.String name,
Object obj)
Binds a objet to a name, creating any required subcontexts. |
static java.lang.String |
encodeRFC2396(java.lang.String str)
Encodes a string according to RFC2396. |
static NameComponent[] |
parent(NameComponent[] name)
Get the parent name of the given name. |
static java.lang.String |
parent(java.lang.String name)
Get the parent name of the given name. |
static NamingContext |
resolveOrCreateContext(NamingContext context,
NameComponent[] name)
Resolve contexts as far as they exist in the name, and create the remainder |
static NameComponent[] |
to_name(java.lang.String sn)
This operation accepts a stringified name and returns a Name. |
static java.lang.String |
to_string(NameComponent[] n)
This operation accepts Name and returns a stringified name. |
static java.lang.String |
to_url(java.lang.String addr,
java.lang.String sn)
This operation takes an URL address and performs any escapes necessary on the stringified name and returns a fully formed URL string. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public NamingUtils()
Method Detail |
public static void deepBind(NamingContext context, java.lang.String name, Object obj) throws InvalidName, NotFound, CannotProceed, AlreadyBound
context
- The name context root.name
- The nameobj
- The object to bind.public static void deepBind(NamingContext context, NameComponent[] name, Object obj) throws InvalidName, NotFound, CannotProceed, AlreadyBound
context
- The name context root.name
- The nameobj
- The object to bind.public static void deepRebind(NamingContext context, java.lang.String name, Object obj) throws InvalidName, NotFound, CannotProceed
context
- The name context root.name
- The nameobj
- The object to bind.public static void deepRebind(NamingContext context, NameComponent[] name, Object obj) throws InvalidName, NotFound, CannotProceed
context
- The name context root.name
- The nameobj
- The object to bind.public static NamingContext resolveOrCreateContext(NamingContext context, NameComponent[] name) throws InvalidName, NotFound, CannotProceed
context
- The name context root.name
- The namepublic static NameComponent[] to_name(java.lang.String sn) throws InvalidName
sn
- the stringified name to transform to a name.InvalidName
- This exception is raised if the
stringified name is syntactically malformed or
violates an implementation limit.public static java.lang.String to_string(NameComponent[] n) throws InvalidName
n
- the name to stringified.InvalidName
- This exception is raised if the name is
invalid.public static java.lang.String to_url(java.lang.String addr, java.lang.String sn) throws InvalidAddress, InvalidName
addr
- the address ( for example myhost.xyz.com )sn
- the stringified name to add to the URLInvalidAddress
- This exception is raises if a address
is invalid ( it means that the address does not
respect the address format ).InvalidName
- This exception is raised if the
stringified name is syntactically malformed or
violates an implementation limit.public static java.lang.String encodeRFC2396(java.lang.String str)
public static java.lang.String decodeRFC2396(java.lang.String enc)
enc
- the string to encode.InvalidArgumentException
- the string to decode is formatted
incorrectly.public static NameComponent[] parent(NameComponent[] name)
name
- the name.public static java.lang.String parent(java.lang.String name)
name
- the name.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |