|
PenProfile 2.x | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.livescribe.storage.StrokeStorage
public class StrokeStorage
This class describes the system stroke storage. It gives information about current, previous, and next strokes based on time values.
The current implementation is limited to querying the last 50 strokes obtained by the system. For example, if you have a timestamp from before the last 50 strokes, then this will not be able to find that stroke.
| Constructor Summary | |
|---|---|
StrokeStorage(PageInstance page)
Creates a new stroke storage instance. |
|
| Method Summary | |
|---|---|
Point |
getLastCoord()
Returns the last point. |
long |
getLastStroke()
Returns the last stroke time. |
long |
getNextStroke(long time)
Returns the next stroke time, in milliseconds. |
long |
getPreviousStroke(long time)
Returns the previous stroke time, in milliseconds. |
Stroke |
getStroke(long time)
Returns the stroke corresponding to the specified time. |
Rectangle |
getStrokeBoundingBox(long time)
Returns the rectangle bounding the stroke. |
boolean |
isTap(long time)
Checks if the stroke is a tap |
boolean |
isTap(long time1,
long time2)
Checks if a stroke is a double tap |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StrokeStorage(PageInstance page)
page - the page instance| Method Detail |
|---|
public Stroke getStroke(long time)
time - the time corresponding to the stroke
Strokepublic Rectangle getStrokeBoundingBox(long time)
time - the time corresponding to the stroke
public long getPreviousStroke(long time)
time - the time corresponding to the current stroke
public long getNextStroke(long time)
time - the time corresponding to the current stroke
public long getLastStroke()
getLastCoord()public boolean isTap(long time)
time - the timestamp of the stroke
public boolean isTap(long time1,
long time2)
time1 - the timestamp of one of the strokestime2 - the timestamp of the other stroke (order does not matter)
public Point getLastCoord()
Point.
This can be used, for example, in a thread that monitors the current
pen position.
Point instance.getLastStroke()
|
PenProfile 2.x | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||