public class AnnotationCreationModifier extends TouchModifierBase
Constructor and Description |
---|
AnnotationCreationModifier() |
Modifier and Type | Method and Description |
---|---|
protected IAnnotation |
createAnnotation(ISciChartSurface parentSurface,
IAnnotationFactory annotationFactory,
int annotationType)
Creates an annotation
|
IAnnotationFactory |
getAnnotationFactory()
Gets the annotation factory which creates new annotations which are used this modifier
|
int |
getAnnotationType()
Gets the type of annotation to create
|
java.lang.String |
getXAxisId()
Gets the xAxis id for annotations created by this modifier
|
java.lang.String |
getYAxisId()
Gets the yAxis id for annotations created by this modifier
|
protected void |
onAnnotationCreated(IAnnotation newAnnotation)
Called when new annotation is created
|
protected boolean |
onTouchDown(com.scichart.core.utility.touch.ModifierTouchEventArgs args)
Called when
MotionEvent.ACTION_DOWN event occurs |
protected boolean |
onTouchMove(com.scichart.core.utility.touch.ModifierTouchEventArgs args)
Called when
MotionEvent.ACTION_MOVE event occurs |
protected boolean |
onTouchUp(com.scichart.core.utility.touch.ModifierTouchEventArgs args)
Called when
MotionEvent.ACTION_UP event occurs |
void |
setAnnotationCreationListener(OnAnnotationCreatedListener listener)
Sets the
OnAnnotationCreatedListener instance which is called whenever new annotation is created by this modifier |
void |
setAnnotationFactory(IAnnotationFactory annotationFactory)
Sets the annotation factory which creates new annotations which are used this modifier
|
void |
setAnnotationType(int annotationType)
Sets the type of annotation to create
|
void |
setXAxisId(java.lang.String xAxisId)
Sets the xAxis id for annotations created by this modifier
|
void |
setYAxisId(java.lang.String yAxisId)
Sets the yAxis id for annotations created by this modifier
|
onTouch, onTouchCancel
applyThemeProvider, attachTo, detach, getContext, getEventsGroupTag, getIsEnabled, getMasterModifier, getModifierSurface, getParentSurface, getPointRelativeTo, getReceiveHandledEvents, getRenderableSeries, getRenderableSeriesArea, getServices, getXAxes, getXAxis, getXAxis, getYAxes, getYAxis, getYAxis, isAttached, isWithinSourceBounds, onAnnotationsCollectionChanged, onAnnotationsDrasticallyChanged, onGenericMotion, onIsEnabledChanged, onParentSurfaceResized, onRenderableSeriesCollectionChanged, onRenderableSeriesDrasticallyChanged, onRenderSurfaceRendered, onSelectedSeriesCollectionChanged, onXAxesCollectionChanged, onXAxesDrasticallyChanged, onYAxesCollectionChanged, onYAxesDrasticallyChanged, setEventsGroupTag, setIsEnabled, setReceiveHandledEvents
public final void setXAxisId(@NonNull java.lang.String xAxisId)
xAxisId
- The new xAxis id@NonNull public final java.lang.String getXAxisId()
public final void setYAxisId(@NonNull java.lang.String yAxisId)
yAxisId
- The new xAxis id@NonNull public final java.lang.String getYAxisId()
public final void setAnnotationFactory(@NonNull IAnnotationFactory annotationFactory)
annotationFactory
- The new annotation factory@NonNull public final IAnnotationFactory getAnnotationFactory()
public final void setAnnotationCreationListener(@Nullable OnAnnotationCreatedListener listener)
OnAnnotationCreatedListener
instance which is called whenever new annotation is created by this modifierlistener
- The new listener instancepublic final void setAnnotationType(int annotationType)
annotationType
- The new annotation typepublic final int getAnnotationType()
protected boolean onTouchDown(com.scichart.core.utility.touch.ModifierTouchEventArgs args)
MotionEvent.ACTION_DOWN
event occursonTouchDown
in class TouchModifierBase
args
- The touch event args for this eventprotected boolean onTouchMove(com.scichart.core.utility.touch.ModifierTouchEventArgs args)
MotionEvent.ACTION_MOVE
event occursonTouchMove
in class TouchModifierBase
args
- The touch event args for this eventprotected boolean onTouchUp(com.scichart.core.utility.touch.ModifierTouchEventArgs args)
MotionEvent.ACTION_UP
event occursonTouchUp
in class TouchModifierBase
args
- The touch event args for this eventprotected final void onAnnotationCreated(@NonNull IAnnotation newAnnotation)
@NonNull protected IAnnotation createAnnotation(@NonNull ISciChartSurface parentSurface, @NonNull IAnnotationFactory annotationFactory, int annotationType)