public class RevCompSequence extends SimpleSequence
Sequence interface.
 All features of the underlying sequence are reflected onto the RevCompSequence using a ProjectedFeatureHolder
calling createFeature() on a RevCompSequence creates a feature on the underlying sequence. Non-Stranded features will return the reverse compemented view of the sequence when getSymbols() is called that is to say if you get what you expect as if your RevCompSequence was a regular Sequence.Annotatable.AnnotationForwarderFeatureHolder.EmptyFeatureHolder| Modifier and Type | Field and Description | 
|---|---|
protected Sequence | 
origSeq  | 
EDIT, EMPTY_LISTANNOTATIONEMPTY_FEATURE_HOLDER, FEATURES, SCHEMA| Constructor and Description | 
|---|
RevCompSequence(Sequence seq)
URN, Name and Annotation are copied as is from the original Sequence, unless you use the
  the other contructor that sets these. 
 | 
RevCompSequence(Sequence seq,
               String urn,
               String name,
               Annotation annotation)  | 
| Modifier and Type | Method and Description | 
|---|---|
Object | 
clone()
clone() should make a complete copy of the Sequence with  all features (and children) and return
 a SimpleSequence that is unconnected from the original sequence. 
 | 
boolean | 
containsFeature(Feature f)
containsFeature() will return true if this seq contains the feature in question, or
 if if the original (non reverse complement) sequence contains the feature; 
 | 
int | 
countFeatures()
Count how many features are contained. 
 | 
Feature | 
createFeature(Feature.Template ft)
createFeature() will call createFeature() on the underlying Sequence. 
 | 
void | 
edit(Edit e)
edit() will try to edit the underlying Sequence. 
 | 
Iterator | 
features()
Iterate over the features in no well defined order. 
 | 
FeatureHolder | 
filter(FeatureFilter ff)
Query this set of features using a supplied  
FeatureFilter. | 
FeatureHolder | 
filter(FeatureFilter ff,
      boolean recurse)
Return a new FeatureHolder that contains all of the children of this one
 that passed the filter fc. 
 | 
Feature | 
getFeatureFromOriginal(Feature f)
getFeatureFromOriginal() Since you can not create a feature on a projectedFeature at this time, I am 
 including this method so that you can get the corresponding feature from the original sequence. 
 | 
void | 
removeFeature(Feature f)
Remove a feature attached to this sequence. 
 | 
createFeature, featureHolderAllocated, getAlphabet, getAnnotation, getChangeSupport, getFeatureHolder, getName, getSchema, getURN, iterator, length, realizeFeature, seqString, setName, setURN, subList, subStr, symbolAt, toList, toStringaddChangeListener, addChangeListener, generateChangeSupport, hasListeners, hasListeners, isUnchanging, removeChangeListener, removeChangeListenerequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddChangeListener, addChangeListener, isUnchanging, removeChangeListener, removeChangeListenerpublic RevCompSequence(Sequence seq) throws IllegalAlphabetException
IllegalAlphabetExceptionpublic RevCompSequence(Sequence seq, String urn, String name, Annotation annotation) throws IllegalAlphabetException
IllegalAlphabetExceptionpublic void edit(Edit e) throws ChangeVetoException, IndexOutOfBoundsException
Since I have not seen and editable Sequence I have not tested this
edit in interface SymbolListedit in class SimpleSequencee - the Edit to performChangeVetoException - if either the SymboList does not support the
         edit, or if the change was vetoedIndexOutOfBoundsException - if the edit does not lie within the
         SymbolListpublic Iterator features()
FeatureHolderfeatures in interface FeatureHolderfeatures in class SimpleSequencepublic int countFeatures()
FeatureHoldercountFeatures in interface FeatureHoldercountFeatures in class SimpleSequencepublic FeatureHolder filter(FeatureFilter ff)
FeatureHolderFeatureFilter.filter in interface FeatureHolderfilter in class SimpleSequenceff - the FeatureFilter to apply.filter.public FeatureHolder filter(FeatureFilter ff, boolean recurse)
FeatureHolderfilter in interface FeatureHolderfilter in class SimpleSequenceff - the FeatureFilter to applyrecurse - true if all features-of-features should be scanned, and a
                single flat collection of features returned, or false if
                just immediate children should be filtered.public boolean containsFeature(Feature f)
containsFeature in interface FeatureHoldercontainsFeature in class SimpleSequencef - the Feature to checkpublic void removeFeature(Feature f) throws ChangeVetoException, BioException
SimpleSequenceremoveFeature in interface FeatureHolderremoveFeature in class SimpleSequenceChangeVetoException - if this FeatureHolder does not support
         feature removal or if the change was vetoedBioException - if there was an error removing the featurepublic Feature createFeature(Feature.Template ft) throws ChangeVetoException, BioException
createFeature in interface FeatureHoldercreateFeature in class SimpleSequenceChangeVetoException - if this FeatureHolder does not support
         creation of new features, or if the change was vetoedBioException - if something went wrong during creating the featurepublic Feature getFeatureFromOriginal(Feature f)
Copyright © 2020 BioJava. All rights reserved.