|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.upenn.gloDB.parser.Operation
public class Operation
These objects store the operations parsed by the parser. An Operation can contain either an array of Operations (ie a set of Operations to be processed as a group), or a Set of Features (ie a Track).
Field Summary | |
---|---|
private java.util.ArrayList |
group
If this Operation is a 'group' (ie '()'), then instead of containing a SortedSet of Features, it will contain an array of Operations. |
private boolean |
ignore
Flag for whether the mapped Feature should be included in the output. |
private java.util.Iterator |
iterator
An Iterator over 'Track'. |
(package private) int |
matched
Number of times the Operation has been matched. |
private int |
maxLength
Maximum acceptible Feature width. |
(package private) int |
maxPos
Maximum number of positions since the previous Track. |
private int |
maxRepeat
Maximum number of repeating features. |
private int |
maxSeqPos
Maximum acceptible position within 'sequence'. |
private int |
maxWithin
Maximum number of positions between repeating features. |
private int |
minLength
Minimum acceptible Feature width. |
(package private) int |
minPos
Minimum number of positions since the previous Track. |
private int |
minRepeat
Minimum number of repeating features. |
private int |
minSeqPos
Minimum acceptible position within 'sequence'. |
private int |
minWithin
Minimum number of positions between repeating features. |
private boolean |
negate
Flag for whether to invert the output Track, treating the Track as a mask over the Sequence (ie binary operation). |
private Sequence |
sequence
If not null, then ignore all other Sequences when testing for Feature matches. |
Track |
track
SortedSet of Features to be searched. |
private int |
type
Flag for the type of operation to be performed with the preceeding Operation. |
Constructor Summary | |
---|---|
private |
Operation()
Create a new Operation object, used by clone() below. |
|
Operation(java.util.ArrayList group)
Create a new Operation object containing a group. |
|
Operation(java.util.Set tracks)
Create a new Operation object with a set of Tracks. |
|
Operation(Track track)
Create a new Operation object with a Track. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Create a shallow clone (just clone the structure, not the Objects) of the existing object. |
void |
filterOnLength()
This will remove all Features from "track" that are not within the 'minLength'/'maxLength' boundaries. |
void |
filterOnRepeat()
This will remove all Features from "track" that are not within the 'minRepeat/maxRepeat' and 'minWithin/maxWithin' boundaries. |
void |
filterOnSeqPos()
This will remove all Features from "track" that are not within the 'minSeqPos'/'maxSeqPos' boundaries. |
void |
filterOnSequence()
This will remove all Features from "track" that are not on "sequence". |
Feature |
firstFeature()
Restart the Tracks iterator and return the first Feature. |
java.util.ArrayList |
getGroup()
Gets the array of Operations. |
int |
getType()
Get the Operation type: 0 = POS, 1 = AND, 2 = nAND, 3 = OR, 4 = LESS 10 = ., 11 = &&, 12 = ^&&, 13 = ||, 14 = - |
java.util.Iterator |
groupIterator()
Returns an iterator over the group list, null if empty group. |
boolean |
hasNextFeature()
Return true if there are more Features in 'iterator'. |
private void |
initialize()
|
boolean |
isGroup()
Returns true if this Operation is a group. |
boolean |
isIgnore()
Gets the ignore flag. |
boolean |
isNegate()
Flag for whether to invert the output Track, treating the Track as a mask over the Sequence (ie binary operation). |
Feature |
nextFeature()
Return the next Feature in iterator. |
int |
numFeatures()
Returns the number of Features contained in Operation. |
void |
resetTrack()
Restart iterator. |
void |
setGroup(java.util.ArrayList group)
Sets the array of Operations. |
void |
setIgnore(boolean ignore)
Sets the ignore flag. |
void |
setLength(int min,
int max)
This will set the min/max Length for all Features in "track". |
void |
setNegate(boolean negate)
Flag for whether to invert the output Track, treating the Track as a mask over the Sequence (ie binary operation). |
void |
setRepeat(int min,
int max)
This will set the min/max Repeat for all Features in "track". |
void |
setRepeat(int min,
int max,
int minW,
int maxW)
|
void |
setSeqPos(int min,
int max)
This will set the min/max seqquence position for all Features in "track". |
void |
setSequence(Sequence seq)
This will remove all Features from "track" that are not on "sequence". |
void |
setType(int type)
Set the Operation type: 0 = POS, 1 = AND, 2 = nAND, 3 = OR, 4 = LESS 10 = ., 11 = &&, 12 = ^&&, 13 = ||, 14 = - |
java.lang.String |
toString()
Returns Operation information for debugging purposes. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private java.util.ArrayList group
public Track track
private int type
private boolean negate
int minPos
int maxPos
private Sequence sequence
private int minLength
private int maxLength
private int minSeqPos
private int maxSeqPos
private int minRepeat
private int maxRepeat
private int minWithin
private int maxWithin
private boolean ignore
int matched
private java.util.Iterator iterator
Constructor Detail |
---|
private Operation()
public Operation(java.util.ArrayList group)
public Operation(Track track)
public Operation(java.util.Set tracks)
Method Detail |
---|
private void initialize()
public void setGroup(java.util.ArrayList group)
public java.util.ArrayList getGroup()
public void setType(int type)
public int getType()
public void setNegate(boolean negate)
public boolean isNegate()
public void setIgnore(boolean ignore)
public boolean isIgnore()
public void setSequence(Sequence seq)
public void setLength(int min, int max)
public void setSeqPos(int min, int max)
public void setRepeat(int min, int max)
public void setRepeat(int min, int max, int minW, int maxW)
public void filterOnSequence()
public void filterOnLength()
public void filterOnSeqPos()
public void filterOnRepeat()
public boolean isGroup()
public int numFeatures()
public void resetTrack()
public boolean hasNextFeature()
public Feature firstFeature()
public Feature nextFeature()
public java.util.Iterator groupIterator()
public java.lang.Object clone()
clone
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |