|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectchemaxon.jep.ChemContext
chemaxon.jep.context.MolContext
public class MolContext
Expression evaluation context containing a single molecule.
Provides function names for accessing context elements
through the CallbackIface
.
Field Summary | |
---|---|
static java.lang.String[] |
CFNS
The context function names. |
Constructor Summary | |
---|---|
MolContext()
Constructor. |
|
MolContext(Molecule m)
Creates a MolContext with the given input molecule. |
Method Summary | |
---|---|
java.lang.Object |
callback(java.lang.String method,
java.lang.Object arg)
Implements CallbackIface . |
void |
clear()
Clears the context. |
java.lang.String[] |
getContextFunctionNames()
Returns {"mol", "fingerprint"}. |
int[] |
getFingerprint()
Returns the input molecule fingerprint. |
protected int[] |
getFingerprint(java.lang.Object arg)
Returns the input molecule fingerprint if argument is the input molecule, null otherwise. |
Molecule |
getMolecule()
Returns the input molecule. |
void |
setFingerprint(int[] fingerprint)
Sets the fingerprint of the input molecule. |
void |
setMolecule(Molecule mol)
Sets the input molecule. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.lang.String[] CFNS
Constructor Detail |
---|
public MolContext()
public MolContext(Molecule m)
Method Detail |
---|
public java.lang.String[] getContextFunctionNames()
getContextFunctionNames
in class ChemContext
public java.lang.Object callback(java.lang.String method, java.lang.Object arg)
CallbackIface
.
Returns null
for unimplemented callbacks.
Implemented callbacks:
method | arg | return value |
---|---|---|
"mol" | null | the input molecule |
"fingerprint" | null | the input molecule fingerprint |
callback
in interface chemaxon.marvin.util.CallbackIface
callback
in class ChemContext
method
- is the accessor method namearg
- is the accessor method argument (the JEP parameter stack as null
,
a single parameter object or a parameter object array depending on the number
of parameters on the stack)
public void setMolecule(Molecule mol)
mol
- is the input moleculepublic Molecule getMolecule()
public void setFingerprint(int[] fingerprint)
fingerprint
- is the fingerprintpublic int[] getFingerprint()
protected int[] getFingerprint(java.lang.Object arg)
null
otherwise.
arg
- is the argument to be checked against the input molecule
null
public void clear()
clear
in class ChemContext
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |