Class AtomContext

  • All Implemented Interfaces:
    ChemContext, chemaxon.marvin.util.CallbackIface, Serializable

    @PublicAPI
    public class AtomContext
    extends MolContext
    Expression evaluation context containing an input molecule and an input atom. Provides function names for accessing context elements through the CallbackIface.
    Since:
    JChem 2.2, Marvin 5.1
    See Also:
    Serialized Form
    • Field Detail

      • CFNS

        public static String[] CFNS
        The context function names.
    • Constructor Detail

      • AtomContext

        public AtomContext()
        Constructor.
    • Method Detail

      • callback

        public Object callback​(String method,
                               Object arg)
        Implements CallbackIface. Returns null for unimplemented callbacks. Implemented callbacks:
        methodargreturn value
        "mol"nullthe input molecule
        "fingerprint"nullthe input molecule fingerprint
        "atom"nullthe input atom
        Specified by:
        callback in interface chemaxon.marvin.util.CallbackIface
        Specified by:
        callback in interface ChemContext
        Overrides:
        callback in class MolContext
        Parameters:
        method - is the accessor method name
        arg - 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)
        Returns:
        the context element
      • setAtom

        public void setAtom​(int atom)
        Sets the input atom.
        Parameters:
        atom - is the input atom index
      • getAtom

        public int getAtom()
        Returns the input atom index.
        Returns:
        the input atom index