Class CreateGroupAction

    • Field Detail

    • Constructor Detail

      • CreateGroupAction

        public CreateGroupAction​(Map<String,​String> params)
        Initializes a create group standardizes action
        Parameters:
        params - the parameter map of the action
    • Method Detail

      • addGroup

        public void addGroup​(GroupDefinition group)
        Adds a group definition to the group list of the action
        Parameters:
        group - group definition to be added to the group list of the action
      • addGroup

        public void addGroup​(String abbreviation)
        Adds a group to the list defined by its abbreviation
        Parameters:
        abbreviation - the abbreviation of the group to be added
      • setAbbreviation

        public void setAbbreviation​(int index,
                                    String abbreviation)
        Sets the abbreviation of the group at the provided index
        Parameters:
        index - the target index
        abbreviation - the abbreviation to be set
      • setMolecule

        public void setMolecule​(int index,
                                Molecule molecule)
        Sets the molecule of the group at the provided index
        Parameters:
        index - the target index
        molecule - the molecule to be set
      • getGroupCount

        public int getGroupCount()
        Gets the count of the groups of the action
        Returns:
        the count of the groups of the action
      • getMolecule

        public Molecule getMolecule​(int index)
        Gets the molecule at the provided index
        Parameters:
        index - the required index
        Returns:
        the molecule at the provided index
      • getAbbreviation

        public String getAbbreviation​(int index)
        Gets the abbreviation at the provided index
        Parameters:
        index - the required index
        Returns:
        the abbreviation at the provided index
      • removeGroup

        public void removeGroup​(GroupDefinition group)
        Removes a group definition from the group list of the action
        Parameters:
        group - group definition to be removed from the group list of the action
      • removeAllGroups

        public void removeAllGroups()
        Removes all group definitions from the group list of the action.
      • get

        public GroupDefinition get​(int index)
        Returns the group definition at specified index.
        Parameters:
        index - the index of group definition
        Returns:
        the group definition at specified index
      • set

        public GroupDefinition set​(int index,
                                   GroupDefinition groupDefinition)
        Sets the group definition at specified index, and returns the previous value.
        Parameters:
        index - the index of element to change
        groupDefinition - the new group definition to set
        Returns:
        the previous group definition at specified index
      • getGroupList

        public chemaxon.standardizer.advancedactions.GroupList getGroupList()
        Gets the list of groups set for the action
        Returns:
        the list of groups set for the action