1. package org.omg.CosNaming;
  2. /**
  3. * org/omg/CosNaming/NamingContextOperations.java .
  4. * Generated by the IDL-to-Java compiler (portable), version "3.1"
  5. * from ../../../../src/share/classes/org/omg/CosNaming/nameservice.idl
  6. * Monday, February 23, 2004 7:03:07 AM GMT
  7. */
  8. /**
  9. * A naming context is an object that contains a set of name bindings in
  10. * which each name is unique. Different names can be bound to an object
  11. * in the same or different contexts at the same time. <p>
  12. *
  13. * See <a href="http://www.omg.org/technology/documents/formal/naming_service.htm">
  14. * CORBA COS
  15. * Naming Specification.</a>
  16. */
  17. public interface NamingContextOperations
  18. {
  19. /**
  20. * Creates a binding of a name and an object in the naming context.
  21. * Naming contexts that are bound using bind do not participate in name
  22. * resolution when compound names are passed to be resolved.
  23. *
  24. * @param n Name of the object <p>
  25. *
  26. * @param obj The Object to bind with the given name<p>
  27. *
  28. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates
  29. * the name does not identify a binding.<p>
  30. *
  31. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed
  32. * Indicates that the implementation has given up for some reason.
  33. * The client, however, may be able to continue the operation
  34. * at the returned naming context.<p>
  35. *
  36. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName
  37. * Indicates that the name is invalid. <p>
  38. *
  39. * @exception org.omg.CosNaming.NamingContextPackage.AlreadyBound
  40. * Indicates an object is already bound to the specified name.<p>
  41. */
  42. void bind (org.omg.CosNaming.NameComponent[] n, org.omg.CORBA.Object obj) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName, org.omg.CosNaming.NamingContextPackage.AlreadyBound;
  43. /**
  44. * Names an object that is a naming context. Naming contexts that
  45. * are bound using bind_context() participate in name resolution
  46. * when compound names are passed to be resolved.
  47. *
  48. * @param n Name of the object <p>
  49. *
  50. * @param nc NamingContect object to bind with the given name <p>
  51. *
  52. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates the name does not identify a binding.<p>
  53. *
  54. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed Indicates that the implementation has
  55. * given up for some reason. The client, however, may be able to
  56. * continue the operation at the returned naming context.<p>
  57. *
  58. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName Indicates that the name is invalid. <p>
  59. *
  60. * @exception org.omg.CosNaming.NamingContextPackage.AlreadyBound Indicates an object is already
  61. * bound to the specified name.<p>
  62. */
  63. void bind_context (org.omg.CosNaming.NameComponent[] n, org.omg.CosNaming.NamingContext nc) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName, org.omg.CosNaming.NamingContextPackage.AlreadyBound;
  64. /**
  65. * Creates a binding of a name and an object in the naming context
  66. * even if the name is already bound in the context. Naming contexts
  67. * that are bound using rebind do not participate in name resolution
  68. * when compound names are passed to be resolved.
  69. *
  70. * @param n Name of the object <p>
  71. *
  72. * @parm obj The Object to rebind with the given name <p>
  73. *
  74. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates the name does not identify a binding.<p>
  75. *
  76. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed Indicates that the implementation has
  77. * given up for some reason. The client, however, may be able to
  78. * continue the operation at the returned naming context.<p>
  79. *
  80. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName Indicates that the name is invalid. <p>
  81. */
  82. void rebind (org.omg.CosNaming.NameComponent[] n, org.omg.CORBA.Object obj) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName;
  83. /**
  84. * Creates a binding of a name and a naming context in the naming
  85. * context even if the name is already bound in the context. Naming
  86. * contexts that are bound using rebind_context() participate in name
  87. * resolution when compound names are passed to be resolved.
  88. *
  89. * @param n Name of the object <p>
  90. *
  91. * @param nc NamingContect object to rebind with the given name <p>
  92. *
  93. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates the name does not identify a binding.<p>
  94. *
  95. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed Indicates that the implementation has
  96. * given up for some reason. The client, however, may be able to
  97. * continue the operation at the returned naming context.<p>
  98. *
  99. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName Indicates that the name is invalid. <p>
  100. */
  101. void rebind_context (org.omg.CosNaming.NameComponent[] n, org.omg.CosNaming.NamingContext nc) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName;
  102. /**
  103. * The resolve operation is the process of retrieving an object
  104. * bound to a name in a given context. The given name must exactly
  105. * match the bound name. The naming service does not return the type
  106. * of the object. Clients are responsible for "narrowing" the object
  107. * to the appropriate type. That is, clients typically cast the returned
  108. * object from Object to a more specialized interface.
  109. *
  110. * @param n Name of the object <p>
  111. *
  112. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates the name does not identify a binding.<p>
  113. *
  114. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed Indicates that the implementation has
  115. * given up for some reason. The client, however, may be able to
  116. * continue the operation at the returned naming context.<p>
  117. *
  118. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName Indicates that the name is invalid. <p>
  119. */
  120. org.omg.CORBA.Object resolve (org.omg.CosNaming.NameComponent[] n) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName;
  121. /**
  122. * The unbind operation removes a name binding from a context.
  123. *
  124. * @param n Name of the object <p>
  125. *
  126. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates the name does not identify a binding.<p>
  127. *
  128. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed Indicates that the implementation has
  129. * given up for some reason. The client, however, may be able to
  130. * continue the operation at the returned naming context.<p>
  131. *
  132. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName Indicates that the name is invalid. <p>
  133. */
  134. void unbind (org.omg.CosNaming.NameComponent[] n) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName;
  135. /**
  136. * The list operation allows a client to iterate through a set of
  137. * bindings in a naming context. <p>
  138. *
  139. * The list operation returns at most the requested number of
  140. * bindings in BindingList bl.
  141. * <ul>
  142. * <li>If the naming context contains additional
  143. * bindings, the list operation returns a BindingIterator with the
  144. * additional bindings.
  145. * <li>If the naming context does not contain additional
  146. * bindings, the binding iterator is a nil object reference.
  147. * </ul>
  148. *
  149. * @param how_many the maximum number of bindings to return <p>
  150. *
  151. * @param bl the returned list of bindings <p>
  152. *
  153. * @param bi the returned binding iterator <p>
  154. */
  155. void list (int how_many, org.omg.CosNaming.BindingListHolder bl, org.omg.CosNaming.BindingIteratorHolder bi);
  156. /**
  157. * This operation returns a naming context implemented by the same
  158. * naming server as the context on which the operation was invoked.
  159. * The new context is not bound to any name.
  160. */
  161. org.omg.CosNaming.NamingContext new_context ();
  162. /**
  163. * This operation creates a new context and binds it to the name
  164. * supplied as an argument. The newly-created context is implemented
  165. * by the same naming server as the context in which it was bound (that
  166. * is, the naming server that implements the context denoted by the
  167. * name argument excluding the last component).
  168. *
  169. * @param n Name of the object <p>
  170. *
  171. * @exception org.omg.CosNaming.NamingContextPackage.NotFound Indicates the name does not identify a binding.<p>
  172. *
  173. * @exception org.omg.CosNaming.NamingContextPackage.AlreadyBound Indicates an object is already
  174. * bound to the specified name.<p>
  175. *
  176. * @exception org.omg.CosNaming.NamingContextPackage.CannotProceed Indicates that the implementation has
  177. * given up for some reason. The client, however, may be able to
  178. * continue the operation at the returned naming context.<p>
  179. *
  180. * @exception org.omg.CosNaming.NamingContextPackage.InvalidName Indicates that the name is invalid. <p>
  181. */
  182. org.omg.CosNaming.NamingContext bind_new_context (org.omg.CosNaming.NameComponent[] n) throws org.omg.CosNaming.NamingContextPackage.NotFound, org.omg.CosNaming.NamingContextPackage.AlreadyBound, org.omg.CosNaming.NamingContextPackage.CannotProceed, org.omg.CosNaming.NamingContextPackage.InvalidName;
  183. /**
  184. * The destroy operation deletes a naming context. If the naming
  185. * context contains bindings, the NotEmpty exception is raised.
  186. *
  187. * @exception org.omg.CosNaming.NamingContextPackage.NotEmpty Indicates that the Naming Context contains bindings.
  188. */
  189. void destroy () throws org.omg.CosNaming.NamingContextPackage.NotEmpty;
  190. } // interface NamingContextOperations