org.gxos.util
Class InternalNaming

java.lang.Object
  |
  +--org.gxos.util.InternalNaming

public class InternalNaming
extends java.lang.Object

This class provides utility methods for InternalND typed objects. In the GXOS schema, InternalND type objects are commonly used.

$Id: InternalNaming.java,v 1.8 2001/05/29 23:59:53 balsoy Exp $


Constructor Summary
InternalNaming()
          Default constructor.
 
Method Summary
static boolean contains(InternalND[] names, InternalND name)
          Checks if a name is in a name list.
static ExternalND copy(ExternalND nameSource, ExternalND nameDest)
          Copies one name to another.
static InternalND copy(InternalND nameSource, InternalND nameDest)
          Copies one name to another.
static java.lang.String getObjectName(java.lang.String name)
          Returns an object's name in an GXOS name URL, i.e.
static java.lang.String getParentName(java.lang.String name)
          Returns an object's name in an GXOS name URL, i.e.
static InternalND initInternalND(InternalND name, java.lang.String gxosName)
          Method for setting InternetAddress of an InternalND type object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InternalNaming

public InternalNaming()
Default constructor.
Method Detail

initInternalND

public static InternalND initInternalND(InternalND name,
                                        java.lang.String gxosName)
Method for setting InternetAddress of an InternalND type object.
Parameters:
name - InternalND type object to be set.
gxosName - GNDI name for this InternalND object.
Returns:
Altered input object name is returned.
See Also:
InternalND

getObjectName

public static java.lang.String getObjectName(java.lang.String name)
Returns an object's name in an GXOS name URL, i.e. event1 in //Education/Events/event1.
Parameters:
name - Object's name in string.
Returns:
Object's name.

getParentName

public static java.lang.String getParentName(java.lang.String name)
Returns an object's name in an GXOS name URL, i.e. event1 in //Education/Events/event1.
Parameters:
name - Object's name in string.
Returns:
Object's name.

contains

public static boolean contains(InternalND[] names,
                               InternalND name)
Checks if a name is in a name list. All names are {@see InternalND} typed.
Parameters:
names - an array of names
name - name to be check if exists in the array
Returns:
true if name exists in names; false otherwise.

copy

public static InternalND copy(InternalND nameSource,
                              InternalND nameDest)
Copies one name to another. If source name is null, destination returned unchanged.
Parameters:
nameSource - source name
nameDest - destionation name
Returns:
returns destination name.

copy

public static ExternalND copy(ExternalND nameSource,
                              ExternalND nameDest)
Copies one name to another. If source name is null, destination returned unchanged.
Parameters:
nameSource - source name
nameDest - destionation name
Returns:
returns destination name.