Class IORImpl

All Implemented Interfaces:
IOR, MakeImmutable, Writeable, Iterable, Collection, List

public class IORImpl extends IdentifiableContainerBase implements IOR
An IOR is represented as a list of profiles. Only objects that extend TaggedProfile should be added to an IOR. However, enforcing this restriction requires overriding all of the addXXX methods inherited from List, so no check is included here.
Author:
Ken Cavanaugh
  • Constructor Details

    • IORImpl

      public IORImpl(ORB orb)
      Construct an empty IOR. This is needed for null object references.
    • IORImpl

      public IORImpl(ORB orb, String typeid)
    • IORImpl

      public IORImpl(ORB orb, String typeId, IORTemplate iortemp, ObjectId id)
      Construct an IOR from an IORTemplate by applying the same object id to each TaggedProfileTemplate in the IORTemplate.
    • IORImpl

      public IORImpl(ORB orb, String typeId, IORTemplateList iortemps, ObjectId id)
      Construct an IOR from an IORTemplate by applying the same object id to each TaggedProfileTemplate in the IORTemplate.
    • IORImpl

      public IORImpl(InputStream is)
  • Method Details

    • getORB

      public ORB getORB()
      Specified by:
      getORB in interface IOR
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface Collection
      Specified by:
      equals in interface List
      Overrides:
      equals in class FreezableList
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface Collection
      Specified by:
      hashCode in interface List
      Overrides:
      hashCode in class FreezableList
    • getTypeId

      public String getTypeId()
      Description copied from interface: IOR
      Return the type id string from the IOR.
      Specified by:
      getTypeId in interface IOR
    • write

      public void write(OutputStream os)
      Description copied from interface: Writeable
      Write this object directly to the output stream.
      Specified by:
      write in interface Writeable
    • stringify

      public String stringify()
      Description copied from interface: IOR
      Return a representation of this IOR in the standard GIOP stringified format that begins with "IOR:".
      Specified by:
      stringify in interface IOR
    • makeImmutable

      public void makeImmutable()
      Specified by:
      makeImmutable in interface MakeImmutable
      Overrides:
      makeImmutable in class FreezableList
    • getIOPIOR

      public IOR getIOPIOR()
      Description copied from interface: IOR
      Return a representation of this IOR in the standard GIOP marshalled form.
      Specified by:
      getIOPIOR in interface IOR
    • isNil

      public boolean isNil()
      Description copied from interface: IOR
      Return true if this IOR has no profiles.
      Specified by:
      isNil in interface IOR
    • isEquivalent

      public boolean isEquivalent(IOR ior)
      Description copied from interface: IOR
      Return true if this IOR is equivalent to ior. Here equivalent means that the typeids are the same, they have the same number of profiles, and each profile is equivalent to the corresponding profile.
      Specified by:
      isEquivalent in interface IOR
    • getIORTemplates

      public IORTemplateList getIORTemplates()
      Return the IORTemplateList for this IOR. Will throw exception if it is not possible to generate an IOR from the IORTemplateList that is equal to this IOR, which can only happen if not every TaggedProfile in the IOR has the same ObjectId.
      Specified by:
      getIORTemplates in interface IOR
    • getProfile

      public IIOPProfile getProfile()
      Return the first IIOPProfile in this IOR. XXX THIS IS TEMPORARY FOR BACKWARDS COMPATIBILITY AND WILL BE REMOVED SOON!
      Specified by:
      getProfile in interface IOR