Class SolutionCompleteGraph
- java.lang.Object
-
- com.actelion.research.util.graph.complete.AMemorizedObject
-
- com.actelion.research.util.graph.complete.SolutionCompleteGraph
-
- All Implemented Interfaces:
java.lang.Comparable<SolutionCompleteGraph>
- Direct Known Subclasses:
ModelSolutionSimilarity
public class SolutionCompleteGraph extends AMemorizedObject implements java.lang.Comparable<SolutionCompleteGraph>
SolutionCompleteGraphCopyright: Actelion Ltd., Inc. All Rights Reserved This software is the proprietary information of Actelion Pharmaceuticals, Ltd. Use is subject to license terms.
- Version:
- 1.0 Oct 1, 2012 MvK: Start implementation
- Author:
- Modest von Korff
-
-
Constructor Summary
Constructors Constructor Description SolutionCompleteGraph()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(byte indexNodeQuery, byte indexNodeBase)Adds a pair of nodes to this solution.intcompareTo(SolutionCompleteGraph s)voidcopyIntoThis(AMemorizedObject a)Has to be a deep copybooleanequals(java.lang.Object obj)bytegetIndexBaseFromHeap(int indexOnHeapBase)bytegetIndexCorrespondingBaseNode(int indexQueryNode)bytegetIndexQueryFromHeap(int indexOnHeapQuery)intgetNodesQuery()doublegetSimilarity()intgetSizeHeap()byte[]getSolution()The index is the index of the node in the query molecule.inthashCode()voidreset()voidsetNodesQuery(int nodes)Only needed for the toString() method.voidsetSimilarity(double similarity)java.lang.StringtoString()-
Methods inherited from class com.actelion.research.util.graph.complete.AMemorizedObject
getPositionInContainer, setPositionInContainer
-
-
-
-
Method Detail
-
add
public void add(byte indexNodeQuery, byte indexNodeBase)Adds a pair of nodes to this solution.- Parameters:
indexNodeBase- index of the base node in the complete base graph.indexNodeQuery- index of the query node in the complete query graph.
-
compareTo
public int compareTo(SolutionCompleteGraph s)
- Specified by:
compareToin interfacejava.lang.Comparable<SolutionCompleteGraph>
-
getSizeHeap
public int getSizeHeap()
-
getIndexBaseFromHeap
public byte getIndexBaseFromHeap(int indexOnHeapBase)
-
getIndexQueryFromHeap
public byte getIndexQueryFromHeap(int indexOnHeapQuery)
-
getIndexCorrespondingBaseNode
public byte getIndexCorrespondingBaseNode(int indexQueryNode)
-
getSolution
public byte[] getSolution()
The index is the index of the node in the query molecule. The value at 'index' is the index of the node in the base molecule.
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
copyIntoThis
public void copyIntoThis(AMemorizedObject a)
Description copied from class:AMemorizedObjectHas to be a deep copy- Specified by:
copyIntoThisin classAMemorizedObject
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
reset
public void reset()
- Specified by:
resetin classAMemorizedObject
-
getSimilarity
public double getSimilarity()
-
setSimilarity
public void setSimilarity(double similarity)
-
setNodesQuery
public void setNodesQuery(int nodes)
Only needed for the toString() method.- Parameters:
nodes-
-
getNodesQuery
public int getNodesQuery()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-