Class RenameNamedRelation


  • public class RenameNamedRelation
    extends UnitRelation
    A relation indicating that the source unit renames the Named Object
    • Constructor Summary

      Constructors 
      Constructor Description
      RenameNamedRelation​(Unit s, Named named, java.lang.String name, int line)
      Creates a new RenameRelation.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void add()
      Attaches an order to all report objects it is relevant to. source and named.
      boolean isRelated​(java.lang.Object object)
      Returns true if this relation somehow relates to the specified object.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • named

        public Named named
        The object that is named
      • name

        public java.lang.String name
        The given name
    • Constructor Detail

      • RenameNamedRelation

        public RenameNamedRelation​(Unit s,
                                   Named named,
                                   java.lang.String name,
                                   int line)
        Creates a new RenameRelation.
        Parameters:
        s - The source unit
        named - The target unit
        name - The new name of named
        line - The line in the source's orders
    • Method Detail

      • add

        public void add()
        Attaches an order to all report objects it is relevant to. source and named.
        Overrides:
        add in class UnitRelation
      • isRelated

        public boolean isRelated​(java.lang.Object object)
        Description copied from class: UnitRelation
        Returns true if this relation somehow relates to the specified object. Subclasses should overwrite this method if they involve relations to other report objects.
        Overrides:
        isRelated in class UnitRelation
        Returns:
        true if the object is source or origin or otherwise affected by this relation