public class SimplePosition extends Object implements Position
BETWEEN_BASES, EMPTY_POSITION, IN_RANGE
Modifier | Constructor and Description |
---|---|
protected |
SimplePosition() |
|
SimplePosition(boolean fs,
boolean fe,
int p)
Constructs a point position, with optionally fuzzy start and
end.
|
|
SimplePosition(boolean fs,
boolean fe,
int s,
int e,
String t)
Constructs a range position, with optionally fuzzy start and
end.
|
|
SimplePosition(int p)
Constructs a point position, with no fuzzy start or
end.
|
|
SimplePosition(int s,
int e)
Constructs a range position, with no fuzzy start or
end.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o)
Two positions are equal if they share all parameters in common,
eg. fuzzy start+end, start, end, type.
|
int |
getEnd()
Returns the end of the range of bases this base could lie in.
|
boolean |
getFuzzyEnd()
Returns true if the position has a fuzzy end.
|
boolean |
getFuzzyStart()
Returns true if the position has a fuzzy start.
|
Integer |
getId()
Gets the Hibernate ID.
|
int |
getStart()
Returns the beginning of the range of bases this base could lie in.
|
String |
getType()
Returns the type of this position if it is not a point/single position.
|
void |
setId(Integer id)
Sets the Hibernate ID.
|
String |
toString() |
Position |
translate(int distance)
Takes this position and returns a copy translated by 'distance' bases.
|
public SimplePosition(int p)
p
- the point positionpublic SimplePosition(int s, int e)
s
- the start positione
- the end positionpublic SimplePosition(boolean fs, boolean fe, int p)
fs
- fuzzy start?fe
- fuzzy end?p
- the point positionpublic SimplePosition(boolean fs, boolean fe, int s, int e, String t)
fs
- fuzzy start?fe
- fuzzy end?s
- the start of the positione
- the end of the positiont
- the type of the positionprotected SimplePosition()
public boolean getFuzzyStart()
getFuzzyStart
in interface Position
public boolean getFuzzyEnd()
getFuzzyEnd
in interface Position
public int getStart()
public int getEnd()
public String getType()
public Position translate(int distance)
public boolean equals(Object o)
public Integer getId()
Copyright © 2014 BioJava. All rights reserved.