Class MoveRenameResourceChange

  • All Implemented Interfaces:
    IAdaptable

    public class MoveRenameResourceChange
    extends ResourceChange
    Change that moves and renames a resource.
    Since:
    3.10
    • Constructor Detail

      • MoveRenameResourceChange

        public MoveRenameResourceChange​(IResource source,
                                        IContainer target,
                                        java.lang.String newName)
        Creates the change.
        Parameters:
        source - the resource to move
        target - the container the resource is moved to. An existing resource at the destination will be replaced.
        newName - new name of resource
      • MoveRenameResourceChange

        protected MoveRenameResourceChange​(IResource source,
                                           IContainer target,
                                           java.lang.String newName,
                                           long stampToRestore,
                                           Change restoreSourceChange)
        Creates the change.
        Parameters:
        source - the resource to move
        target - the container the resource is moved to. An existing resource at the destination will be replaced.
        newName - the new name of the resource in the the target container
        stampToRestore - the stamp to restore on the moved resource
        restoreSourceChange - the change to restore a resource at the source or null if no resource needs to be resourced.
    • Method Detail

      • setDescriptor

        public void setDescriptor​(ChangeDescriptor descriptor)
        Sets the change descriptor to be returned by Change.getDescriptor().
        Parameters:
        descriptor - the change descriptor
      • getName

        public java.lang.String getName()
        Description copied from class: Change
        Returns the human readable name of this change. The name MUST not be null.
        Specified by:
        getName in class Change
        Returns:
        the human readable name of this change