diff options
author | Hung-ying Tyan <tyanh@google.com> | 2010-10-18 19:45:59 +0800 |
---|---|---|
committer | Hung-ying Tyan <tyanh@google.com> | 2010-10-21 03:27:20 +0800 |
commit | e87b644402642bad7147f915849bfa0eadaea446 (patch) | |
tree | ceb79dbf59365f65a7f1333a79000aa6e3f49e11 /voip | |
parent | 6fe795ecd35c4d49822d349424fc71b660577dfc (diff) | |
download | frameworks_base-e87b644402642bad7147f915849bfa0eadaea446.zip frameworks_base-e87b644402642bad7147f915849bfa0eadaea446.tar.gz frameworks_base-e87b644402642bad7147f915849bfa0eadaea446.tar.bz2 |
Add permission requirements to SipAudioCall and SipManager javadoc.
Bug: 3116259
Change-Id: I00a033794e9d3e1c2d2ccfe4e612cd50003ec2ee
Diffstat (limited to 'voip')
-rw-r--r-- | voip/java/android/net/sip/SipAudioCall.java | 20 | ||||
-rw-r--r-- | voip/java/android/net/sip/SipManager.java | 3 |
2 files changed, 22 insertions, 1 deletions
diff --git a/voip/java/android/net/sip/SipAudioCall.java b/voip/java/android/net/sip/SipAudioCall.java index 834ea70..6a4014f 100644 --- a/voip/java/android/net/sip/SipAudioCall.java +++ b/voip/java/android/net/sip/SipAudioCall.java @@ -41,6 +41,16 @@ import java.util.Map; * facilitates instantiating a {@code SipAudioCall} object for making/receiving * calls. See {@link SipManager#makeAudioCall} and * {@link SipManager#takeAudioCall}. + * + * <p>Requires permissions to use this class: + * {@link android.Manifest.permission#INTERNET} and + * {@link android.Manifest.permission#USE_SIP}. + * <br/>Requires permissions to {@link #startAudio}: + * {@link android.Manifest.permission#RECORD_AUDIO}, + * {@link android.Manifest.permission#ACCESS_WIFI_STATE} and + * {@link android.Manifest.permission#WAKE_LOCK}. + * <br/>Requires permissions to {@link #setSpeakerMode}: + * {@link android.Manifest.permission#MODIFY_AUDIO_SETTINGS}. */ public class SipAudioCall { private static final String TAG = SipAudioCall.class.getSimpleName(); @@ -774,7 +784,11 @@ public class SipAudioCall { } } - /** Puts the device to speaker mode. */ + /** + * Puts the device to speaker mode. + * <p>Requires permission: + * {@link android.Manifest.permission#MODIFY_AUDIO_SETTINGS}. + */ public void setSpeakerMode(boolean speakerMode) { synchronized (this) { ((AudioManager) mContext.getSystemService(Context.AUDIO_SERVICE)) @@ -874,6 +888,10 @@ public class SipAudioCall { /** * Starts the audio for the established call. This method should be called * after {@link Listener#onCallEstablished} is called. + * <p>Requires permission: + * {@link android.Manifest.permission#RECORD_AUDIO}, + * {@link android.Manifest.permission#ACCESS_WIFI_STATE} and + * {@link android.Manifest.permission#WAKE_LOCK}. */ public void startAudio() { try { diff --git a/voip/java/android/net/sip/SipManager.java b/voip/java/android/net/sip/SipManager.java index e1b1d10..38d2b0c 100644 --- a/voip/java/android/net/sip/SipManager.java +++ b/voip/java/android/net/sip/SipManager.java @@ -50,6 +50,9 @@ import java.text.ParseException; * </ul> * {@code SipManager} can only be instantiated if SIP API is supported by the * device. (See {@link #isApiSupported}). + * <p>Requires permissions to use this class: + * {@link android.Manifest.permission#INTERNET} and + * {@link android.Manifest.permission#USE_SIP}. */ public class SipManager { /** |