Mercurial > repos > deepakjadmin > mayatool3_test2
comparison docs/modules/html/SDFileIO.html @ 0:4816e4a8ae95 draft default tip
Uploaded
| author | deepakjadmin |
|---|---|
| date | Wed, 20 Jan 2016 09:23:18 -0500 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:4816e4a8ae95 |
|---|---|
| 1 <html> | |
| 2 <head> | |
| 3 <title>MayaChemTools:Documentation:FileIO::SDFileIO.pm</title> | |
| 4 <meta http-equiv="content-type" content="text/html;charset=utf-8"> | |
| 5 <link rel="stylesheet" type="text/css" href="../../css/MayaChemTools.css"> | |
| 6 </head> | |
| 7 <body leftmargin="20" rightmargin="20" topmargin="10" bottommargin="10"> | |
| 8 <br/> | |
| 9 <center> | |
| 10 <a href="http://www.mayachemtools.org" title="MayaChemTools Home"><img src="../../images/MayaChemToolsLogo.gif" border="0" alt="MayaChemTools"></a> | |
| 11 </center> | |
| 12 <br/> | |
| 13 <div class="DocNav"> | |
| 14 <table width="100%" border=0 cellpadding=0 cellspacing=2> | |
| 15 <tr align="left" valign="top"><td width="33%" align="left"><a href="./MDLMolFileIO.html" title="MDLMolFileIO.html">Previous</a> <a href="./index.html" title="Table of Contents">TOC</a> <a href="./FileUtil.html" title="FileUtil.html">Next</a></td><td width="34%" align="middle"><strong>FileIO::SDFileIO.pm</strong></td><td width="33%" align="right"><a href="././code/SDFileIO.html" title="View source code">Code</a> | <a href="./../pdf/SDFileIO.pdf" title="PDF US Letter Size">PDF</a> | <a href="./../pdfgreen/SDFileIO.pdf" title="PDF US Letter Size with narrow margins: www.changethemargins.com">PDFGreen</a> | <a href="./../pdfa4/SDFileIO.pdf" title="PDF A4 Size">PDFA4</a> | <a href="./../pdfa4green/SDFileIO.pdf" title="PDF A4 Size with narrow margins: www.changethemargins.com">PDFA4Green</a></td></tr> | |
| 16 </table> | |
| 17 </div> | |
| 18 <p> | |
| 19 </p> | |
| 20 <h2>NAME</h2> | |
| 21 <p>SDFileIO</p> | |
| 22 <p> | |
| 23 </p> | |
| 24 <h2>SYNOPSIS</h2> | |
| 25 <p>use FileIO::SDFileIO;</p> | |
| 26 <p>use FileIO::SDFileIO qw(:all);</p> | |
| 27 <p> | |
| 28 </p> | |
| 29 <h2>DESCRIPTION</h2> | |
| 30 <p><strong>SDFIleIO</strong> class provides the following methods:</p> | |
| 31 <p> <a href="#new">new</a>, <a href="#generatemoleculestring">GenerateMoleculeString</a>, <a href="#issdfile">IsSDFile</a>, <a href="#parsemoleculestring">ParseMoleculeString</a>, <a href="#readmolecule">ReadMolecule</a> | |
| 32 , <a href="#readmoleculestring">ReadMoleculeString</a>, <a href="#writemolecule">WriteMolecule</a> | |
| 33 </p><p>The following methods can also be used as functions:</p> | |
| 34 <p>GenerateMoleculeString, IsSDFile, ParseMoleculeString</p> | |
| 35 <p>Data specific to <strong>SDFileIO</strong> class not directly used by <strong>Molecule</strong>, <strong>Atom</strong> and | |
| 36 <strong>Bond</strong> objects - data label/value pairs, atom SteroParity and so on - is associated to | |
| 37 and retrieved from approptiate objects using following methods:</p> | |
| 38 <div class="OptionsBox"> | |
| 39 SetMDL<PropertyName> | |
| 40 <br/> GetMDL<PropertyName>.</div> | |
| 41 <p>SD data label and values are attached to <strong>Molecule</strong> object as a refernece to a hash | |
| 42 using SetDataFieldLabelAndValues and can be retrieved using GetDataFieldLabelAndValues | |
| 43 method.</p> | |
| 44 <p><strong>SDFileIO</strong> class is derived from <em>FileIO</em> class and uses its methods to support | |
| 45 generic file related functionality.</p> | |
| 46 <p> | |
| 47 </p> | |
| 48 <h2>METHODS</h2> | |
| 49 <dl> | |
| 50 <dt><strong><a name="new" class="item"><strong>new</strong></a></strong></dt> | |
| 51 <dd> | |
| 52 <div class="OptionsBox"> | |
| 53 $NewSDFileIO = new FileIO::SDFileIO(%NamesAndValues);</div> | |
| 54 <p>Using specified <em>SDFileIO</em> property names and values hash, <strong>new</strong> method creates a new object | |
| 55 and returns a reference to newly created <strong>SDFileIO</strong> object.</p> | |
| 56 </dd> | |
| 57 <dt><strong><a name="generatemoleculestring" class="item"><strong>GenerateMoleculeString</strong></a></strong></dt> | |
| 58 <dd> | |
| 59 <div class="OptionsBox"> | |
| 60 $MoleculeString = $SDFileIO->GenerateMoleculeString($Molecule); | |
| 61 <br/> $MoleculeString = FileIO::SDFileIO::GenerateMoleculeString($Molecule);</div> | |
| 62 <p>Returns a <strong>MoleculeString</strong> in SD format corresponding to <em>Molecule</em>.</p> | |
| 63 </dd> | |
| 64 <dt><strong><a name="issdfile" class="item"><strong>IsSDFile</strong></a></strong></dt> | |
| 65 <dd> | |
| 66 <div class="OptionsBox"> | |
| 67 $Status = $SDFileIO->IsSDFile($FileName); | |
| 68 <br/> $Status = FileIO::SDFileIO::IsSDFile($FileName);</div> | |
| 69 <p>Returns 1 or 0 based on whether <em>FileName</em> is a SD file.</p> | |
| 70 </dd> | |
| 71 <dt><strong><a name="parsemoleculestring" class="item"><strong>ParseMoleculeString</strong></a></strong></dt> | |
| 72 <dd> | |
| 73 <div class="OptionsBox"> | |
| 74 $Molecule = $SDFileIO->ParseMoleculeString($MoleculeString); | |
| 75 <br/> $Molecule = FileIO::SDFileIO::ParseMoleculeString($MoleculeString);</div> | |
| 76 <p>Parses <em>MoleculeString</em> and returns a <strong>Molecule</strong> object. SD data field label and value pairs | |
| 77 are associated to <strong>Molecule</strong> object as a reference to a hash using:</p> | |
| 78 <div class="OptionsBox"> | |
| 79 $Molecule->SetDataFieldLabelAndValues(\%DataLabelsAndValues)</div> | |
| 80 <p>The reference to hash can be retrieved by:</p> | |
| 81 <div class="OptionsBox"> | |
| 82 $DataLabelsAndValues = $Molecule->GetDataFieldLabelAndValues(); | |
| 83 <br/> for $DataLabel (sort keys %{$DataLabelsAndValues}) { | |
| 84 <br/> $DataValue = $DataLabelsAndValues->{$DataLabel}; | |
| 85 <br/> }</div> | |
| 86 </dd> | |
| 87 <dt><strong><a name="readmolecule" class="item"><strong>ReadMolecule</strong></a></strong></dt> | |
| 88 <dd> | |
| 89 <div class="OptionsBox"> | |
| 90 $Molecule = $SDFileIO->ReadMolecule($FileHandle);</div> | |
| 91 <p>Reads data for the next compound in a file using already opened <em>FileHandle</em>, creates, | |
| 92 and returns a <strong>Molecule</strong> object.</p> | |
| 93 </dd> | |
| 94 <dt><strong><a name="readmoleculestring" class="item"><strong>ReadMoleculeString</strong></a></strong></dt> | |
| 95 <dd> | |
| 96 <div class="OptionsBox"> | |
| 97 $MoleculeString = $SDFileIO->ReadMoleculeString($FileHandle);</div> | |
| 98 <p>Reads data for the next compound in a file using already opened <em>FileHandle</em> and | |
| 99 returns a <strong>MoleculeString</strong> corresponding to compound structure and other associated | |
| 100 data.</p> | |
| 101 </dd> | |
| 102 <dt><strong><a name="writemolecule" class="item"><strong>WriteMolecule</strong></a></strong></dt> | |
| 103 <dd> | |
| 104 <div class="OptionsBox"> | |
| 105 $SDFileIO->WriteMolecule($Molecule);</div> | |
| 106 <p>Writes <em>Molecule</em> data to a file in MDLMol format and returns <strong>SDFileIO</strong>.</p> | |
| 107 </dd> | |
| 108 </dl> | |
| 109 <p> | |
| 110 </p> | |
| 111 <h2>AUTHOR</h2> | |
| 112 <p><a href="mailto:msud@san.rr.com">Manish Sud</a></p> | |
| 113 <p> | |
| 114 </p> | |
| 115 <h2>SEE ALSO</h2> | |
| 116 <p><a href="./MoleculeFileIO.html">MoleculeFileIO.pm</a>, <a href="./MDLMolFileIO.html">MDLMolFileIO.pm</a> | |
| 117 </p> | |
| 118 <p> | |
| 119 </p> | |
| 120 <h2>COPYRIGHT</h2> | |
| 121 <p>Copyright (C) 2015 Manish Sud. All rights reserved.</p> | |
| 122 <p>This file is part of MayaChemTools.</p> | |
| 123 <p>MayaChemTools is free software; you can redistribute it and/or modify it under | |
| 124 the terms of the GNU Lesser General Public License as published by the Free | |
| 125 Software Foundation; either version 3 of the License, or (at your option) | |
| 126 any later version.</p> | |
| 127 <p> </p><p> </p><div class="DocNav"> | |
| 128 <table width="100%" border=0 cellpadding=0 cellspacing=2> | |
| 129 <tr align="left" valign="top"><td width="33%" align="left"><a href="./MDLMolFileIO.html" title="MDLMolFileIO.html">Previous</a> <a href="./index.html" title="Table of Contents">TOC</a> <a href="./FileUtil.html" title="FileUtil.html">Next</a></td><td width="34%" align="middle"><strong>March 29, 2015</strong></td><td width="33%" align="right"><strong>FileIO::SDFileIO.pm</strong></td></tr> | |
| 130 </table> | |
| 131 </div> | |
| 132 <br /> | |
| 133 <center> | |
| 134 <img src="../../images/h2o2.png"> | |
| 135 </center> | |
| 136 </body> | |
| 137 </html> |
