|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object
|
+--java.util.TimerTask
|
+--com.motorola.multimedia.Vibrator
The Vibrator represents the vibrator present on the Phone.
| Field Summary | |
static int |
MAX_VIBRATE_TIME
The maximum time the vibrator can vibrate for (5 minutes). |
static int |
MIN_PAUSE_TIME
The minimum time to pause between the vibrator stopping and starting again (2 seconds). |
static int |
VIBRATE_2SHORT
The two shorts vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods. |
static int |
VIBRATE_LONG
The long vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods. |
static int |
VIBRATE_PULSE
The pulse vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods.
|
static int |
VIBRATE_SHORT
The short vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods. |
static int |
VIBRATE_SHORT_LONG
The short and long vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods. |
static int |
VIBRATE_SILENT
The silent vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods. |
| Method Summary | |
void |
run()
This is the run method for the Vibration thread. |
static void |
setVibrateTone(int tone)
This method sets the current vibrate tone that will be used by the vibratorOn, vibratorFor and vibratePeriodically methods. |
static void |
vibrateFor(int timeInMs)
This method forces the vibrator to vibrate by the current vibrate tone for the time period specified in milliseconds. |
static void |
vibratePeriodically(int timeInMs)
This method forces the vibrator to vibrate periodically by the current vibrate tone for the timeInMs milliseconds and be silent for the timeInMs milliseconds. |
static void |
vibratePeriodically(int timeOnInMs,
int timeOffInMs)
This method forces the vibrator to vibrate periodically by the current vibrate tone for the timeOnInMs milliseconds and be silent for the timeOffInMs milliseconds. |
static void |
vibratorOff()
This method turns off the vibrator. |
static void |
vibratorOn()
This method turns on the vibrator for MAX_VIBRATE_TIME to vibrate by the current vibrate tone. |
| Methods inherited from class java.util.TimerTask |
cancel, scheduledExecutionTime |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int MAX_VIBRATE_TIME
public static final int MIN_PAUSE_TIME
public static final int VIBRATE_SILENT
vibratorOn, vibratorFor and vibratePeriodically methods.public static final int VIBRATE_SHORT
vibratorOn, vibratorFor and vibratePeriodically methods.public static final int VIBRATE_LONG
vibratorOn, vibratorFor and vibratePeriodically methods.public static final int VIBRATE_2SHORT
vibratorOn, vibratorFor and vibratePeriodically methods.public static final int VIBRATE_SHORT_LONG
vibratorOn, vibratorFor and vibratePeriodically methods.public static final int VIBRATE_PULSE
vibratorOn, vibratorFor and vibratePeriodically methods.
The pulse vibrate style is the default alert style.| Method Detail |
public void run()
run in class java.util.TimerTaskpublic static void vibrateFor(int timeInMs)
timeInMs - Vibrate time period specified in milliseconds.MAX_VIBRATE_TIME, otherwise the IllegalArgumentException is generated.public static void vibratePeriodically(int timeInMs)
timeInMs - Vibrate time period specified in milliseconds.MIN_PAUSE_TIME and less than or equal to MAX_VIBRATE_TIME, otherwise the IllegalArgumentException is generated.
public static void vibratePeriodically(int timeOnInMs,
int timeOffInMs)
timeOnInMs - Vibrate time period specified in milliseconds.timeOffInMs - Silent time period specified in milliseconds.MAX_VIBRATE_TIME, the value of timeOffInMs must be greater than or equal to MIN_PAUSE_TIME, otherwise the IllegalArgumentException is generated.public static void vibratorOff()
public static void vibratorOn()
public static void setVibrateTone(int tone)
vibratorOn, vibratorFor and vibratePeriodically methods.tone - Vibrate tone type.VIBRATE_PULSE or VIBRATE_SHORT or VIBRATE_LONG or VIBRATE_2SHORT or VIBRATE_SHORT_LONG or VIBRATE_SILENT, otherwise the IllegalArgumentException is generated.
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||