org.jmol.api
public abstract class JmolAdapter extends Object
Nested Class Summary | |
---|---|
abstract class | JmolAdapter.AtomIterator
AtomIterator is used to enumerate all the clientAtom
objects in a specified frame.
|
abstract class | JmolAdapter.BondIterator
BondIterator is used to enumerate all the bonds
|
abstract class | JmolAdapter.StructureIterator
StructureIterator is used to enumerate Structures
Helix, Sheet, Turn
|
Field Summary | |
---|---|
String | adapterName |
static short | ORDER_AROMATIC |
static short | ORDER_AROMATIC_DOUBLE |
static short | ORDER_AROMATIC_SINGLE |
static short | ORDER_COVALENT_DOUBLE |
static short | ORDER_COVALENT_SINGLE |
static short | ORDER_COVALENT_TRIPLE |
static short | ORDER_HBOND |
static short | ORDER_PARTIAL01 |
static short | ORDER_PARTIAL12 |
static short | ORDER_PARTIAL23 |
static short | ORDER_PARTIAL32 |
static short | ORDER_STEREO_FAR |
static short | ORDER_STEREO_NEAR |
static short | ORDER_UNSPECIFIED |
static int | SHELL_D_CARTESIAN |
static int | SHELL_D_SPHERICAL |
static int | SHELL_F_CARTESIAN |
static int | SHELL_F_SPHERICAL |
static int | SHELL_L |
static int | SHELL_P |
static int | SHELL_S |
static int | SHELL_SP |
Constructor Summary | |
---|---|
JmolAdapter(String adapterName) |
Method Summary | |
---|---|
static String | canonicalizeQuantumSubshellTag(String tag) |
static char | canonizeAlphaDigit(char ch) |
static char | canonizeAlternateLocationID(char altLoc) |
static char | canonizeChainID(char chainID) |
static char | canonizeInsertionCode(char insertionCode) |
boolean | coordinatesAreFractional(Object clientFile)
Get the boolean whether coordinates are fractional. |
void | finish(Object clientFile) |
String | getAdapterName() |
abstract JmolAdapter.AtomIterator | getAtomIterator(Object clientFile)
Get an AtomIterator for retrieval of all atoms in the file.
|
Hashtable | getAtomSetAuxiliaryInfo(Object clientFile, int atomSetIndex)
Get the auxiliary information for a particular atomSet.
|
Hashtable | getAtomSetCollectionAuxiliaryInfo(Object clientFile)
Get the auxiliary information for this atomSetCollection.
|
String | getAtomSetCollectionName(Object clientFile)
Get the name of the atom set collection, if known.
|
Properties | getAtomSetCollectionProperties(Object clientFile)
Get the properties for this atomSetCollection.
|
int | getAtomSetCount(Object clientFile)
Get number of atomSets in the file.
|
String | getAtomSetName(Object clientFile, int atomSetIndex)
Get the name of an atomSet.
|
int | getAtomSetNumber(Object clientFile, int atomSetIndex)
Get the number identifying each atomSet.
|
Properties | getAtomSetProperties(Object clientFile, int atomSetIndex)
Get the properties for an atomSet.
|
JmolAdapter.BondIterator | getBondIterator(Object clientFile)
Get a BondIterator for retrieval of all bonds in the file.
|
String | getClientAtomStringProperty(Object clientAtom, String propertyName)
Get a property from a clientAtom.
|
static int | getElementNumber(String elementSymbol) |
static String | getElementSymbol(int elementNumber) |
abstract int | getEstimatedAtomCount(Object clientFile)
Get the estimated number of atoms contained in the file.
|
String | getFileTypeName(Object clientFile)
Get the type of this file or molecular model, if known. |
float[] | getNotionalUnitcell(Object clientFile)
Get the notional unit cell.
|
float[] | getPdbScaleMatrix(Object clientFile)
Get the PDB scale matrix.
|
float[] | getPdbScaleTranslate(Object clientFile)
Get the PDB scale translation vector.
|
static int | getQuantumShellTagID(String tag) |
static int | getQuantumShellTagIDSpherical(String tag) |
static String | getQuantumSubshellTag(int shell, int subshell) |
static int | getQuantumSubshellTagID(int shell, String tag) |
JmolAdapter.StructureIterator | getStructureIterator(Object clientFile)
Get a StructureIterator. |
static boolean | isHetero(String group3) |
static short | lookupGroupID(String group3) |
Object | openBufferedReader(String name, String type, BufferedReader bufferedReader, Hashtable htParams)
Associate a clientFile object with a bufferedReader.
|
Object | openBufferedReader(String name, BufferedReader bufferedReader) |
Object | openBufferedReader(String name, BufferedReader bufferedReader, Hashtable htParams) |
Object | openBufferedReader(String name, String type, BufferedReader bufferedReader) |
Object | openBufferedReaders(JmolFileReaderInterface fileReader, String[] names, String[] types, Hashtable[] htParams)
Associate a clientFile object with an array of BufferedReader.
|
Object | openDOMReader(Object DOMNode) |
Object | openZipFiles(InputStream is, String fileName, String[] zipDirectory, Hashtable htParams, boolean asBufferedReader) |
String[] | specialLoad(String name, String type) |
Parameters: clientFile The client file
Returns: true if the coordinates are fractional, default false
This method may not return null
.
Parameters: clientFile The client file
Returns: An AtomIterator
See Also: AtomIterator
Via the smarterJmolAdapter
Parameters: clientFile The client file atomSetIndex The atom set index
Returns: The auxiliaryInfo Hashtable that may be available for particular
filetypes for this atomSet or null
Via the smarterJmolAdapter
Parameters: clientFile The client file
Returns: The auxiliaryInfo Hashtable that may be available for particular
filetypes for this atomSetCollection or null
Some file formats contain a formal name of the molecule in the file.
If this method returns null
then the JmolViewer will
automatically supply the file/URL name as a default.
Parameters: clientFile
Returns: The atom set collection name or null
Not yet implemented everywhere, it is in the smarterJmolAdapter
Parameters: clientFile The client file
Returns: The properties for this atomSetCollection or null
NOTE WARNING:
Not yet implemented everywhere, it is in the smarterJmolAdapter
Parameters: clientFile The client file
Returns: The number of atomSets in the file, default 1
Parameters: clientFile The client file atomSetIndex The atom set index
Returns: The name of the atom set, default the string representation of atomSetIndex
For a PDB file, this is is the model number. For others it is a 1-based atomSet number.
Note that this is not currently implemented in PdbReader
Parameters: clientFile The client file atomSetIndex The atom set's index for which to get the atom set number
Returns: The number identifying each atom set, default atomSetIndex+1.
Parameters: clientFile The client file atomSetIndex The atom set index
Returns: The properties for an atom set or null
If this method returns null
and no
bonds are defined then the JmolViewer will automatically apply its
rebonding code to build bonds between atoms.
Parameters: clientFile The client file
Returns: A BondIterator or null
See Also: BondIterator
Parameters: clientAtom The clientAtom propertyName the key of the property
Returns: The value of the property
Just return -1 if you don't know (or don't want to figure it out)
Parameters: clientFile The client file
Returns: The estimated number of atoms in the file
Parameters: clientFile The client file
Returns: The type of this file or molecular model, default
"unknown"
This method returns the parameters that define a crystal unitcell
the parameters are returned in a float[] in the following order
a, b, c, alpha, beta, gamma
a, b, c
: angstroms
alpha, beta, gamma
: degrees
if there is no unit cell data then return null
Parameters: clientFile The client file
Returns: The array of the values or null
Does not seem to be overriden by any descendent
Parameters: clientFile The client file
Returns: The array of 9 floats for the matrix or null
Does not seem to be overriden by any descendent
Parameters: clientFile The client file
Returns: The x, y and z translation values or null
Parameters: clientFile The client file
Returns: A StructureIterator or null
Given the BufferedReader, return an object which represents the file
contents. The parameter name
is assumed to be the
file name or URL which is the source of reader. Note that this 'file'
may have been automatically decompressed. Also note that the name
may be 'String', representing a string constant. Therefore, few
assumptions should be made about the name
parameter.
The return value is an object which represents a clientFile
.
This clientFile
will be passed back in to other methods.
If the return value is instanceof String
then it is
considered an error condition and the returned String is the error
message.
Parameters: name File name, String or URL acting as the source of the reader type File type, if known, or null bufferedReader The BufferedReader htParams a hash table containing parameter information
Returns: The clientFile or String with an error message
Given the array of BufferedReader, return an object which represents
the concatenation of every file contents. The parameter name
is assumed to be the file names or URL which are the source of each
reader. Note that each of this 'file' may have been automatically
decompressed. Also note that the name may be 'String',
representing a string constant. Therefore, few
assumptions should be made about the name
parameter.
The return value is an object which represents a clientFile
.
This clientFile
will be passed back in to other methods.
If the return value is instanceof String
then it is
considered an error condition and the returned String is the error
message.
Parameters: fileReader the thread requesting a set of files if bufferedReaders is null names File names, String or URL acting as the source of each reader types File types, if known, or null htParams The input parameters for each file to load
Returns: The clientFile or String with an error message