## com.rbnb.api
Interface RmapInterface

All Superinterfaces:
  Cloneable, Serializable

All Known Subinterfaces:
  Client, ClientInterface, Controller, com.rbnb.api.ControllerInterface, PlugIn, PlugInInterface, RoutingMap, com.rbnb.api.RoutingMapInterface, Shortcut, com.rbnb.api.ShortcutInterface, Sink, SinkInterface, Source, SourceInterface

All Known Implementing Classes:
  ControllerHandle

    public interface RmapInterface

extends Cloneable, Serializable

`Rmap` methods interface.

This interface provides a description of an `Rmap` that provides the minimum number of methods necessary to access generally useful capabilities of an `Rmap` through other interfaces.

Since:
  V2.0
Author:
  Ian Brown
Version:
  09/28/2004

Method Summary
`void` `addChild(Rmap childI)` Adds a child `Rmap` to this `RmapInterface`.
`Object` `clone()` Clones this object.
`int` `compareNames(Rmap otherI)` Compares the name of this `RmapInterface` to the name of the input `Rmap`.
`int` `compareNames(String nameI)` Compares the name of this `RmapInterface` to the input name.
`int` `compareTo(Rmap rmapI)` Compares the input `Rmap` to this one.
`Rmap` `findChild(Rmap childI)` Finds a matching child `Rmap`.
`Rmap` `findDescendant(String nameI, boolean addI)` Finds a descendant `Rmap` by name.
`String` `getFullName()` Gets the fully qualified name of this `Rmap`.
`String` `getName()` Gets the name of this `RmapInterface`.
`Rmap` `getParent()` Gets the parent `Rmap` of this `RmapInterface`.
`void` `removeChild(Rmap childI)` Removes a child `Rmap` from this `RmapInterface`.
`void` `removeChildAt(int indexI)` Removes the child `Rmap` at a particular index from this `RmapInterface`.
`void` `setName(String nameI)` Sets the name of this `RmapInterface`.
`String` `toString()` Gets a displayable string representation of this `RmapInterface`.
`String` `toString(boolean memberI, String indentI)` Gets a displayable string representation of this `RmapInterface`.

Method Detail

### addChild

    void addChild(Rmap childI)
                  throws AddressException,
                         SerializeException,
                         EOFException,
                         IOException,
                         InterruptedException

  Adds a child `Rmap` to this `RmapInterface`.

  Parameters:
    `childI` - the new child `Rmap`.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `EOFException` - thrown if the end of the input stream is reached.
    `IOException` - thrown if there is an error during I/O.
    `IllegalArgumentException` - thrown if the input `Rmap` is already a child of another `Rmap` or if the input is null.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  See Also:
    `removeChild(com.rbnb.api.Rmap)`, `removeChildAt(int)`
  Author:
    Ian Brown
  Version:
    01/24/2002

### clone

    Object clone()

  Clones this object.

  Returns:
    the clone.
  Since:
    V2.0
  See Also:
    `Cloneable`
  Author:
    Ian Brown
  Version:
    05/11/2001

### compareNames

    int compareNames(Rmap otherI)

  Compares the name of this `RmapInterface` to the name of the input `Rmap`.

  Parameters:
    `otherI` - the other `Rmap`.
  Returns:
    the results of the comparison:
    - <0 if this `RmapInterface` compares less than the input,
    - 0 if this `RmapInterface` compares equal to the input, and,
    - 0 if this `RmapInterface` compares greater than the input.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001

### compareNames

    int compareNames(String nameI)

  Compares the name of this `RmapInterface` to the input name.

  Parameters:
    `nameI` - the name to compare to.
  Returns:
    the results of the comparison:
    - <0 if this `RmapInterface` compares less than the input,
    - 0 if this `RmapInterface` compares equal to the input, and,
    - 0 if this `RmapInterface` compares greater than the input.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001

### compareTo

    int compareTo(Rmap rmapI)

  Compares the input `Rmap` to this one.

  Parameters:
    `rmapI` - the `Rmap` to compare.
  Returns:
    the results of the comparison:

    <0 if this `Rmap` compares less than the input,

    0 if this `Rmap` compares equal to the input, and

    >0 if this `Rmap` compares greater than the input.

  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001

### findChild

    Rmap findChild(Rmap childI)
                   throws AddressException,
                          SerializeException,
                          IOException,
                          InterruptedException

  Finds a matching child `Rmap`.

  If there are multiple matches, the one returned is not defined.

  Parameters:
    `childI` - the child `Rmap` to match.
  Returns:
    the matching child `Rmap`.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `IOException` - thrown if there is an error during I/O.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001

