chemaxon.util
Class HitDisplayTool

java.lang.Object
  extended bychemaxon.util.HitDisplayTool
All Implemented Interfaces:
SearchConstants

public class HitDisplayTool
extends java.lang.Object
implements SearchConstants

Class for displaying hit results with hit coloring, alignment, partial clean, etc.

Since:
JChem 5.0
Author:
Szilard Dorant

Field Summary
 
Fields inherited from interface chemaxon.sss.SearchConstants
ABS_STEREO_ALWAYS_ON, ABS_STEREO_CHIRAL_FLAG, ABS_STEREO_TABLE_OPTION, CHARGE_MATCHING_DEFAULT, CHARGE_MATCHING_EXACT, CHARGE_MATCHING_IGNORE, DEFAULT_DISSIMILARITY_THRESHOLD, DEFAULT_SIMILARITY_THRESHOLD, DISSIMILARITY, EXACT, EXACT_FRAGMENT, EXACT_FRAGMENT_OFF, EXACT_FRAGMENT_ON, HCOUNT_MATCHING_AUTO, HCOUNT_MATCHING_EQUAL, HCOUNT_MATCHING_GREATER_OR_EQUAL, IMPLICIT_H_MATCHING_DEFAULT, IMPLICIT_H_MATCHING_DISABLED, IMPLICIT_H_MATCHING_ENABLED, ISOTOPE_MATCHING_DEFAULT, ISOTOPE_MATCHING_EXACT, ISOTOPE_MATCHING_IGNORE, KEEP_QUERY_ORDER, MARKUSH_AROM_FINAL_CHECK, MARKUSH_AROM_NO_FINAL_CHECK, MARKUSH_AROM_OFF, MARKUSH_DISABLED, MARKUSH_ENABLED, MARKUSH_HIT_ORIGINAL, MARKUSH_HIT_SUPERGRAPH, MATCH_COUNT_BETWEEN, MATCH_COUNT_RELATION, MIX_SGROUP_MATCHING_OFF, MIX_SGROUP_MATCHING_ON, NO_ABAS, NO_SCREEN, OPTION_CHARGE_MATCHING, OPTION_EXACT_FRAGMENT, OPTION_ISOTOPE_MATCHING, OPTION_KEEP_QUERY_ORDER, OPTION_MARKUSH_AROM, OPTION_MARKUSH_ENABLED, OPTION_MARKUSH_HIT, OPTION_MIX_SGROUP_MATCHING, OPTION_RADICAL_MATCHING, OPTION_STEREO_MODEL, OPTION_TAUTOMER_SEARCH, OPTION_VAGUE_BOND, OPTION_VALENCE_MATCHING, PERFECT, R_NODE_PLACEHOLDER, RADICAL_MATCHING_DEFAULT, RADICAL_MATCHING_EXACT, RADICAL_MATCHING_IGNORE, REARRANGE_QUERY, REGULAR_SEARCH, SEARCH_MODE_NAMES, SEARCH_OPTIONS_LENGTH, SIMILARITY, STEREO_MODEL_COMPREHENSIVE, STEREO_MODEL_DEFAULT, STEREO_MODEL_GLOBAL, STEREO_MODEL_LOCAL, SUBSTRUCTURE, SUPERSTRUCTURE, TAUTOMER_SEARCH_OFF, TAUTOMER_SEARCH_ON, VAGUE_BOND_DEFAULT, VAGUE_BOND_LEVEL1, VAGUE_BOND_LEVEL2, VAGUE_BOND_LEVEL3, VAGUE_BOND_LEVEL4, VAGUE_BOND_OFF, VALENCE_MATCHING_IGNORE, VALENCE_MATCHING_ON
 
Constructor Summary
HitDisplayTool(HitColoringAndAlignmentOptions options, MolSearchOptions searchOptions, Standardizer standardizer, Molecule query)
          Constructor.
 
Method Summary
 Molecule getHit(Molecule target)
          Processes the next target structure.
 java.util.ArrayList getHitIndexes()
          Returns the hit indexes for the last target.
 Molecule[] getHits(Molecule target, chemaxon.enumeration.supergraph.Supergraph markushSupergraph, int maxHitCount)
          Processes the next target structure.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HitDisplayTool

public HitDisplayTool(HitColoringAndAlignmentOptions options,
                      MolSearchOptions searchOptions,
                      Standardizer standardizer,
                      Molecule query)
Constructor.

Parameters:
options - options for coloring and alignment
searchOptions - search options
standardizer - this Standardizer will be used during the search process, or null for only aromatization.
query - the query structure
Method Detail

getHit

public Molecule getHit(Molecule target)
                throws chemaxon.sss.search.SearchException,
                       chemaxon.enumeration.supergraph.SupergraphException
Processes the next target structure.

Parameters:
target - the target
Returns:
the structure to be displayed, or null if there was no hit
Throws:
chemaxon.sss.search.SearchException
chemaxon.enumeration.supergraph.SupergraphException

getHits

public Molecule[] getHits(Molecule target,
                          chemaxon.enumeration.supergraph.Supergraph markushSupergraph,
                          int maxHitCount)
                   throws chemaxon.sss.search.SearchException,
                          chemaxon.enumeration.supergraph.SupergraphException
Processes the next target structure.

Parameters:
target - the target
markushSupergraph - a standardized markush supergraph can be specified here if present, or null
maxHitCount - specify 0 to get back all the hits found, or an arbitrary limit.
Specify -1 to get back only a single hit, the best fitting is returned in case of alignment (default).
Returns:
the structures to be displayed, or a zero sized array if there were no hits
Throws:
chemaxon.sss.search.SearchException
chemaxon.enumeration.supergraph.SupergraphException

getHitIndexes

public java.util.ArrayList getHitIndexes()
Returns the hit indexes for the last target. Can be called after getHit(chemaxon.struc.Molecule) or getHits(chemaxon.struc.Molecule, chemaxon.enumeration.supergraph.Supergraph, int)

Returns:
the hit indexes in an ArrayList, containing int[] elements.