Class DeepRename


  • public class DeepRename
    extends XMLRequest
    Rename an object including all objects in the same folder and below.
    • Constructor Detail

      • DeepRename

        public DeepRename()
        Constructs a DeepRename request.
    • Method Detail

      • getSrc

        protected java.lang.String getSrc()
        Description copied from class: XMLRequest
        Returns the request source. This method is used internally.
        Specified by:
        getSrc in class XMLRequest
        Returns:
        Source
      • createRequest

        protected void createRequest​(com.uc4.util.XMLDocument doc,
                                     org.w3c.dom.Element request,
                                     ConnectionAttributes sessionInfo)
        Description copied from class: XMLRequest
        Creates the XML Document for the request. This method is used internally.
        Specified by:
        createRequest in class XMLRequest
        Parameters:
        doc - Document, used to create new Elements
        request - Request Element - classes append information to this request element
        sessionInfo - Information about the session
      • setNamePattern

        public void setNamePattern​(java.lang.String namePattern)
        Sets the name pattern of the object to rename.
        Parameters:
        namePattern - wildcard with exactly one '*': like "BEGIN.*.END" new object names will be created like "BEGIN.NAME.END pattern must contain a '*', strings before/after the '*' are optional
      • setCleanPattern

        public void setCleanPattern​(java.lang.String cleanPattern)
        Sets the new name.
        Parameters:
        cleanPattern - wildcard with exactly one '*': like "BEFORE.*.AFTER" old object names are used to create new object names using parameter namePattern, however, cleanPatter is used to remove leading and/or trailing characters. in this example, prefix/postfix "BEFORE." / ".AFTER" is removed from the begin / end of old names and "BEGIN_" / "_END" is used as new prefix / postfix to create the new name, e.g., old name "BEFORE.NAME.AFTER" is converted to new name "BEGIN.NAME.END" pattern must contain a '*', strings before/after the '*' are optional
      • setAbortIfNameExists

        public void setAbortIfNameExists​(DeepRename.AbortIfNameExistsMode nameExistsMode)
        Sets the mode for abortIfNameExists.
        Parameters:
        nameExistsMode - One of the AbortIfNameExistsMode defined in this class
      • setIncludeFolderNames

        public void setIncludeFolderNames​(DeepRename.IncludeFolderNamesMode includeFolderNamesMode)
        Sets the mode for includeFolderNames.
        Parameters:
        includeFolderNamesMode - One of the IncludeFolderNamesMode defined in this class
      • isAllowedInClientZero

        protected boolean isAllowedInClientZero()
        Description copied from class: XMLRequest
        This method is used internally. Tests if this XMLRequest is allowed in client 0. The default implementation returns false, subclasses may override.
        Overrides:
        isAllowedInClientZero in class XMLRequest
        Returns:
        true if this request is allowed in client 0, false otherwise