### findDescendant

    Rmap findDescendant(String nameI,
                        boolean addI)
                        throws AddressException,
                               SerializeException,
                               IOException,
                               InterruptedException

  Finds a descendant `Rmap` by name.

  Due to the complications introduced by group membership, this method can only be used properly when there are no groups. If a group is discovered during the search, an exception is thrown.

  This method can optionally create the hierarchy leading to the desired descendant.

  Parameters:
    `nameI` - the fully qualified descendant's name.
    `addI` - add the descendant if it doesn't exist?
  Returns:
    the descendant.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `IOException` - thrown if there is an error during I/O.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    08/30/2002

### getFullName

    String getFullName()
                       throws AddressException,
                              SerializeException,
                              EOFException,
                              IOException,
                              InterruptedException

  Gets the fully qualified name of this `Rmap`.

  If the `Rmap` is a descendent of an `Rmap` with group members, the fully qualified name is actually ambiguous. The code fills in a special _<member> name into the fully qualified name at the appropriate point.

  Returns:
    the fully qualified name.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `EOFException` - thrown if the end of the input stream is reached.
    `IOException` - thrown if there is an error during I/O.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    12/13/2001

### getName

    String getName()

  Gets the name of this `RmapInterface`.

  Returns:
    the name.
  Since:
    V2.0
  See Also:
    `setName(String)`
  Author:
    Ian Brown
  Version:
    05/10/2001

### getParent

    Rmap getParent()

  Gets the parent `Rmap` of this `RmapInterface`.

  Returns:
    the parent `Rmap`.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001

### removeChild

    void removeChild(Rmap childI)
                     throws AddressException,
                            SerializeException,
                            EOFException,
                            IOException,
                            InterruptedException

  Removes a child `Rmap` from this `RmapInterface`.

  Parameters:
    `childI` - the child to remove.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `EOFException` - thrown if the end of the input stream is reached.
    `IOException` - thrown if there is an error during I/O.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  See Also:
    `addChild(com.rbnb.api.Rmap)`, `removeChildAt(int)`
  Author:
    Ian Brown
  Version:
    01/24/2002

### removeChildAt

    void removeChildAt(int indexI)
                       throws AddressException,
                              SerializeException,
                              EOFException,
                              IOException,
                              InterruptedException

  Removes the child `Rmap` at a particular index from this `RmapInterface`.

  Parameters:
    `indexI` - the index of child to remove.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `EOFException` - thrown if the end of the input stream is reached.
    `IOException` - thrown if there is an error during I/O.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  See Also:
    `addChild(com.rbnb.api.Rmap)`, `removeChild(com.rbnb.api.Rmap)`
  Author:
    Ian Brown
  Version:
    01/24/2002

### setName

    void setName(String nameI)
                 throws AddressException,
                        SerializeException,
                        EOFException,
                        InterruptedIOException,
                        IOException,
                        InterruptedException

  Sets the name of this `RmapInterface`.

  Parameters:
    `nameI` - the name of the `RmapInterface`.
  Throws:
    `AddressException` - thrown if there is a problem with an address.
    `SerializeException` - thrown if there is a problem with the serialization.
    `EOFException` - thrown if the end of the input stream is reached.
    `InterruptedIOException` - thrown if this operation is interrupted during I/O.
    `IOException` - thrown if there is an error during I/O.
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  See Also:
    `getName()`
  Author:
    Ian Brown
  Version:
    06/04/2001

### toString

    String toString()

  Gets a displayable string representation of this `RmapInterface`.

  Overrides:
    `toString` in class `Object`
  Returns:
    the string representation.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001

### toString

    String toString(boolean memberI,
                    String indentI)
                    throws InterruptedException

  Gets a displayable string representation of this `RmapInterface`.

  This method is the workhorse that actually does the work under the the standard `toString()` method. It builds a representation that shows the entire structure of the `RmapInterface`, including the group members and the children.

  The input parameters specify whether this `RmapInterface` is a group member of its parent (or a child) and the identation string to prepend to put this `RmapInterface` under its parent.

  Parameters:
    `memberI` - is this `RmapInterface` a group member?
    `indentI` - the indentation string to use.
  Returns:
    the string representation.
  Throws:
    `InterruptedException` - thrown if the operation is interrupted.
  Since:
    V2.0
  Author:
    Ian Brown
  Version:
    05/10/2001