toxTree.tree.rules
Class InChILookupFile

java.lang.Object
  extended by toxTree.tree.rules.InChILookupFile
All Implemented Interfaces:
ILookupFile

public class InChILookupFile
extends java.lang.Object
implements ILookupFile

In-memory InChI lookup. Should be fine for few hundreds compounds found in bodymol & foodmol.

Author:
nina

Field Summary
protected  java.io.File file
           
protected  ambit2.core.processors.structure.InchiProcessor inchiProcessor
           
protected  java.util.List<java.lang.String> inchis
           
 
Constructor Summary
InChILookupFile(java.io.File file)
           
 
Method Summary
 boolean find(org.openscience.cdk.interfaces.IAtomContainer mol)
           
 java.io.File getFile()
           
 boolean isEnabled()
           
 void readFile()
           
 void readFileInchi()
           
 void setFile(java.io.File file)
           
 int size()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

file

protected java.io.File file

inchiProcessor

protected ambit2.core.processors.structure.InchiProcessor inchiProcessor

inchis

protected java.util.List<java.lang.String> inchis
Constructor Detail

InChILookupFile

public InChILookupFile(java.io.File file)
                throws java.io.IOException,
                       org.openscience.cdk.exception.CDKException
Throws:
java.io.IOException
org.openscience.cdk.exception.CDKException
Method Detail

find

public boolean find(org.openscience.cdk.interfaces.IAtomContainer mol)
             throws DecisionMethodException
Specified by:
find in interface ILookupFile
Throws:
DecisionMethodException

readFileInchi

public void readFileInchi()
                   throws java.lang.Exception
Throws:
java.lang.Exception

readFile

public void readFile()
              throws java.lang.Exception
Throws:
java.lang.Exception

isEnabled

public boolean isEnabled()
Specified by:
isEnabled in interface ILookupFile

getFile

public java.io.File getFile()
Specified by:
getFile in interface ILookupFile

setFile

public void setFile(java.io.File file)
             throws java.io.IOException
Specified by:
setFile in interface ILookupFile
Throws:
java.io.IOException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

size

public int size()
Specified by:
size in interface ILookupFile


Copyright © 2004-2012 Ideaconsult Ltd.. All Rights Reserved.