summaryrefslogtreecommitdiff
path: root/gnu/CORBA/NamingService/NamingMap.java
diff options
context:
space:
mode:
authorAudrius Meskauskas <audriusa@Bioinformatics.org>2006-02-14 15:32:27 +0000
committerAudrius Meskauskas <audriusa@Bioinformatics.org>2006-02-14 15:32:27 +0000
commit2482e7fa3e45ededb2dcde23b6c752f7b8d27f2f (patch)
tree9e3d980d0c190b9e422d2d0f9d534ea71b00ca70 /gnu/CORBA/NamingService/NamingMap.java
parentcd71f3a41518aed65e7e6c09c38f4a1c0180e9a8 (diff)
downloadclasspath-2482e7fa3e45ededb2dcde23b6c752f7b8d27f2f.tar.gz
2006-02-14 Audrius Meskauskas <AudriusA@Bioinformatics.org>
* NEWS: Updated tool status. * gnu/CORBA/NamingService/NamingMap.java (Map): Made protected. (constructor, bind, rebind): Rewritten. * gnu/CORBA/NamingService/TransientContext.java: Rewritten. (comitting in parts - problems). * tools/gnu/classpath/tools/giop/README: Updated. * tools/gnu/classpath/tools/giop/NameServicePersistent.java, tools/gnu/classpath/tools/giop/NamingServicePersistent.txt, tools/gnu/classpath/tools/giop/nameservice/PersistentContext.java, tools/gnu/classpath/tools/giop/nameservice/PersistentContextMap.java, tools/gnu/classpath/tools/giop/nameservice/PersistentMap.java: New files.
Diffstat (limited to 'gnu/CORBA/NamingService/NamingMap.java')
-rw-r--r--gnu/CORBA/NamingService/NamingMap.java13
1 files changed, 8 insertions, 5 deletions
diff --git a/gnu/CORBA/NamingService/NamingMap.java b/gnu/CORBA/NamingService/NamingMap.java
index 95deb0096..f4e940ea9 100644
--- a/gnu/CORBA/NamingService/NamingMap.java
+++ b/gnu/CORBA/NamingService/NamingMap.java
@@ -58,11 +58,11 @@ public class NamingMap
/**
* The actual map.
*/
- private final TreeMap map;
+ protected final TreeMap map;
/**
* Creates an instance of the naming map, intialising the comparator
- * to the {@link cmpNameComparator}.
+ * to the {@link NameComponentComparator}.
*/
public NamingMap()
{
@@ -70,7 +70,7 @@ public class NamingMap
}
/**
- * Put the given CORBA object, specifying the given name as a key.
+ * Put the given GIOP object, specifying the given name as a key.
* If the entry with the given name already exists, or if the given
* object is already mapped under another name, the
* {@link AlreadyBound} exception will be thrown.
@@ -93,8 +93,11 @@ public class NamingMap
else
{
if (containsValue(object))
- throw new AlreadyBound("Tha object has another name");
+ throw new AlreadyBound("The object has another name");
}
+
+ // There are no restrictions in binding the object.
+ rebind(name, object);
}
/**
@@ -141,7 +144,7 @@ public class NamingMap
}
/**
- * Put the given CORBA object, specifying the given name as a key.
+ * Put the given GIOP object, specifying the given name as a key.
* Remove all pre - existing mappings for the given name and object.
*
* @param name the name.