public abstract class JmolAdapter
extends java.lang.Object
JmolViewer
,
SmarterJmolAdapter
Modifier and Type | Class and Description |
---|---|
class |
JmolAdapter.AtomIterator
AtomIterator is used to enumerate all the
clientAtom
objects in a specified frame. |
class |
JmolAdapter.BondIterator
BondIterator is used to enumerate all the bonds
|
class |
JmolAdapter.StructureIterator
StructureIterator is used to enumerate Structures
Helix, Sheet, Turn
|
Modifier and Type | Field and Description |
---|---|
(package private) java.lang.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 |
static java.lang.String |
SUPPORTED_BASIS_FUNCTIONS |
Constructor and Description |
---|
JmolAdapter(java.lang.String adapterName) |
Modifier and Type | Method and Description |
---|---|
static char |
canonizeAlphaDigit(char ch) |
static char |
canonizeAlternateLocationID(char altLoc) |
static char |
canonizeChainID(char chainID) |
static char |
canonizeInsertionCode(char insertionCode) |
abstract boolean |
coordinatesAreFractional(java.lang.Object atomSetCollection)
Get the boolean whether coordinates are fractional.
|
void |
finish(java.lang.Object atomSetCollection) |
java.lang.String |
getAdapterName() |
abstract int |
getAtomCount(java.lang.Object atomSetCollection)
Get the estimated number of atoms contained in the file.
|
abstract JmolAdapter.AtomIterator |
getAtomIterator(java.lang.Object atomSetCollection)
Get an AtomIterator for retrieval of all atoms in the file.
|
abstract java.util.Map<java.lang.String,java.lang.Object> |
getAtomSetAuxiliaryInfo(java.lang.Object atomSetCollection,
int atomSetIndex)
Get the auxiliary information for a particular atomSet.
|
abstract java.lang.Object |
getAtomSetCollection(java.lang.Object atomSetCollectionReader) |
abstract java.util.Map<java.lang.String,java.lang.Object> |
getAtomSetCollectionAuxiliaryInfo(java.lang.Object atomSetCollection)
Get the auxiliary information for this atomSetCollection.
|
abstract java.lang.Object |
getAtomSetCollectionFromDOM(java.lang.Object DOMNode,
java.util.Map<java.lang.String,java.lang.Object> htParams) |
java.lang.Object |
getAtomSetCollectionFromReader(java.lang.String name,
java.lang.String type,
java.io.BufferedReader bufferedReader,
java.util.Map<java.lang.String,java.lang.Object> htParams)
all in one -- for TestSmarterJmolAdapter
|
abstract java.lang.Object |
getAtomSetCollectionFromSet(java.lang.Object readers,
java.lang.Object atomSets,
java.util.Map<java.lang.String,java.lang.Object> htParams) |
abstract java.lang.String |
getAtomSetCollectionName(java.lang.Object atomSetCollection)
Get the name of the atom set collection, if known.
|
abstract java.lang.Object |
getAtomSetCollectionOrBufferedReaderFromZip(java.io.InputStream is,
java.lang.String fileName,
java.lang.String[] zipDirectory,
java.util.Map<java.lang.String,java.lang.Object> htParams,
boolean asBufferedReader,
boolean asBufferendInputStream) |
abstract java.lang.Object |
getAtomSetCollectionReader(java.lang.String name,
java.lang.String type,
java.io.BufferedReader bufferedReader,
java.util.Map<java.lang.String,java.lang.Object> htParams)
Read an atomSetCollection object from a bufferedReader and close the reader.
|
abstract java.lang.Object |
getAtomSetCollectionReaders(JmolFilesReaderInterface fileReader,
java.lang.String[] names,
java.lang.String[] types,
java.util.Map<java.lang.String,java.lang.Object> htParams,
boolean getReadersOnly)
Associate a atomSetCollection object with an array of BufferedReader.
|
abstract int |
getAtomSetCount(java.lang.Object atomSetCollection)
Get number of atomSets in the file.
|
abstract java.lang.String |
getAtomSetName(java.lang.Object atomSetCollection,
int atomSetIndex)
Get the name of an atomSet.
|
abstract int |
getAtomSetNumber(java.lang.Object atomSetCollection,
int atomSetIndex)
Get the number identifying each atomSet.
|
static float |
getBondingRadiusFloat(short atomicNumberWithIsotope,
int charge) |
abstract JmolAdapter.BondIterator |
getBondIterator(java.lang.Object atomSetCollection)
Get a BondIterator for retrieval of all bonds in the file.
|
abstract java.lang.String[][] |
getBondList(java.lang.Object atomSetCollection) |
static short |
getElementNumber(java.lang.String elementSymbol) |
static java.lang.String |
getElementSymbol(int elementNumber) |
abstract java.lang.String |
getFileTypeName(java.lang.Object atomSetCollection)
Get the type of this file or molecular model, if known.
|
abstract int |
getHydrogenAtomCount(java.lang.Object atomSetCollection)
Get the hydrogen atom count -- for ligand files
|
static int |
getNaturalIsotope(int elementNumber) |
static int[][] |
getNewDfCoefMap() |
abstract float[] |
getNotionalUnitcell(java.lang.Object atomSetCollection)
Get the notional unit cell.
|
abstract float[] |
getPdbScaleMatrix(java.lang.Object atomSetCollection)
Get the PDB scale matrix.
|
abstract float[] |
getPdbScaleTranslate(java.lang.Object atomSetCollection)
Get the PDB scale translation vector.
|
static int |
getQuantumShellTagID(java.lang.String tag) |
static int |
getQuantumShellTagIDSpherical(java.lang.String tag) |
static EnumQuantumShell |
getShellEnumeration(int i) |
abstract JmolAdapter.StructureIterator |
getStructureIterator(java.lang.Object atomSetCollection)
Get a StructureIterator.
|
static boolean |
isHetero(java.lang.String group3) |
static short |
lookupGroupID(java.lang.String group3) |
java.lang.Object |
openBufferedReader(java.lang.String name,
java.io.BufferedReader bufferedReader) |
java.lang.Object |
openBufferedReader(java.lang.String name,
java.io.BufferedReader bufferedReader,
java.util.Map<java.lang.String,java.lang.Object> htParams) |
java.lang.Object |
openBufferedReader(java.lang.String name,
java.lang.String type,
java.io.BufferedReader bufferedReader) |
java.lang.String[] |
specialLoad(java.lang.String name,
java.lang.String type) |
public static final short ORDER_COVALENT_SINGLE
public static final short ORDER_COVALENT_DOUBLE
public static final short ORDER_COVALENT_TRIPLE
public static final short ORDER_AROMATIC
public static final short ORDER_AROMATIC_SINGLE
public static final short ORDER_AROMATIC_DOUBLE
public static final short ORDER_HBOND
public static final short ORDER_STEREO_NEAR
public static final short ORDER_STEREO_FAR
public static final short ORDER_PARTIAL01
public static final short ORDER_PARTIAL12
public static final short ORDER_PARTIAL23
public static final short ORDER_PARTIAL32
public static final short ORDER_UNSPECIFIED
public static final int SHELL_S
public static final int SHELL_P
public static final int SHELL_SP
public static final int SHELL_L
public static final int SHELL_D_SPHERICAL
public static final int SHELL_D_CARTESIAN
public static final int SHELL_F_SPHERICAL
public static final int SHELL_F_CARTESIAN
public static final java.lang.String SUPPORTED_BASIS_FUNCTIONS
java.lang.String adapterName
public static final EnumQuantumShell getShellEnumeration(int i)
public static final int[][] getNewDfCoefMap()
public static java.lang.String getElementSymbol(int elementNumber)
public static short getElementNumber(java.lang.String elementSymbol)
public static int getNaturalIsotope(int elementNumber)
public static boolean isHetero(java.lang.String group3)
public static int getQuantumShellTagID(java.lang.String tag)
public static int getQuantumShellTagIDSpherical(java.lang.String tag)
public static final short lookupGroupID(java.lang.String group3)
public static float getBondingRadiusFloat(short atomicNumberWithIsotope, int charge)
public java.lang.String getAdapterName()
public abstract java.lang.Object getAtomSetCollectionReader(java.lang.String name, java.lang.String type, java.io.BufferedReader bufferedReader, java.util.Map<java.lang.String,java.lang.Object> htParams)
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 atomSetCollection
.
This atomSetCollection
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.
name
- File name, String or URL acting as the source of the readertype
- File type, if known, or nullbufferedReader
- The BufferedReaderhtParams
- a hash table containing parameter informationpublic abstract java.lang.Object getAtomSetCollection(java.lang.Object atomSetCollectionReader)
public abstract java.lang.Object getAtomSetCollectionReaders(JmolFilesReaderInterface fileReader, java.lang.String[] names, java.lang.String[] types, java.util.Map<java.lang.String,java.lang.Object> htParams, boolean getReadersOnly)
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 atomSetCollection
.
This atomSetCollection
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.
fileReader
- the thread requesting a set of files if bufferedReaders is nullnames
- File names, String or URL acting as the source of each readertypes
- File types, if known, or nullhtParams
- The input parameters for each file to loadgetReadersOnly
- public abstract java.lang.Object getAtomSetCollectionFromSet(java.lang.Object readers, java.lang.Object atomSets, java.util.Map<java.lang.String,java.lang.Object> htParams)
public abstract java.lang.Object getAtomSetCollectionOrBufferedReaderFromZip(java.io.InputStream is, java.lang.String fileName, java.lang.String[] zipDirectory, java.util.Map<java.lang.String,java.lang.Object> htParams, boolean asBufferedReader, boolean asBufferendInputStream)
public java.lang.Object getAtomSetCollectionFromReader(java.lang.String name, java.lang.String type, java.io.BufferedReader bufferedReader, java.util.Map<java.lang.String,java.lang.Object> htParams)
name
- type
- bufferedReader
- htParams
- public java.lang.Object openBufferedReader(java.lang.String name, java.io.BufferedReader bufferedReader)
public java.lang.Object openBufferedReader(java.lang.String name, java.io.BufferedReader bufferedReader, java.util.Map<java.lang.String,java.lang.Object> htParams)
public java.lang.Object openBufferedReader(java.lang.String name, java.lang.String type, java.io.BufferedReader bufferedReader)
public abstract java.lang.Object getAtomSetCollectionFromDOM(java.lang.Object DOMNode, java.util.Map<java.lang.String,java.lang.Object> htParams)
public void finish(java.lang.Object atomSetCollection)
atomSetCollection
- public abstract java.lang.String getFileTypeName(java.lang.Object atomSetCollection)
atomSetCollection
- The client file"unknown"
public abstract java.lang.String getAtomSetCollectionName(java.lang.Object atomSetCollection)
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.
atomSetCollection
- null
public abstract java.util.Map<java.lang.String,java.lang.Object> getAtomSetCollectionAuxiliaryInfo(java.lang.Object atomSetCollection)
Via the smarterJmolAdapter
atomSetCollection
- The client filenull
public abstract int getAtomSetCount(java.lang.Object atomSetCollection)
NOTE WARNING:
Not yet implemented everywhere, it is in the smarterJmolAdapter
atomSetCollection
- The client filepublic abstract int getAtomSetNumber(java.lang.Object atomSetCollection, int 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
atomSetCollection
- The client fileatomSetIndex
- The atom set's index for which to get
the atom set numberpublic abstract java.lang.String getAtomSetName(java.lang.Object atomSetCollection, int atomSetIndex)
atomSetCollection
- The client fileatomSetIndex
- The atom set indexpublic abstract java.util.Map<java.lang.String,java.lang.Object> getAtomSetAuxiliaryInfo(java.lang.Object atomSetCollection, int atomSetIndex)
Via the smarterJmolAdapter
atomSetCollection
- The client fileatomSetIndex
- The atom set indexnull
public abstract int getAtomCount(java.lang.Object atomSetCollection)
Just return -1 if you don't know (or don't want to figure it out)
atomSetCollection
- The client filepublic abstract int getHydrogenAtomCount(java.lang.Object atomSetCollection)
atomSetCollection
- public abstract java.lang.String[][] getBondList(java.lang.Object atomSetCollection)
atomSetCollection
- public abstract boolean coordinatesAreFractional(java.lang.Object atomSetCollection)
atomSetCollection
- The client filefalse
public abstract float[] getNotionalUnitcell(java.lang.Object atomSetCollection)
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
atomSetCollection
- The client filenull
public abstract float[] getPdbScaleMatrix(java.lang.Object atomSetCollection)
Does not seem to be overriden by any descendent
atomSetCollection
- The client filenull
public abstract float[] getPdbScaleTranslate(java.lang.Object atomSetCollection)
Does not seem to be overriden by any descendent
atomSetCollection
- The client filenull
public abstract JmolAdapter.AtomIterator getAtomIterator(java.lang.Object atomSetCollection)
This method may not return null
.
atomSetCollection
- The client fileJmolAdapter.AtomIterator
public abstract JmolAdapter.BondIterator getBondIterator(java.lang.Object atomSetCollection)
If this method returns null
and no
bonds are defined then the JmolViewer will automatically apply its
rebonding code to build bonds between atoms.
atomSetCollection
- The client filenull
JmolAdapter.BondIterator
public abstract JmolAdapter.StructureIterator getStructureIterator(java.lang.Object atomSetCollection)
atomSetCollection
- The client filenull
public static final char canonizeAlphaDigit(char ch)
public static final char canonizeChainID(char chainID)
public static final char canonizeInsertionCode(char insertionCode)
public static final char canonizeAlternateLocationID(char altLoc)
public java.lang.String[] specialLoad(java.lang.String name, java.lang.String type)
name
- type
-