net.rim.blackberry.api.profiles
Class SoundAlert
java.lang.Object
net.rim.blackberry.api.profiles.NotificationAlert
net.rim.blackberry.api.profiles.SoundAlert
public class SoundAlert
- extends NotificationAlert
Represents sound alert properties.
The SoundAlert
class defines sound alert properties for alerts
that occur in response to an event. This includes properties such as sound
volume, sound tune name, and so on.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
Field Summary |
|
static byte |
ALWAYS
Indicates that the sound notification should be performed regardless of
the holster condition. |
|
static byte |
IN_HOLSTER_ONLY
Indicates that the sound notification should be performed only when the
device is in the holster. |
|
static byte |
OUT_OF_HOLSTER_ONLY
Indicates that the sound notification should be performed only when the
device is not in the holster. |
Constructor Summary |
|
SoundAlert()
Empty constructor for SoundAlert |
Method Summary |
|
int |
getCount()
Returns the repeat count of this sound alert. |
|
byte |
getHolsterCondition()
Returns the holster condition for this sound alert. |
|
static int |
getMaxVolume()
Returns the maximum value for the volume property. |
|
String |
getTuneName()
Returns the tune name for this alert. |
|
int |
getVolume()
Returns the alert volume. |
|
boolean |
isCountInherited()
Indicates whether the repeat count is inherited from a higher level
profile. |
|
boolean |
isHolsterConditionInherited()
Indicates whether the holster condition is inherited from a higher level
profile. |
|
boolean |
isTuneNameInherited()
Indicates whether the tune name is inherited from a higher level profile. |
|
boolean |
isVolumeInherited()
Indicates whether the sound volume is inherited from a higher level
profile. |
|
void |
setCount(int count)
Sets the repeat count for this sound alert. |
|
void |
setCountInherited(boolean countInherited)
Sets whether the repeat count is inherited from a higher level profile. |
|
void |
setHolsterCondition(byte holsterCondition)
Sets the holster condition for this sound alert. |
|
void |
setHolsterConditionInherited(boolean holsterConditionInherited)
Sets whether the holster condition is inherited from a higher level
profile. |
|
void |
setTuneName(String tuneName)
Sets the tune name for this sound alert. |
|
void |
setTuneNameInherited(boolean tuneNameInherited)
Sets whether the tune name is inherited from a higher level profile. |
|
void |
setVolume(int volume)
Sets the alert volume. |
|
void |
setVolumeInherited(boolean volumeInherited)
Sets whether the sound volume is inherited from a higher level profile. |
|
void |
toString(StringBuffer sb)
Returns a human-readable representation of this sound alert. |
ALWAYS
public static final byte ALWAYS
- Indicates that the sound notification should be performed regardless of
the holster condition.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
IN_HOLSTER_ONLY
public static final byte IN_HOLSTER_ONLY
- Indicates that the sound notification should be performed only when the
device is in the holster.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
OUT_OF_HOLSTER_ONLY
public static final byte OUT_OF_HOLSTER_ONLY
- Indicates that the sound notification should be performed only when the
device is not in the holster.
- See Also:
- Constant Field Values
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
SoundAlert
public SoundAlert()
- Empty constructor for SoundAlert
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
getTuneName
public String getTuneName()
- Returns the tune name for this alert.
The tune name can be a URI to a media file on the file system (such as
"file://home/user/music/tune.wav") or the name of a preloaded tune.
- Returns:
- The tune name.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
getVolume
public int getVolume()
- Returns the alert volume.
This value can be in the range of 0 to 10. A volume of 0 means that the
sound alert is disabled.
- Returns:
- The alert volume.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setVolume
public void setVolume(int volume)
- Sets the alert volume.
- Parameters:
volume
- The new volume. This parameter must be in the range of 0 to
10. A volume of 0 means that the sound alert is disabled.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
getCount
public int getCount()
- Returns the repeat count of this sound alert.
- Returns:
- The repeat count.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setCount
public void setCount(int count)
- Sets the repeat count for this sound alert.
- Parameters:
count
- The new repeat count.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setTuneName
public void setTuneName(String tuneName)
- Sets the tune name for this sound alert.
- Parameters:
tuneName
- The new tune name.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
isTuneNameInherited
public boolean isTuneNameInherited()
- Indicates whether the tune name is inherited from a higher level profile.
- Returns:
true
if the tune name is inherited,
false
otherwise.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setTuneNameInherited
public void setTuneNameInherited(boolean tuneNameInherited)
- Sets whether the tune name is inherited from a higher level profile.
- Parameters:
tuneNameInherited
- If true
the tune name is inherited,
if false
the tune name is not inherited.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
isVolumeInherited
public boolean isVolumeInherited()
- Indicates whether the sound volume is inherited from a higher level
profile.
- Returns:
true
if the volume is inherited, false
otherwise.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setVolumeInherited
public void setVolumeInherited(boolean volumeInherited)
- Sets whether the sound volume is inherited from a higher level profile.
- Parameters:
volumeInherited
- If true
the sound volume is
inherited, if false
the sound volume is not inherited.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
isCountInherited
public boolean isCountInherited()
- Indicates whether the repeat count is inherited from a higher level
profile.
- Returns:
true
if the repeat count is inherited,
false
otherwise.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setCountInherited
public void setCountInherited(boolean countInherited)
- Sets whether the repeat count is inherited from a higher level profile.
- Parameters:
countInherited
- If true
the repeat count is inherited,
if false
the repeat count is not inherited.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
getHolsterCondition
public byte getHolsterCondition()
- Returns the holster condition for this sound alert.
- Returns:
- The holster condition. This value is one of
SoundAlert.ALWAYS
,
SoundAlert.IN_HOLSTER_ONLY
, or SoundAlert.OUT_OF_HOLSTER_ONLY
. - Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setHolsterCondition
public void setHolsterCondition(byte holsterCondition)
- Sets the holster condition for this sound alert.
- Parameters:
holsterCondition
- The new holster condition. This parameter must be
one of SoundAlert.ALWAYS
, SoundAlert.IN_HOLSTER_ONLY
, or
SoundAlert.OUT_OF_HOLSTER_ONLY
.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
isHolsterConditionInherited
public boolean isHolsterConditionInherited()
- Indicates whether the holster condition is inherited from a higher level
profile.
- Returns:
true
if the holster condition is inherited,
false
if the holster condition is not inherited.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
setHolsterConditionInherited
public void setHolsterConditionInherited(boolean holsterConditionInherited)
- Sets whether the holster condition is inherited from a higher level
profile.
- Parameters:
holsterConditionInherited
- If true
the holster
condition is inherited, if false
the holster condition is
not inherited.- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
toString
public void toString(StringBuffer sb)
- Returns a human-readable representation of this sound alert.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
getMaxVolume
public static int getMaxVolume()
- Returns the maximum value for the volume property.
- Returns:
- The maximum value for the volume property.
- Category:
- Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
- Since:
- BlackBerry API 7.1.0
Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal