Lines Matching refs:value

20  * This class holds a time/value pair for an animation. The Keyframe class is used
22 * of the animation. As the time proceeds from one keyframe to the other, the value of the
23 * target object will animate between the value at the previous keyframe and the value at the
28 * a subclass of Keyframe specific to the type of value being stored. This is done to improve
43 * The type of the value in this Keyframe. This type is determined at construction time,
44 * based on the type of the <code>value</code> object passed into the constructor.
55 * Flag to indicate whether this keyframe has a valid value. This flag is used when an
62 * Constructs a Keyframe object with the given time and value. The time defines the
63 * time, as a proportion of an overall animation's duration, at which the value will hold true
64 * for the animation. The value for the animation between keyframes will be calculated as
67 * @param fraction The time, expressed as a value between 0 and 1, representing the fraction
69 * @param value The value that the object will animate to as the animation time approaches
70 * the time in this keyframe, and the the value animated from as the time passes the time in
73 public static Keyframe ofInt(float fraction, int value) {
74 return new IntKeyframe(fraction, value);
78 * Constructs a Keyframe object with the given time. The value at this time will be derived
80 * with no initial value must be used as part of an {@link ObjectAnimator}).
82 * time, as a proportion of an overall animation's duration, at which the value will hold true
83 * for the animation. The value for the animation between keyframes will be calculated as
86 * @param fraction The time, expressed as a value between 0 and 1, representing the fraction
94 * Constructs a Keyframe object with the given time and value. The time defines the
95 * time, as a proportion of an overall animation's duration, at which the value will hold true
96 * for the animation. The value for the animation between keyframes will be calculated as
99 * @param fraction The time, expressed as a value between 0 and 1, representing the fraction
101 * @param value The value that the object will animate to as the animation time approaches
102 * the time in this keyframe, and the the value animated from as the time passes the time in
105 public static Keyframe ofFloat(float fraction, float value) {
106 return new FloatKeyframe(fraction, value);
110 * Constructs a Keyframe object with the given time. The value at this time will be derived
112 * with no initial value must be used as part of an {@link ObjectAnimator}).
114 * time, as a proportion of an overall animation's duration, at which the value will hold true
115 * for the animation. The value for the animation between keyframes will be calculated as
118 * @param fraction The time, expressed as a value between 0 and 1, representing the fraction
126 * Constructs a Keyframe object with the given time and value. The time defines the
127 * time, as a proportion of an overall animation's duration, at which the value will hold true
128 * for the animation. The value for the animation between keyframes will be calculated as
131 * @param fraction The time, expressed as a value between 0 and 1, representing the fraction
133 * @param value The value that the object will animate to as the animation time approaches
134 * the time in this keyframe, and the the value animated from as the time passes the time in
137 public static Keyframe ofObject(float fraction, Object value) {
138 return new ObjectKeyframe(fraction, value);
142 * Constructs a Keyframe object with the given time. The value at this time will be derived
144 * with no initial value must be used as part of an {@link ObjectAnimator}).
146 * time, as a proportion of an overall animation's duration, at which the value will hold true
147 * for the animation. The value for the animation between keyframes will be calculated as
150 * @param fraction The time, expressed as a value between 0 and 1, representing the fraction
158 * Indicates whether this keyframe has a valid value. This method is called internally when
160 * that time by deriving the value for the property from the target object.
162 * @return boolean Whether this object has a value assigned.
169 * Gets the value for this Keyframe.
171 * @return The value for this Keyframe.
176 * Sets the value for this Keyframe.
178 * @param value value for this Keyframe.
180 public abstract void setValue(Object value);
186 * duration. This should be a value between 0 and 1.
196 * duration. This should be a value between 0 and 1.
203 * Gets the optional interpolator for this Keyframe. A value of <code>null</code> indicates
213 * Sets the optional interpolator for this Keyframe. A value of <code>null</code> indicates
227 * @return The type of the value stored in the Keyframe.
242 * The value of the animation at the time mFraction.
246 ObjectKeyframe(float fraction, Object value) {
248 mValue = value;
249 mHasValue = (value != null);
250 mValueType = mHasValue ? value.getClass() : Object.class;
257 public void setValue(Object value) {
258 mValue = value;
259 mHasValue = (value != null);
271 * Internal subclass used when the keyframe value is of type int.
276 * The value of the animation at the time mFraction.
280 IntKeyframe(float fraction, int value) {
282 mValue = value;
300 public void setValue(Object value) {
301 if (value != null && value.getClass() == Integer.class) {
302 mValue = ((Integer)value).intValue();
318 * Internal subclass used when the keyframe value is of type float.
322 * The value of the animation at the time mFraction.
326 FloatKeyframe(float fraction, float value) {
328 mValue = value;
346 public void setValue(Object value) {
347 if (value != null && value.getClass() == Float.class) {
348 mValue = ((Float)value).floatValue();