Track

The Track bean moves a point along a track defined as a sequence of points. A different event can be announced when the point reaches each vertex, and another event is announced when the behaviour completes.

Features

XML Element XML Type Java Class Activity
behaviour track uk.ac.ic.doc.scenebeans.behaviour.Track finite

Properties

Name Type Default Value Getter Method Setter Method Description
pointCount int 0 getPointCount setPointCount The number of points in the track. The value of this property must be three or more.
points Point2D []
(indexed)
(0,0) getPoints setPoints The points of the track.
x double []
(indexed)
0 getX setX The x coordinates of the points of the track.
y double []
(indexed)
0 getY setY The x coordinates of the points of the track.
duration double []
(indexed)
1 getDuration setDuration The duration of each leg of the track. If there are n points in the track, there are (n-1) durations. Duration m is the time taken to move from point m to point (m+1).
event String []
(indexed)
null getEvent setEvent The name of the AnimationEvent announced when the behaviour reaches each point. If there are n points in the track, there are (n-1) events. Event m is announced when the behaviour reaches point (m+1). If an event is null it is not announced.
value java.awt.geom. Point2D (0,0) getValue read only The current value of the behaviour.
activityName double 0.0 getActivityName setActivityName The name of the behaviour, as announced in AnimationEvents when the behaviour completes. In XML documents, this property is usually specified by the name attribute of the <behaviour> element.
finite boolean false isFinite read only Returns whether the activity is finite. It is, so this always returns true.

Behaviour Facets

Name Behaviour Type Getter Method Description
n/a java.awt.geom. Point2D n/a This behaviour is not facetted.