Package chemaxon.util

Class HitColoringAndAlignmentOptions

  • All Implemented Interfaces:
    Cloneable

    @PublicAPI
    public final class HitColoringAndAlignmentOptions
    extends Object
    implements Cloneable
    Class for specifying coloring and alignment options.
    Since:
    JChem 5.0
    • Constructor Detail

      • HitColoringAndAlignmentOptions

        public HitColoringAndAlignmentOptions()
    • Method Detail

      • getEnumerateMarkush

        public boolean getEnumerateMarkush()
        Returns true if markush structures should be hit enumerated according to the query structure. (Markush reduction to the hit.)
        Returns:
        true if markush structures should be hit enumerated according to the query structure. (Markush reduction to the hit.)
        Since:
        JChem 5.12
      • setEnumerateMarkush

        public void setEnumerateMarkush​(boolean enumerateMarkush)
        Sets whether markush structures should be hit enumerated according to the query structure. (Markush reduction to the hit.)
        Parameters:
        enumerateMarkush - true if markush structures should be hit enumerated according to the query structure. (Markush reduction to the hit.)
        Since:
        JChem 5.12
      • isQueryDisplay

        public boolean isQueryDisplay()
        Gets whether the query should be displayed in the upper left corner along with the hit. Default is false .
        Returns:
        true if query is to be shown, false if not.
      • setQueryDisplay

        public void setQueryDisplay​(boolean value)
        Set query display option
        Parameters:
        value - true if query is to be displayed false if not. See:
      • isRemoveUnusedDefitions

        public boolean isRemoveUnusedDefitions()
        Gets whether unused definitions should be removed or not. Default value is true
        Returns:
        true if definitions are to be removed false if not.
        See Also:
        setRemoveUnusedDefinitions(boolean)
      • setRemoveUnusedDefinitions

        public void setRemoveUnusedDefinitions​(boolean value)
        Sets the remove unused definitions option. By removing unused definitions readability is increased.
        Default value is true
        Parameters:
        value - true if definitions are to be removed false if not.
        See Also:
        isRemoveUnusedDefitions()
      • isDisplayLabelsAndBoxes

        public boolean isDisplayLabelsAndBoxes()
        Gets whether bounding boxes and labels are to be displayed for the components of the search. Used only in case of similarity.
        Returns:
        true for boxes and labels to be displayed, false if no labels or boxes displayed.
      • setHitHomologyColor

        public void setHitHomologyColor​(Color hitHomologyColor)
        Set the color of user defined homologies in a substructure hit. Default: Color.green.
        Parameters:
        hitHomologyColor - color used for highlighting homolgies in a hit
      • getHitHomologyColor

        public Color getHitHomologyColor()
        Returns the color used for highlighting user defined homologies in a substructure hit. Default: Color.green.
        Returns:
        the color used for highlighting
      • setDisplayLabelsAndBoxes

        public void setDisplayLabelsAndBoxes​(boolean value)
        Set the option to show labels and bounding boxes for the parts of the result: target, query, score. Default is false.
        Parameters:
        value - true if labels and boxes to be displayed false otherwise.
      • isAcceptedOptionName

        public static boolean isAcceptedOptionName​(String optionName)
        Checks if the given option name can be a hit coloring and alignment option. The option value is not checked for validity.
        Parameters:
        optionName - the option in question
        Returns:
        true if it is an accepted option name.
      • setOptions

        public static void setOptions​(HitColoringAndAlignmentOptions hcaaOptions,
                                      String hitColorAndAlignOptionList)
        Parses the option list given while updating a HitColoringAndAlignmentOptions object. This can read in the option string returned by toString(String).
        Parameters:
        hcaaOptions - HitColoringAndAlignmentOptions to be updated based on option list provided
        hitColorAndAlignOptionList - options list to be parsed Can set multiple options. Name and value of an option should be separated by ":", and different pairs of names/values by spaces. Instead of spaces an alternative option separator string (even more than 1 character) can be specified at the beginning of optionString by the syntax "sep='separator string' ...". After 'separator string' there must be at least 1 space character!)
        E.g.
        • setOptions("hitColoring:y")
        • setOptions(" hitColoring:y align:r")
        • setOptions("sep=*-* align:r*-*markushDisplayMode:rhg")
        Throws:
        IllegalArgumentException - in case of wrong option value string
        See Also:
        toString(String)
      • clone

        public Object clone()
        Makes an identical copy of the Options
        Overrides:
        clone in class Object
        Returns:
        the copy
      • isColoringEnabled

        public boolean isColoringEnabled()
        Specifies if substructure hit coloring should be used. Default: false.
        Returns:
        true if substructure hit coloring should be used
        Since:
        JChem 5.10
      • setColoringEnabled

        public void setColoringEnabled​(boolean coloringEnabled)
        Sets whether substructure hit coloring should be used. Default: false.
        Parameters:
        coloringEnabled - true if substructure hit coloring should be used
        Since:
        JChem 5.10
      • getHitColor

        public Color getHitColor()
        Returns the color to be used when coloring the substructure hit. Default: Color.blue.
        Returns:
        the hitColor
        Since:
        JChem 5.10
      • setHitColor

        public void setHitColor​(Color hitColor)
        Sets the color to be used when coloring the substructure hit. Default: Color.blue.
        Parameters:
        hitColor - the hitColor to set
        Since:
        JChem 5.10
      • getNonHitColor

        public Color getNonHitColor()
        Returns the color to be used when coloring the part of the target which is not matching to the query. Default: Color.black.
        Returns:
        the nonHitColor
        Since:
        JChem 5.10
      • setNonHitColor

        public void setNonHitColor​(Color nonHitColor)
        Sets the color to be used when coloring the part of the target which is not matching to the query. Default: Color.black.
        Parameters:
        nonHitColor - the nonHitColor to set
        Since:
        JChem 5.10
      • getNonHitColor3D

        public Color getNonHitColor3D()
        Returns the color to be used when coloring the part of the 3D target which is not matching to the query. Default: Color.gray.
        Returns:
        the nonHitColor3D
        Since:
        JChem 5.10
      • setNonHitColor3D

        public void setNonHitColor3D​(Color nonHitColor3D)
        Sets the color to be used when coloring the part of the 3D target which is not matching to the query. Default: Color.gray.
        Parameters:
        nonHitColor3D - the nonHitColor3D to set
        Since:
        JChem 5.10
      • getSimilarityScoreDisplay

        public int getSimilarityScoreDisplay()
        Returns the mode of similarity score display. Possible values:
        Returns:
        the similarityScoreDisplay
        Since:
        JChem 5.10
      • setSimilarityScoreDisplay

        public void setSimilarityScoreDisplay​(int similarityScoreDisplay)
        Sets the mode of similarity score display. Possible values:
        Parameters:
        similarityScoreDisplay - the similarityScoreDisplay to set
        Since:
        JChem 5.10