Class ValencePropertyChecker

    • Field Detail

      • PROPERTY_KEY_DEFAULT_VALENCE

        public static final String PROPERTY_KEY_DEFAULT_VALENCE
        Search for valence properties that are equal to the default valence. These might be unnecessary.
        See Also:
        Constant Field Values
      • PROPERTY_KEY_NON_DEFAULT_VALENCE

        public static final String PROPERTY_KEY_NON_DEFAULT_VALENCE
        Search for valence properties that are not equal to the default valence.
        See Also:
        Constant Field Values
      • PROPERTY_KEY_SEARCH_DEFAULT_VALENCE

        public static final String PROPERTY_KEY_SEARCH_DEFAULT_VALENCE
        Search default valence property
        See Also:
        Constant Field Values
      • PROPERTY_KEY_SEARCH_NON_DEFAULT_VALENCE

        public static final String PROPERTY_KEY_SEARCH_NON_DEFAULT_VALENCE
        Search non default valence property
        See Also:
        Constant Field Values
    • Constructor Detail

      • ValencePropertyChecker

        public ValencePropertyChecker()
        Creates a new ValencePropertyChecker instance.
      • ValencePropertyChecker

        public ValencePropertyChecker​(Map<String,​String> params)
        Creates a new ValencePropertyChecker instance. If "default" parameter is given, and its value is "true" then it detects atoms having a valence property that is equal to the default valence of the current atom type. If "non-default" parameter given, and its value is "true" then it detects atoms having a valence property that is not equal to the default valence of the current atom type.
        Parameters:
        params - a Map instance which contains String pairs. Key is the name of the parameter.
    • Method Detail

      • check

        protected boolean check​(Molecule molecule,
                                MolAtom component)
        Description copied from class: ComponentChecker
        Checks if the component with index i has problem
        Specified by:
        check in class ComponentChecker<MolAtom>
        Parameters:
        molecule - is a Molecule instance
        component - the current component to check
        Returns:
        true if the component has problem, false otherwise
      • isSearchDefaultValence

        public boolean isSearchDefaultValence()
        Returns if the checker detects valence properties with the default valence of the current atom type.
        Returns:
        true if the checker detects default valence properties
      • isSearchNonDefaultValence

        public boolean isSearchNonDefaultValence()
        Returns if the checker detects valence properties with a non-default valence of the current atom type.
        Returns:
        true if the checker detects non-default valence properties
      • setSearchDefaultValence

        public void setSearchDefaultValence​(boolean value)
        Sets checker to detect valence properties with the default valence of the current atom type.
        Parameters:
        value - if true, the checker will detect atoms with default valence properties, otherwise not
      • setSearchNonDefaultValence

        public void setSearchNonDefaultValence​(boolean value)
        Sets checker to detect valence properties with non-default valence of the current atom type.
        Parameters:
        value - if true, the checker will detect atoms with non-default valence properties, otherwise not