public class RMShapeAnim extends RMObject
Modifier and Type | Class and Description |
---|---|
static class |
RMShapeAnim.Record
An inner class to represent a time/value snapshot for an attribute.
|
class |
RMShapeAnim.RecordList
An inner class to represent a List of Records for a given attribute.
|
Constructor and Description |
---|
RMShapeAnim(RMShape aShape)
Creates a new anim object for the given shape.
|
Modifier and Type | Method and Description |
---|---|
void |
addAgent(RMAnimAgent anAgent)
Adds an agent to the agent list.
|
void |
addRecord(java.lang.String anAttr,
float aValue)
Adds a record for an attribute/float-value pair.
|
void |
addRecord(java.lang.String anAttr,
float aTime,
java.lang.Object aValue)
Adds a record for an attribute/value pair at a given time.
|
void |
addRecord(java.lang.String anAttr,
java.lang.Object aValue)
Adds a record for an attribute/value pair.
|
java.lang.Object |
clone()
Standard clone implementation.
|
boolean |
equals(java.lang.Object anObj)
Standard equals implementation.
|
RMAnimAgent |
getAgent(int anIndex)
Returns the specific agent at the given index.
|
int |
getAgentCount()
Returns the number of agents for this shape.
|
java.util.List |
getAgents()
Returns the list of agents.
|
java.util.List |
getAttributesAtTime(float aTime)
Returns a List of attribute strings for any attribute that has a Record for the given time.
|
static java.lang.String |
getMethod(java.lang.String aName) |
RMShapeAnim.RecordList |
getRecordList(int anIndex)
Returns the specific record list at the given index.
|
RMShapeAnim.RecordList |
getRecordList(java.lang.String anAttr)
Returns the anim RecordList for a given named attribute (or null if none exists yet).
|
RMShapeAnim.RecordList |
getRecordList(java.lang.String anAttr,
boolean create)
Returns the anim RecordList for a given named attribute, with an option to create one if it doesn't exist yet.
|
int |
getRecordListCount()
Returns the number of record lists for the shape.
|
RMShape |
getShape()
Returns the shape this anim works for.
|
boolean |
isEmpty()
Returns whether this shape doesn't have any real animation.
|
void |
loadKeyFrames(java.util.List aList)
Loads the given list with all unique anim Record times (list is ordered by time and avoids duplicates).
|
void |
removeRecordsAtTime(float aTime)
Removes any records at a given time.
|
void |
removeRecordsBetweenTimes(float startTime,
float endTime,
boolean inclusive)
Removes any records between the given two times (not inclusive).
|
void |
scaleRecords(float start,
float length,
float newLength)
Scales records starting at a given start type over a given length to a new length.
|
void |
setShape(RMShape aShape)
Sets the shape this anim works for.
|
void |
setTime(float aTime)
Resets shape attributes from anim record values for given time.
|
void |
shiftRecords(float fromTime,
float byTime)
Shifts records starting at a given start time by a given amount of time.
|
copy, didChange, didUndo, getAnimAttribute, getClassNameShort, initWithArchiver, undoClone, undoCopy, undoEquals
public RMShapeAnim(RMShape aShape)
public RMShape getShape()
public void setShape(RMShape aShape)
public int getRecordListCount()
public RMShapeAnim.RecordList getRecordList(int anIndex)
public RMShapeAnim.RecordList getRecordList(java.lang.String anAttr)
public RMShapeAnim.RecordList getRecordList(java.lang.String anAttr, boolean create)
public boolean isEmpty()
public void addRecord(java.lang.String anAttr, float aValue)
public void addRecord(java.lang.String anAttr, java.lang.Object aValue)
public void addRecord(java.lang.String anAttr, float aTime, java.lang.Object aValue)
public void removeRecordsAtTime(float aTime)
public void removeRecordsBetweenTimes(float startTime, float endTime, boolean inclusive)
public void shiftRecords(float fromTime, float byTime)
public void scaleRecords(float start, float length, float newLength)
public void setTime(float aTime)
public void loadKeyFrames(java.util.List aList)
public java.util.List getAttributesAtTime(float aTime)
public int getAgentCount()
public RMAnimAgent getAgent(int anIndex)
public java.util.List getAgents()
public void addAgent(RMAnimAgent anAgent)
public boolean equals(java.lang.Object anObj)
equals
in class java.lang.Object
public java.lang.Object clone()
public static java.lang.String getMethod(java.lang.String aName)