public static final class SequenceAlignmentDocument.ReferencedSequence extends Object
AnnotatedPluginDocument containing a SequenceDocument.
However, the referenced AnnotatedPluginDocument may instead contain a SequenceListDocument
if the alignment was built from a sequence list document
or a SequenceAlignmentDocument if the alignment was built using the consensus alignment builder.| Constructor and Description |
|---|
SequenceAlignmentDocument.ReferencedSequence(AnnotatedPluginDocument referencedDocument)
Construct a reference to a document that is a
SequenceDocument. |
SequenceAlignmentDocument.ReferencedSequence(AnnotatedPluginDocument referencedDocument,
int indexInSequenceListDocument) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
static List<SequenceAlignmentDocument.ReferencedSequence> |
forSequenceDocuments(AnnotatedPluginDocument... documents)
Creates a list of ReferencedSequence, with 1 entry in the list for each given document (each of which must be a
SequenceDocument) or null. |
int |
getIndexInSequenceListDocument()
If
getReferencedDocument() is a SequenceListDocument then this method returns
the index of the referenced sequence in that SequenceListDocument |
AnnotatedPluginDocument |
getReferencedDocument()
Gets the document a sequence in the alignment was built from.
|
static SequenceDocument |
getSequenceDocument(SequenceAlignmentDocument.ReferencedSequence referencedSequence,
SequenceDocument.Alphabet alphabet)
Get the sequence document referenced by a ReferencedSequence (if it references a SequenceDocument or SequenceListDocument)
|
SequenceDocument |
getSequenceDocument(SequenceDocument.Alphabet alphabet)
Get the sequence document referenced by this ReferencedSequence (if it references a SequenceDocument or SequenceListDocument)
|
int |
hashCode() |
String |
toString() |
public SequenceAlignmentDocument.ReferencedSequence(AnnotatedPluginDocument referencedDocument, int indexInSequenceListDocument)
referencedDocument - the document to reference. Must not be null.indexInSequenceListDocument - if the referenced document is a SequenceListDocument then this must be
the index of the referenced sequence in that SequenceListDocument. Or -1 if the referenced document is not a SequenceListDocument.public SequenceAlignmentDocument.ReferencedSequence(AnnotatedPluginDocument referencedDocument)
SequenceDocument. (it must not be a SequenceListDocument).
This is equivalent to calling ReferencedSequence(referencedDocument,-1)referencedDocument - the document to referenc,depublic AnnotatedPluginDocument getReferencedDocument()
SequenceDocument.
However, the AnnotatedPluginDocument may instead contain a SequenceListDocument
if the alignment was built from a sequence list document
or a SequenceAlignmentDocument if the alignment was built using the consensus alignment builder.public int getIndexInSequenceListDocument()
getReferencedDocument() is a SequenceListDocument then this method returns
the index of the referenced sequence in that SequenceListDocumentpublic static List<SequenceAlignmentDocument.ReferencedSequence> forSequenceDocuments(AnnotatedPluginDocument... documents)
SequenceDocument) or null.documents - the documents to create a list refering to.public SequenceDocument getSequenceDocument(SequenceDocument.Alphabet alphabet) throws DocumentOperationException
alphabet - alphabet of the sequence. Never nullDocumentOperationException - if the referenced sequence document could not be loadedpublic static SequenceDocument getSequenceDocument(SequenceAlignmentDocument.ReferencedSequence referencedSequence, SequenceDocument.Alphabet alphabet) throws DocumentOperationException
alphabet - alphabet of the sequence. Never nullreferencedSequence - the referenced sequence to get the sequence document from. Can be nullDocumentOperationException - if the referenced document could not be loaded