Class RGroupQueryWriter

  • All Implemented Interfaces:
    Closeable, AutoCloseable, IChemObjectIO, IChemObjectWriter

    public class RGroupQueryWriter
    extends DefaultChemObjectWriter
    A writer for Symyx' Rgroup files (RGFiles).
    An RGfile describes a single molecular query with Rgroups. Each RGfile is a combination of Ctabs defining the root molecule and each member of each Rgroup in the query.
    This class relies on the MDLV2000Writer to create CTAB data blocks.
    Author:
    Mark Rijnbeek
    Source code:
    main
    Belongs to CDK module:
    io
    Keywords:
    Rgroup, R group, R-group
    • Constructor Detail

      • RGroupQueryWriter

        public RGroupQueryWriter​(Writer out)
        Constructs a new writer that can write an IRGroupQuery to the Symx RGFile format.
        Parameters:
        out - The Writer to write to
      • RGroupQueryWriter

        public RGroupQueryWriter()
        Zero argument constructor.
    • Method Detail

      • accepts

        public boolean accepts​(Class<? extends IChemObject> classObject)
        Returns true for accepted input types.
        Parameters:
        classObject - IChemObject of which is tested if it can be handled.
        Returns:
        true, if the IChemObject can be handled.
      • close

        public void close()
                   throws IOException
        Flushes the output and closes this object.
        Throws:
        IOException - when the wrapper IO class cannot be closed.
      • write

        public void write​(IChemObject object)
                   throws CDKException
        The actual writing of the output.
        Parameters:
        object - the object of which the content is outputted
        Throws:
        CDKException - could not write RGroup query