code
stringlengths 11
173k
| docstring
stringlengths 2
593k
| func_name
stringlengths 2
189
| language
stringclasses 1
value | repo
stringclasses 844
values | path
stringlengths 11
294
| url
stringlengths 60
339
| license
stringclasses 4
values |
---|---|---|---|---|---|---|---|
public void explicitCallTransfer(Call heldCall) throws CallStateException {
if (VDBG) {
Rlog.d(LOG_TAG, " explicitCallTransfer(" + heldCall + ")");
Rlog.d(LOG_TAG, toString());
}
if (canTransfer(heldCall)) {
heldCall.getPhone().explicitCallTransfer();
}
if (VDBG) {
Rlog.d(LOG_TAG, "End explicitCallTransfer(" + heldCall + ")");
Rlog.d(LOG_TAG, toString());
}
} |
Connects the held call and active call
Disconnects the subscriber from both calls
Explicit Call Transfer occurs asynchronously
and may fail. Final notification occurs via
{@link #registerForPreciseCallStateChanged(android.os.Handler, int,
java.lang.Object) registerForPreciseCallStateChanged()}.
@exception CallStateException if canTransfer() would return false.
In these cases, this operation may not be performed.
| CallManager::explicitCallTransfer | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public List<? extends MmiCode> getPendingMmiCodes(Phone phone) {
Rlog.e(LOG_TAG, "getPendingMmiCodes not implemented");
return null;
} |
Returns a list of MMI codes that are pending for a phone. (They have initiated
but have not yet completed).
Presently there is only ever one.
Use <code>registerForMmiInitiate</code>
and <code>registerForMmiComplete</code> for change notification.
@return null if phone doesn't have or support mmi code
| CallManager::getPendingMmiCodes | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean sendUssdResponse(Phone phone, String ussdMessge) {
Rlog.e(LOG_TAG, "sendUssdResponse not implemented");
return false;
} |
Sends user response to a USSD REQUEST message. An MmiCode instance
representing this response is sent to handlers registered with
registerForMmiInitiate.
@param ussdMessge Message to send in the response.
@return false if phone doesn't support ussd service
| CallManager::sendUssdResponse | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean getMute() {
if (hasActiveFgCall()) {
return getActiveFgCall().getPhone().getMute();
} else if (hasActiveBgCall()) {
return getFirstActiveBgCall().getPhone().getMute();
}
return false;
} |
Gets current mute status. Use
{@link #registerForPreciseCallStateChanged(android.os.Handler, int,
java.lang.Object) registerForPreciseCallStateChanged()}
as a change notifcation, although presently phone state changed is not
fired when setMute() is called.
@return true is muting, false is unmuting
| CallManager::getMute | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void setEchoSuppressionEnabled() {
if (VDBG) {
Rlog.d(LOG_TAG, " setEchoSuppression()");
Rlog.d(LOG_TAG, toString());
}
if (hasActiveFgCall()) {
getActiveFgCall().getPhone().setEchoSuppressionEnabled();
}
if (VDBG) {
Rlog.d(LOG_TAG, "End setEchoSuppression()");
Rlog.d(LOG_TAG, toString());
}
} |
Enables or disables echo suppression.
| CallManager::setEchoSuppressionEnabled | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean sendDtmf(char c) {
boolean result = false;
if (VDBG) {
Rlog.d(LOG_TAG, " sendDtmf(" + c + ")");
Rlog.d(LOG_TAG, toString());
}
if (hasActiveFgCall()) {
getActiveFgCall().getPhone().sendDtmf(c);
result = true;
}
if (VDBG) {
Rlog.d(LOG_TAG, "End sendDtmf(" + c + ")");
Rlog.d(LOG_TAG, toString());
}
return result;
} |
Play a DTMF tone on the active call.
@param c should be one of 0-9, '*' or '#'. Other values will be
silently ignored.
@return false if no active call or the active call doesn't support
dtmf tone
| CallManager::sendDtmf | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean startDtmf(char c) {
boolean result = false;
if (VDBG) {
Rlog.d(LOG_TAG, " startDtmf(" + c + ")");
Rlog.d(LOG_TAG, toString());
}
if (hasActiveFgCall()) {
getActiveFgCall().getPhone().startDtmf(c);
result = true;
}
if (VDBG) {
Rlog.d(LOG_TAG, "End startDtmf(" + c + ")");
Rlog.d(LOG_TAG, toString());
}
return result;
} |
Start to paly a DTMF tone on the active call.
or there is a playing DTMF tone.
@param c should be one of 0-9, '*' or '#'. Other values will be
silently ignored.
@return false if no active call or the active call doesn't support
dtmf tone
| CallManager::startDtmf | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void stopDtmf() {
if (VDBG) {
Rlog.d(LOG_TAG, " stopDtmf()" );
Rlog.d(LOG_TAG, toString());
}
if (hasActiveFgCall()) getFgPhone().stopDtmf();
if (VDBG) {
Rlog.d(LOG_TAG, "End stopDtmf()");
Rlog.d(LOG_TAG, toString());
}
} |
Stop the playing DTMF tone. Ignored if there is no playing DTMF
tone or no active call.
| CallManager::stopDtmf | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean sendBurstDtmf(String dtmfString, int on, int off, Message onComplete) {
if (hasActiveFgCall()) {
getActiveFgCall().getPhone().sendBurstDtmf(dtmfString, on, off, onComplete);
return true;
}
return false;
} |
send burst DTMF tone, it can send the string as single character or multiple character
ignore if there is no active call or not valid digits string.
Valid digit means only includes characters ISO-LATIN characters 0-9, *, #
The difference between sendDtmf and sendBurstDtmf is sendDtmf only sends one character,
this api can send single character and multiple character, also, this api has response
back to caller.
@param dtmfString is string representing the dialing digit(s) in the active call
@param on the DTMF ON length in milliseconds, or 0 for default
@param off the DTMF OFF length in milliseconds, or 0 for default
@param onComplete is the callback message when the action is processed by BP
| CallManager::sendBurstDtmf | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForUnknownConnection(Handler h, int what, Object obj){
mUnknownConnectionRegistrants.addUnique(h, what, obj);
} |
Notifies when a previously untracked non-ringing/waiting connection has appeared.
This is likely due to some other entity (eg, SIM card application) initiating a call.
| CallManager::registerForUnknownConnection | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForUnknownConnection(Handler h){
mUnknownConnectionRegistrants.remove(h);
} |
Unregisters for unknown connection notifications.
| CallManager::unregisterForUnknownConnection | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForIncomingRing(Handler h, int what, Object obj){
mIncomingRingRegistrants.addUnique(h, what, obj);
} |
Notifies when an incoming call rings.<p>
Messages received from this:
Message.obj will be an AsyncResult
AsyncResult.userObj = obj
AsyncResult.result = a Connection. <p>
| CallManager::registerForIncomingRing | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForRingbackTone(Handler h, int what, Object obj){
mRingbackToneRegistrants.addUnique(h, what, obj);
} |
Notifies when out-band ringback tone is needed.<p>
Messages received from this:
Message.obj will be an AsyncResult
AsyncResult.userObj = obj
AsyncResult.result = boolean, true to start play ringback tone
and false to stop. <p>
| CallManager::registerForRingbackTone | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForOnHoldTone(Handler h, int what, Object obj){
mOnHoldToneRegistrants.addUnique(h, what, obj);
} |
Notifies when out-band on-hold tone is needed.<p>
Messages received from this:
Message.obj will be an AsyncResult
AsyncResult.userObj = obj
AsyncResult.result = boolean, true to start play on-hold tone
and false to stop. <p>
| CallManager::registerForOnHoldTone | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForResendIncallMute(Handler h, int what, Object obj){
mResendIncallMuteRegistrants.addUnique(h, what, obj);
} |
Registers the handler to reset the uplink mute state to get
uplink audio.
| CallManager::registerForResendIncallMute | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForResendIncallMute(Handler h){
mResendIncallMuteRegistrants.remove(h);
} |
Unregisters for resend incall mute notifications.
| CallManager::unregisterForResendIncallMute | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForMmiInitiate(Handler h, int what, Object obj){
mMmiInitiateRegistrants.addUnique(h, what, obj);
} |
Register for notifications of initiation of a new MMI code request.
MMI codes for GSM are discussed in 3GPP TS 22.030.<p>
Example: If Phone.dial is called with "*#31#", then the app will
be notified here.<p>
The returned <code>Message.obj</code> will contain an AsyncResult.
<code>obj.result</code> will be an "MmiCode" object.
| CallManager::registerForMmiInitiate | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForMmiInitiate(Handler h){
mMmiInitiateRegistrants.remove(h);
} |
Unregisters for new MMI initiate notification.
Extraneous calls are tolerated silently
| CallManager::unregisterForMmiInitiate | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForMmiComplete(Handler h, int what, Object obj){
Rlog.d(LOG_TAG, "registerForMmiComplete");
mMmiCompleteRegistrants.addUnique(h, what, obj);
} |
Register for notifications that an MMI request has completed
its network activity and is in its final state. This may mean a state
of COMPLETE, FAILED, or CANCELLED.
<code>Message.obj</code> will contain an AsyncResult.
<code>obj.result</code> will be an "MmiCode" object
| CallManager::registerForMmiComplete | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForMmiComplete(Handler h){
mMmiCompleteRegistrants.remove(h);
} |
Unregisters for MMI complete notification.
Extraneous calls are tolerated silently
| CallManager::unregisterForMmiComplete | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForEcmTimerReset(Handler h, int what, Object obj){
mEcmTimerResetRegistrants.addUnique(h, what, obj);
} |
Registration point for Ecm timer reset
@param h handler to notify
@param what user-defined message code
@param obj placed in Message.obj
| CallManager::registerForEcmTimerReset | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForEcmTimerReset(Handler h){
mEcmTimerResetRegistrants.remove(h);
} |
Unregister for notification for Ecm timer reset
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForEcmTimerReset | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForServiceStateChanged(Handler h, int what, Object obj){
mServiceStateChangedRegistrants.addUnique(h, what, obj);
} |
Register for ServiceState changed.
Message.obj will contain an AsyncResult.
AsyncResult.result will be a ServiceState instance
| CallManager::registerForServiceStateChanged | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForServiceStateChanged(Handler h){
mServiceStateChangedRegistrants.remove(h);
} |
Unregisters for ServiceStateChange notification.
Extraneous calls are tolerated silently
| CallManager::unregisterForServiceStateChanged | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForSuppServiceFailed(Handler h, int what, Object obj){
mSuppServiceFailedRegistrants.addUnique(h, what, obj);
} |
Register for notifications when a supplementary service attempt fails.
Message.obj will contain an AsyncResult.
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForSuppServiceFailed | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForSuppServiceFailed(Handler h){
mSuppServiceFailedRegistrants.remove(h);
} |
Unregister for notifications when a supplementary service attempt fails.
Extraneous calls are tolerated silently
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForSuppServiceFailed | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForInCallVoicePrivacyOn(Handler h, int what, Object obj){
mInCallVoicePrivacyOnRegistrants.addUnique(h, what, obj);
} |
Register for notifications when a sInCall VoicePrivacy is enabled
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForInCallVoicePrivacyOn | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForInCallVoicePrivacyOn(Handler h){
mInCallVoicePrivacyOnRegistrants.remove(h);
} |
Unregister for notifications when a sInCall VoicePrivacy is enabled
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForInCallVoicePrivacyOn | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForInCallVoicePrivacyOff(Handler h, int what, Object obj){
mInCallVoicePrivacyOffRegistrants.addUnique(h, what, obj);
} |
Register for notifications when a sInCall VoicePrivacy is disabled
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForInCallVoicePrivacyOff | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForInCallVoicePrivacyOff(Handler h){
mInCallVoicePrivacyOffRegistrants.remove(h);
} |
Unregister for notifications when a sInCall VoicePrivacy is disabled
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForInCallVoicePrivacyOff | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForCallWaiting(Handler h, int what, Object obj){
mCallWaitingRegistrants.addUnique(h, what, obj);
} |
Register for notifications when CDMA call waiting comes
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForCallWaiting | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForCallWaiting(Handler h){
mCallWaitingRegistrants.remove(h);
} |
Unregister for notifications when CDMA Call waiting comes
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForCallWaiting | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForSignalInfo(Handler h){
mSignalInfoRegistrants.remove(h);
} |
Unregisters for signal information notifications.
Extraneous calls are tolerated silently
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForSignalInfo | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForDisplayInfo(Handler h, int what, Object obj){
mDisplayInfoRegistrants.addUnique(h, what, obj);
} |
Register for display information notifications from the network.
Message.obj will contain an AsyncResult.
AsyncResult.result will be a SuppServiceNotification instance.
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForDisplayInfo | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForDisplayInfo(Handler h) {
mDisplayInfoRegistrants.remove(h);
} |
Unregisters for display information notifications.
Extraneous calls are tolerated silently
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForDisplayInfo | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForCdmaOtaStatusChange(Handler h, int what, Object obj){
mCdmaOtaStatusChangeRegistrants.addUnique(h, what, obj);
} |
Register for notifications when CDMA OTA Provision status change
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForCdmaOtaStatusChange | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForCdmaOtaStatusChange(Handler h){
mCdmaOtaStatusChangeRegistrants.remove(h);
} |
Unregister for notifications when CDMA OTA Provision status change
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForCdmaOtaStatusChange | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForSubscriptionInfoReady(Handler h, int what, Object obj){
mSubscriptionInfoReadyRegistrants.addUnique(h, what, obj);
} |
Registration point for subscription info ready
@param h handler to notify
@param what what code of message when delivered
@param obj placed in Message.obj
| CallManager::registerForSubscriptionInfoReady | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForSubscriptionInfoReady(Handler h){
mSubscriptionInfoReadyRegistrants.remove(h);
} |
Unregister for notifications for subscription info
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForSubscriptionInfoReady | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForPostDialCharacter(Handler h, int what, Object obj){
mPostDialCharacterRegistrants.addUnique(h, what, obj);
} |
Sets an event to be fired when the telephony system processes
a post-dial character on an outgoing call.<p>
Messages of type <code>what</code> will be sent to <code>h</code>.
The <code>obj</code> field of these Message's will be instances of
<code>AsyncResult</code>. <code>Message.obj.result</code> will be
a Connection object.<p>
Message.arg1 will be the post dial character being processed,
or 0 ('\0') if end of string.<p>
If Connection.getPostDialState() == WAIT,
the application must call
{@link com.android.internal.telephony.Connection#proceedAfterWaitChar()
Connection.proceedAfterWaitChar()} or
{@link com.android.internal.telephony.Connection#cancelPostDial()
Connection.cancelPostDial()}
for the telephony system to continue playing the post-dial
DTMF sequence.<p>
If Connection.getPostDialState() == WILD,
the application must call
{@link com.android.internal.telephony.Connection#proceedAfterWildChar
Connection.proceedAfterWildChar()}
or
{@link com.android.internal.telephony.Connection#cancelPostDial()
Connection.cancelPostDial()}
for the telephony system to continue playing the
post-dial DTMF sequence.<p>
| CallManager::registerForPostDialCharacter | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void registerForTtyModeReceived(Handler h, int what, Object obj){
mTtyModeReceivedRegistrants.addUnique(h, what, obj);
} |
Register for TTY mode change notifications from the network.
Message.obj will contain an AsyncResult.
AsyncResult.result will be an Integer containing new mode.
@param h Handler that receives the notification message.
@param what User-defined message code.
@param obj User object.
| CallManager::registerForTtyModeReceived | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public void unregisterForTtyModeReceived(Handler h) {
mTtyModeReceivedRegistrants.remove(h);
} |
Unregisters for TTY mode change notifications.
Extraneous calls are tolerated silently
@param h Handler to be removed from the registrant list.
| CallManager::unregisterForTtyModeReceived | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public List<Call> getForegroundCalls() {
return Collections.unmodifiableList(mForegroundCalls);
} |
@return list of all foreground calls
| CallManager::getForegroundCalls | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean hasActiveRingingCall() {
return (getFirstActiveCall(mRingingCalls) != null);
} |
Return true if there is at least one active ringing call
| CallManager::hasActiveRingingCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public Call getActiveFgCall() {
Call call = getFirstNonIdleCall(mForegroundCalls);
if (call == null) {
call = (mDefaultPhone == null)
? null
: mDefaultPhone.getForegroundCall();
}
return call;
} |
return the active foreground call from foreground calls
Active call means the call is NOT in Call.State.IDLE
1. If there is active foreground call, return it
2. If there is no active foreground call, return the
foreground call associated with default phone, which state is IDLE.
3. If there is no phone registered at all, return null.
| CallManager::getActiveFgCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public Call.State getActiveFgCallState() {
Call fgCall = getActiveFgCall();
if (fgCall != null) {
return fgCall.getState();
}
return Call.State.IDLE;
} |
@return the state of active foreground call
return IDLE if there is no active foreground call
| CallManager::getActiveFgCallState | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public List<Connection> getFgCallConnections(int subId) {
Call fgCall = getActiveFgCall(subId);
if ( fgCall != null) {
return fgCall.getConnections();
}
return mEmptyConnections;
} |
@return the connections of active foreground call
return empty list if there is no active foreground call
| CallManager::getFgCallConnections | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean hasDisconnectedFgCall() {
return (getFirstCallOfState(mForegroundCalls, Call.State.DISCONNECTED) != null);
} |
@return true if there is at least one Foreground call in disconnected state
| CallManager::hasDisconnectedFgCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean hasDisconnectedFgCall(int subId) {
return (getFirstCallOfState(mForegroundCalls, Call.State.DISCONNECTED,
subId) != null);
} |
@return true if there is at least one Foreground call in disconnected state
| CallManager::hasDisconnectedFgCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean hasDisconnectedBgCall() {
return (getFirstCallOfState(mBackgroundCalls, Call.State.DISCONNECTED) != null);
} |
@return true if there is at least one background call in disconnected state
| CallManager::hasDisconnectedBgCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public boolean hasDisconnectedBgCall(int subId) {
return (getFirstCallOfState(mBackgroundCalls, Call.State.DISCONNECTED,
subId) != null);
} |
@return true if there is at least one background call in disconnected state
| CallManager::hasDisconnectedBgCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
private Call getFirstActiveCall(ArrayList<Call> calls) {
for (Call call : calls) {
if (!call.isIdle()) {
return call;
}
}
return null;
} |
@return the first active call from a call list
| CallManager::getFirstActiveCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
private Call getFirstActiveCall(ArrayList<Call> calls, int subId) {
for (Call call : calls) {
if ((!call.isIdle()) && ((call.getPhone().getSubId() == subId) ||
(call.getPhone() instanceof SipPhone))) {
return call;
}
}
return null;
} |
@return the first active call from a call list
| CallManager::getFirstActiveCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
private Call getFirstCallOfState(ArrayList<Call> calls, Call.State state) {
for (Call call : calls) {
if (call.getState() == state) {
return call;
}
}
return null;
} |
@return the first call in a the Call.state from a call list
| CallManager::getFirstCallOfState | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
private Call getFirstCallOfState(ArrayList<Call> calls, Call.State state,
int subId) {
for (Call call : calls) {
if ((call.getState() == state) ||
((call.getPhone().getSubId() == subId) ||
(call.getPhone() instanceof SipPhone))) {
return call;
}
}
return null;
} |
@return the first call in a the Call.state from a call list
| CallManager::getFirstCallOfState | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
private boolean hasMoreThanOneHoldingCall(int subId) {
int count = 0;
for (Call call : mBackgroundCalls) {
if ((call.getState() == Call.State.HOLDING) &&
((call.getPhone().getSubId() == subId) ||
(call.getPhone() instanceof SipPhone))) {
if (++count > 1) return true;
}
}
return false;
} |
@return true if more than one active background call exists on
the provided subId.
This checks for the background calls on provided
subId and also background calls on SIP Phone.
| CallManager::hasMoreThanOneHoldingCall | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/telephony/CallManager.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/telephony/CallManager.java | MIT |
public PipedOutputStream(PipedInputStream snk) throws IOException {
connect(snk);
} |
Creates a piped output stream connected to the specified piped
input stream. Data bytes written to this stream will then be
available as input from <code>snk</code>.
@param snk The piped input stream to connect to.
@exception IOException if an I/O error occurs.
| PipedOutputStream::PipedOutputStream | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public PipedOutputStream() {
} |
Creates a piped output stream that is not yet connected to a
piped input stream. It must be connected to a piped input stream,
either by the receiver or the sender, before being used.
@see java.io.PipedInputStream#connect(java.io.PipedOutputStream)
@see java.io.PipedOutputStream#connect(java.io.PipedInputStream)
| PipedOutputStream::PipedOutputStream | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public synchronized void connect(PipedInputStream snk) throws IOException {
if (snk == null) {
throw new NullPointerException();
} else if (sink != null || snk.connected) {
throw new IOException("Already connected");
}
sink = snk;
snk.in = -1;
snk.out = 0;
snk.connected = true;
} |
Connects this piped output stream to a receiver. If this object
is already connected to some other piped input stream, an
<code>IOException</code> is thrown.
<p>
If <code>snk</code> is an unconnected piped input stream and
<code>src</code> is an unconnected piped output stream, they may
be connected by either the call:
<blockquote><pre>
src.connect(snk)</pre></blockquote>
or the call:
<blockquote><pre>
snk.connect(src)</pre></blockquote>
The two calls have the same effect.
@param snk the piped input stream to connect to.
@exception IOException if an I/O error occurs.
| PipedOutputStream::connect | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public void write(int b) throws IOException {
if (sink == null) {
throw new IOException("Pipe not connected");
}
sink.receive(b);
} |
Writes the specified <code>byte</code> to the piped output stream.
<p>
Implements the <code>write</code> method of <code>OutputStream</code>.
@param b the <code>byte</code> to be written.
@exception IOException if the pipe is <a href=#BROKEN> broken</a>,
{@link #connect(java.io.PipedInputStream) unconnected},
closed, or if an I/O error occurs.
| PipedOutputStream::write | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public void write(byte b[], int off, int len) throws IOException {
if (sink == null) {
throw new IOException("Pipe not connected");
} else if (b == null) {
throw new NullPointerException();
} else if ((off < 0) || (off > b.length) || (len < 0) ||
((off + len) > b.length) || ((off + len) < 0)) {
throw new IndexOutOfBoundsException();
} else if (len == 0) {
return;
}
sink.receive(b, off, len);
} |
Writes <code>len</code> bytes from the specified byte array
starting at offset <code>off</code> to this piped output stream.
This method blocks until all the bytes are written to the output
stream.
@param b the data.
@param off the start offset in the data.
@param len the number of bytes to write.
@exception IOException if the pipe is <a href=#BROKEN> broken</a>,
{@link #connect(java.io.PipedInputStream) unconnected},
closed, or if an I/O error occurs.
| PipedOutputStream::write | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public synchronized void flush() throws IOException {
if (sink != null) {
synchronized (sink) {
sink.notifyAll();
}
}
} |
Flushes this output stream and forces any buffered output bytes
to be written out.
This will notify any readers that bytes are waiting in the pipe.
@exception IOException if an I/O error occurs.
| PipedOutputStream::flush | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public void close() throws IOException {
if (sink != null) {
sink.receivedLast();
}
} |
Closes this piped output stream and releases any system resources
associated with this stream. This stream may no longer be used for
writing bytes.
@exception IOException if an I/O error occurs.
| PipedOutputStream::close | java | Reginer/aosp-android-jar | android-33/src/java/io/PipedOutputStream.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-33/src/java/io/PipedOutputStream.java | MIT |
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead. | ProtoLogImpl::d | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static void v(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.VERBOSE, group, messageHash, paramsMask, messageString,
args);
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead. | ProtoLogImpl::v | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static void i(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.INFO, group, messageHash, paramsMask, messageString, args);
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void v(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.VERBOSE, group, messageHash, paramsMask, messageString,
args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead. | ProtoLogImpl::i | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static void w(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.WARN, group, messageHash, paramsMask, messageString, args);
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void v(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.VERBOSE, group, messageHash, paramsMask, messageString,
args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void i(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.INFO, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead. | ProtoLogImpl::w | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static void e(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.ERROR, group, messageHash, paramsMask, messageString, args);
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void v(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.VERBOSE, group, messageHash, paramsMask, messageString,
args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void i(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.INFO, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void w(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.WARN, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead. | ProtoLogImpl::e | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static void wtf(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.WTF, group, messageHash, paramsMask, messageString, args);
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void v(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.VERBOSE, group, messageHash, paramsMask, messageString,
args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void i(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.INFO, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void w(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.WARN, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void e(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.ERROR, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead. | ProtoLogImpl::wtf | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static boolean isEnabled(IProtoLogGroup group) {
return group.isLogToLogcat()
|| (group.isLogToProto() && getSingleInstance().isProtoEnabled());
} |
A service for the ProtoLog logging system.
public class ProtoLogImpl extends BaseProtoLogImpl {
private static final int BUFFER_CAPACITY = 1024 * 1024;
private static final String LOG_FILENAME = "/data/misc/wmtrace/wm_log.winscope";
private static final String VIEWER_CONFIG_FILENAME = "/system/etc/protolog.conf.json.gz";
private static ProtoLogImpl sServiceInstance = null;
static {
addLogGroupEnum(ProtoLogGroup.values());
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void d(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.DEBUG, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void v(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.VERBOSE, group, messageHash, paramsMask, messageString,
args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void i(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.INFO, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void w(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.WARN, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void e(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance()
.log(LogLevel.ERROR, group, messageHash, paramsMask, messageString, args);
}
/** Used by the ProtoLogTool, do not call directly - use {@code ProtoLog} class instead.
public static void wtf(IProtoLogGroup group, int messageHash, int paramsMask,
@Nullable String messageString,
Object... args) {
getSingleInstance().log(LogLevel.WTF, group, messageHash, paramsMask, messageString, args);
}
/** Returns true iff logging is enabled for the given {@code IProtoLogGroup}. | ProtoLogImpl::isEnabled | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
public static synchronized ProtoLogImpl getSingleInstance() {
if (sServiceInstance == null) {
sServiceInstance = new ProtoLogImpl(
new File(LOG_FILENAME), BUFFER_CAPACITY, new ProtoLogViewerConfigReader());
}
return sServiceInstance;
} |
Returns the single instance of the ProtoLogImpl singleton class.
| ProtoLogImpl::getSingleInstance | java | Reginer/aosp-android-jar | android-32/src/com/android/internal/protolog/ProtoLogImpl.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/com/android/internal/protolog/ProtoLogImpl.java | MIT |
private void onServiceReady(ICarrierMessagingService carrierMessagingService) {
mICarrierMessagingService = carrierMessagingService;
if (mOnServiceReadyCallback != null && mServiceReadyCallbackExecutor != null) {
final long identity = Binder.clearCallingIdentity();
try {
mServiceReadyCallbackExecutor.execute(mOnServiceReadyCallback);
} finally {
Binder.restoreCallingIdentity(identity);
}
}
} |
Called when connection with service is established.
@param carrierMessagingService the carrier messaing service interface
| CarrierMessagingServiceWrapper::onServiceReady | java | Reginer/aosp-android-jar | android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | MIT |
default void onReceiveSmsComplete(
@CarrierMessagingService.FilterCompleteResult int result) {
} |
Response callback for {@link CarrierMessagingServiceWrapper#receiveSms}.
@param result a bitmask integer to indicate how the incoming text SMS should be handled
by the platform. Bits set can be
{@link CarrierMessagingService#RECEIVE_OPTIONS_DROP} and
{@link CarrierMessagingService#
RECEIVE_OPTIONS_SKIP_NOTIFY_WHEN_CREDENTIAL_PROTECTED_STORAGE_UNAVAILABLE}.
{@link CarrierMessagingService#onReceiveTextSms}.
| CarrierMessagingServiceConnection::onReceiveSmsComplete | java | Reginer/aosp-android-jar | android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | MIT |
default void onSendSmsComplete(@CarrierMessagingService.SendResult
int result, int messageRef) {
} |
Response callback for {@link CarrierMessagingServiceWrapper#sendTextSms} and
{@link CarrierMessagingServiceWrapper#sendDataSms}.
@param result send status, one of {@link CarrierMessagingService#SEND_STATUS_OK},
{@link CarrierMessagingService#SEND_STATUS_RETRY_ON_CARRIER_NETWORK},
and {@link CarrierMessagingService#SEND_STATUS_ERROR}.
@param messageRef message reference of the just-sent message. This field is applicable
only if result is {@link CarrierMessagingService#SEND_STATUS_OK}.
| CarrierMessagingServiceConnection::onSendSmsComplete | java | Reginer/aosp-android-jar | android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | MIT |
default void onSendMultipartSmsComplete(@CarrierMessagingService.SendResult
int result, @Nullable int[] messageRefs) {
} |
Response callback for {@link CarrierMessagingServiceWrapper#sendMultipartTextSms}.
@param result send status, one of {@link CarrierMessagingService#SEND_STATUS_OK},
{@link CarrierMessagingService#SEND_STATUS_RETRY_ON_CARRIER_NETWORK},
and {@link CarrierMessagingService#SEND_STATUS_ERROR}.
@param messageRefs an array of message references, one for each part of the
multipart SMS. This field is applicable only if result is
{@link CarrierMessagingService#SEND_STATUS_OK}.
| CarrierMessagingServiceConnection::onSendMultipartSmsComplete | java | Reginer/aosp-android-jar | android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | MIT |
default void onSendMmsComplete(@CarrierMessagingService.SendResult
int result, @Nullable byte[] sendConfPdu) {
} |
Response callback for {@link CarrierMessagingServiceWrapper#sendMms}.
@param result send status, one of {@link CarrierMessagingService#SEND_STATUS_OK},
{@link CarrierMessagingService#SEND_STATUS_RETRY_ON_CARRIER_NETWORK},
and {@link CarrierMessagingService#SEND_STATUS_ERROR}.
@param sendConfPdu a possibly {code null} SendConf PDU, which confirms that the message
was sent. sendConfPdu is ignored if the {@code result} is not
{@link CarrierMessagingService#SEND_STATUS_OK}.
| CarrierMessagingServiceConnection::onSendMmsComplete | java | Reginer/aosp-android-jar | android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | MIT |
default void onDownloadMmsComplete(@CarrierMessagingService.DownloadResult
int result) {
} |
Response callback for {@link CarrierMessagingServiceWrapper#downloadMms}.
@param result download status, one of {@link CarrierMessagingService#DOWNLOAD_STATUS_OK},
{@link CarrierMessagingService#DOWNLOAD_STATUS_RETRY_ON_CARRIER_NETWORK},
and {@link CarrierMessagingService#DOWNLOAD_STATUS_ERROR}.
| CarrierMessagingServiceConnection::onDownloadMmsComplete | java | Reginer/aosp-android-jar | android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/service/carrier/CarrierMessagingServiceWrapper.java | MIT |
public ArithmeticException() {
super();
} |
Constructs an {@code ArithmeticException} with no detail
message.
| ArithmeticException::ArithmeticException | java | Reginer/aosp-android-jar | android-34/src/java/lang/ArithmeticException.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/java/lang/ArithmeticException.java | MIT |
public ArithmeticException(String s) {
super(s);
} |
Constructs an {@code ArithmeticException} with the specified
detail message.
@param s the detail message.
| ArithmeticException::ArithmeticException | java | Reginer/aosp-android-jar | android-34/src/java/lang/ArithmeticException.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/java/lang/ArithmeticException.java | MIT |
public static @Config int activityInfoConfigNativeToJava(@NativeConfig int input) {
int output = 0;
for (int i = 0; i < CONFIG_NATIVE_BITS.length; i++) {
if ((input & CONFIG_NATIVE_BITS[i]) != 0) {
output |= (1 << i);
}
}
return output;
} |
Convert native change bits to Java.
@hide
| ActivityInfo::activityInfoConfigNativeToJava | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public int getRealConfigChanged() {
return applicationInfo.targetSdkVersion < android.os.Build.VERSION_CODES.HONEYCOMB_MR2
? (configChanges | ActivityInfo.CONFIG_SCREEN_SIZE
| ActivityInfo.CONFIG_SMALLEST_SCREEN_SIZE)
: configChanges;
} |
@hide
Unfortunately some developers (OpenFeint I am looking at you) have
compared the configChanges bit field against absolute values, so if we
introduce a new bit they break. To deal with that, we will make sure
the public field will not have a value that breaks them, and let the
framework call here to get the real value.
| ActivityInfo::getRealConfigChanged | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public static final String lockTaskLaunchModeToString(int lockTaskLaunchMode) {
switch (lockTaskLaunchMode) {
case LOCK_TASK_LAUNCH_MODE_DEFAULT:
return "LOCK_TASK_LAUNCH_MODE_DEFAULT";
case LOCK_TASK_LAUNCH_MODE_NEVER:
return "LOCK_TASK_LAUNCH_MODE_NEVER";
case LOCK_TASK_LAUNCH_MODE_ALWAYS:
return "LOCK_TASK_LAUNCH_MODE_ALWAYS";
case LOCK_TASK_LAUNCH_MODE_IF_ALLOWLISTED:
return "LOCK_TASK_LAUNCH_MODE_IF_ALLOWLISTED";
default:
return "unknown=" + lockTaskLaunchMode;
}
} |
Screen rotation animation desired by the activity, with values as defined
for {@link android.view.WindowManager.LayoutParams#rotationAnimation}.
-1 means to use the system default.
@hide
public int rotationAnimation = -1;
/** @hide
public static final int LOCK_TASK_LAUNCH_MODE_DEFAULT = 0;
/** @hide
public static final int LOCK_TASK_LAUNCH_MODE_NEVER = 1;
/** @hide
public static final int LOCK_TASK_LAUNCH_MODE_ALWAYS = 2;
/** @hide
public static final int LOCK_TASK_LAUNCH_MODE_IF_ALLOWLISTED = 3;
/** @hide | ActivityInfo::lockTaskLaunchModeToString | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public final int getThemeResource() {
return theme != 0 ? theme : applicationInfo.theme;
} |
Return the theme resource identifier to use for this activity. If
the activity defines a theme, that is used; else, the application
theme is used.
@return The theme associated with this activity.
| ActivityInfo::getThemeResource | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public boolean hasFixedAspectRatio(@ScreenOrientation int orientation) {
return getMaxAspectRatio() != 0 || getMinAspectRatio(orientation) != 0;
} |
Returns true if the activity has maximum or minimum aspect ratio.
@hide
| ActivityInfo::hasFixedAspectRatio | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public boolean isFixedOrientation() {
return isFixedOrientationLandscape() || isFixedOrientationPortrait()
|| screenOrientation == SCREEN_ORIENTATION_LOCKED;
} |
Returns true if the activity's orientation is fixed.
@hide
| ActivityInfo::isFixedOrientation | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
boolean isFixedOrientationLandscape() {
return isFixedOrientationLandscape(screenOrientation);
} |
Returns true if the activity's orientation is fixed to landscape.
@hide
| ActivityInfo::isFixedOrientationLandscape | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public static boolean isFixedOrientationLandscape(@ScreenOrientation int orientation) {
return orientation == SCREEN_ORIENTATION_LANDSCAPE
|| orientation == SCREEN_ORIENTATION_SENSOR_LANDSCAPE
|| orientation == SCREEN_ORIENTATION_REVERSE_LANDSCAPE
|| orientation == SCREEN_ORIENTATION_USER_LANDSCAPE;
} |
Returns true if the activity's orientation is fixed to landscape.
@hide
| ActivityInfo::isFixedOrientationLandscape | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
boolean isFixedOrientationPortrait() {
return isFixedOrientationPortrait(screenOrientation);
} |
Returns true if the activity's orientation is fixed to portrait.
@hide
| ActivityInfo::isFixedOrientationPortrait | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public static boolean isFixedOrientationPortrait(@ScreenOrientation int orientation) {
return orientation == SCREEN_ORIENTATION_PORTRAIT
|| orientation == SCREEN_ORIENTATION_SENSOR_PORTRAIT
|| orientation == SCREEN_ORIENTATION_REVERSE_PORTRAIT
|| orientation == SCREEN_ORIENTATION_USER_PORTRAIT;
} |
Returns true if the activity's orientation is fixed to portrait.
@hide
| ActivityInfo::isFixedOrientationPortrait | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public boolean neverSandboxDisplayApis(ConstrainDisplayApisConfig constrainDisplayApisConfig) {
return isChangeEnabled(NEVER_SANDBOX_DISPLAY_APIS)
|| constrainDisplayApisConfig.getNeverConstrainDisplayApis(applicationInfo);
} |
Returns if the activity should never be sandboxed to the activity window bounds.
@hide
| ActivityInfo::neverSandboxDisplayApis | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public boolean alwaysSandboxDisplayApis(ConstrainDisplayApisConfig constrainDisplayApisConfig) {
return isChangeEnabled(ALWAYS_SANDBOX_DISPLAY_APIS)
|| constrainDisplayApisConfig.getAlwaysConstrainDisplayApis(applicationInfo);
} |
Returns if the activity should always be sandboxed to the activity window bounds.
@hide
| ActivityInfo::alwaysSandboxDisplayApis | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public void setMaxAspectRatio(float maxAspectRatio) {
this.mMaxAspectRatio = maxAspectRatio;
} |
Returns if the activity should always be sandboxed to the activity window bounds.
@hide
public boolean alwaysSandboxDisplayApis(ConstrainDisplayApisConfig constrainDisplayApisConfig) {
return isChangeEnabled(ALWAYS_SANDBOX_DISPLAY_APIS)
|| constrainDisplayApisConfig.getAlwaysConstrainDisplayApis(applicationInfo);
}
/** @hide | ActivityInfo::setMaxAspectRatio | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public float getMaxAspectRatio() {
return mMaxAspectRatio;
} |
Returns if the activity should always be sandboxed to the activity window bounds.
@hide
public boolean alwaysSandboxDisplayApis(ConstrainDisplayApisConfig constrainDisplayApisConfig) {
return isChangeEnabled(ALWAYS_SANDBOX_DISPLAY_APIS)
|| constrainDisplayApisConfig.getAlwaysConstrainDisplayApis(applicationInfo);
}
/** @hide
public void setMaxAspectRatio(float maxAspectRatio) {
this.mMaxAspectRatio = maxAspectRatio;
}
/** @hide | ActivityInfo::getMaxAspectRatio | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public void setMinAspectRatio(float minAspectRatio) {
this.mMinAspectRatio = minAspectRatio;
} |
Returns if the activity should always be sandboxed to the activity window bounds.
@hide
public boolean alwaysSandboxDisplayApis(ConstrainDisplayApisConfig constrainDisplayApisConfig) {
return isChangeEnabled(ALWAYS_SANDBOX_DISPLAY_APIS)
|| constrainDisplayApisConfig.getAlwaysConstrainDisplayApis(applicationInfo);
}
/** @hide
public void setMaxAspectRatio(float maxAspectRatio) {
this.mMaxAspectRatio = maxAspectRatio;
}
/** @hide
public float getMaxAspectRatio() {
return mMaxAspectRatio;
}
/** @hide | ActivityInfo::setMinAspectRatio | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public float getMinAspectRatio(@ScreenOrientation int orientation) {
if (applicationInfo == null || !isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO) || (
isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_PORTRAIT_ONLY)
&& !isFixedOrientationPortrait(orientation))) {
return mMinAspectRatio;
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_LARGE)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_LARGE_VALUE, mMinAspectRatio);
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM_VALUE, mMinAspectRatio);
}
return mMinAspectRatio;
} |
Returns the min aspect ratio of this activity.
This takes into account the minimum aspect ratio as defined in the app's manifest and
possible overrides as per OVERRIDE_MIN_ASPECT_RATIO.
In the rare cases where the manifest minimum aspect ratio is required, use
{@code getManifestMinAspectRatio}.
@hide
| ActivityInfo::getMinAspectRatio | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public float getManifestMinAspectRatio() {
return mMinAspectRatio;
} |
Returns the min aspect ratio of this activity.
This takes into account the minimum aspect ratio as defined in the app's manifest and
possible overrides as per OVERRIDE_MIN_ASPECT_RATIO.
In the rare cases where the manifest minimum aspect ratio is required, use
{@code getManifestMinAspectRatio}.
@hide
public float getMinAspectRatio(@ScreenOrientation int orientation) {
if (applicationInfo == null || !isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO) || (
isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_PORTRAIT_ONLY)
&& !isFixedOrientationPortrait(orientation))) {
return mMinAspectRatio;
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_LARGE)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_LARGE_VALUE, mMinAspectRatio);
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM_VALUE, mMinAspectRatio);
}
return mMinAspectRatio;
}
private boolean isChangeEnabled(long changeId) {
return CompatChanges.isChangeEnabled(changeId, applicationInfo.packageName,
UserHandle.getUserHandleForUid(applicationInfo.uid));
}
/** @hide | ActivityInfo::getManifestMinAspectRatio | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public static boolean isPreserveOrientationMode(int mode) {
return mode == RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION;
} |
Returns the min aspect ratio of this activity.
This takes into account the minimum aspect ratio as defined in the app's manifest and
possible overrides as per OVERRIDE_MIN_ASPECT_RATIO.
In the rare cases where the manifest minimum aspect ratio is required, use
{@code getManifestMinAspectRatio}.
@hide
public float getMinAspectRatio(@ScreenOrientation int orientation) {
if (applicationInfo == null || !isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO) || (
isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_PORTRAIT_ONLY)
&& !isFixedOrientationPortrait(orientation))) {
return mMinAspectRatio;
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_LARGE)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_LARGE_VALUE, mMinAspectRatio);
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM_VALUE, mMinAspectRatio);
}
return mMinAspectRatio;
}
private boolean isChangeEnabled(long changeId) {
return CompatChanges.isChangeEnabled(changeId, applicationInfo.packageName,
UserHandle.getUserHandleForUid(applicationInfo.uid));
}
/** @hide
public float getManifestMinAspectRatio() {
return mMinAspectRatio;
}
/** @hide
@UnsupportedAppUsage
public static boolean isResizeableMode(int mode) {
return mode == RESIZE_MODE_RESIZEABLE
|| mode == RESIZE_MODE_FORCE_RESIZEABLE
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION
|| mode == RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION;
}
/** @hide | ActivityInfo::isPreserveOrientationMode | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public static String resizeModeToString(int mode) {
switch (mode) {
case RESIZE_MODE_UNRESIZEABLE:
return "RESIZE_MODE_UNRESIZEABLE";
case RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION:
return "RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION";
case RESIZE_MODE_RESIZEABLE:
return "RESIZE_MODE_RESIZEABLE";
case RESIZE_MODE_FORCE_RESIZEABLE:
return "RESIZE_MODE_FORCE_RESIZEABLE";
case RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY:
return "RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY";
case RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY:
return "RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY";
case RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION:
return "RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION";
default:
return "unknown=" + mode;
}
} |
Returns the min aspect ratio of this activity.
This takes into account the minimum aspect ratio as defined in the app's manifest and
possible overrides as per OVERRIDE_MIN_ASPECT_RATIO.
In the rare cases where the manifest minimum aspect ratio is required, use
{@code getManifestMinAspectRatio}.
@hide
public float getMinAspectRatio(@ScreenOrientation int orientation) {
if (applicationInfo == null || !isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO) || (
isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_PORTRAIT_ONLY)
&& !isFixedOrientationPortrait(orientation))) {
return mMinAspectRatio;
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_LARGE)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_LARGE_VALUE, mMinAspectRatio);
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM_VALUE, mMinAspectRatio);
}
return mMinAspectRatio;
}
private boolean isChangeEnabled(long changeId) {
return CompatChanges.isChangeEnabled(changeId, applicationInfo.packageName,
UserHandle.getUserHandleForUid(applicationInfo.uid));
}
/** @hide
public float getManifestMinAspectRatio() {
return mMinAspectRatio;
}
/** @hide
@UnsupportedAppUsage
public static boolean isResizeableMode(int mode) {
return mode == RESIZE_MODE_RESIZEABLE
|| mode == RESIZE_MODE_FORCE_RESIZEABLE
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION
|| mode == RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION;
}
/** @hide
public static boolean isPreserveOrientationMode(int mode) {
return mode == RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION;
}
/** @hide | ActivityInfo::resizeModeToString | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public static String sizeChangesSupportModeToString(@SizeChangesSupportMode int mode) {
switch (mode) {
case SIZE_CHANGES_UNSUPPORTED_METADATA:
return "SIZE_CHANGES_UNSUPPORTED_METADATA";
case SIZE_CHANGES_UNSUPPORTED_OVERRIDE:
return "SIZE_CHANGES_UNSUPPORTED_OVERRIDE";
case SIZE_CHANGES_SUPPORTED_METADATA:
return "SIZE_CHANGES_SUPPORTED_METADATA";
case SIZE_CHANGES_SUPPORTED_OVERRIDE:
return "SIZE_CHANGES_SUPPORTED_OVERRIDE";
default:
return "unknown=" + mode;
}
} |
Returns the min aspect ratio of this activity.
This takes into account the minimum aspect ratio as defined in the app's manifest and
possible overrides as per OVERRIDE_MIN_ASPECT_RATIO.
In the rare cases where the manifest minimum aspect ratio is required, use
{@code getManifestMinAspectRatio}.
@hide
public float getMinAspectRatio(@ScreenOrientation int orientation) {
if (applicationInfo == null || !isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO) || (
isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_PORTRAIT_ONLY)
&& !isFixedOrientationPortrait(orientation))) {
return mMinAspectRatio;
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_LARGE)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_LARGE_VALUE, mMinAspectRatio);
}
if (isChangeEnabled(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM)) {
return Math.max(OVERRIDE_MIN_ASPECT_RATIO_MEDIUM_VALUE, mMinAspectRatio);
}
return mMinAspectRatio;
}
private boolean isChangeEnabled(long changeId) {
return CompatChanges.isChangeEnabled(changeId, applicationInfo.packageName,
UserHandle.getUserHandleForUid(applicationInfo.uid));
}
/** @hide
public float getManifestMinAspectRatio() {
return mMinAspectRatio;
}
/** @hide
@UnsupportedAppUsage
public static boolean isResizeableMode(int mode) {
return mode == RESIZE_MODE_RESIZEABLE
|| mode == RESIZE_MODE_FORCE_RESIZEABLE
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION
|| mode == RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION;
}
/** @hide
public static boolean isPreserveOrientationMode(int mode) {
return mode == RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY
|| mode == RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION;
}
/** @hide
public static String resizeModeToString(int mode) {
switch (mode) {
case RESIZE_MODE_UNRESIZEABLE:
return "RESIZE_MODE_UNRESIZEABLE";
case RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION:
return "RESIZE_MODE_RESIZEABLE_VIA_SDK_VERSION";
case RESIZE_MODE_RESIZEABLE:
return "RESIZE_MODE_RESIZEABLE";
case RESIZE_MODE_FORCE_RESIZEABLE:
return "RESIZE_MODE_FORCE_RESIZEABLE";
case RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY:
return "RESIZE_MODE_FORCE_RESIZABLE_PORTRAIT_ONLY";
case RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY:
return "RESIZE_MODE_FORCE_RESIZABLE_LANDSCAPE_ONLY";
case RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION:
return "RESIZE_MODE_FORCE_RESIZABLE_PRESERVE_ORIENTATION";
default:
return "unknown=" + mode;
}
}
/** @hide | ActivityInfo::sizeChangesSupportModeToString | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
public boolean shouldCheckMinWidthHeightForMultiWindow() {
return isChangeEnabled(CHECK_MIN_WIDTH_HEIGHT_FOR_MULTI_WINDOW);
} |
Whether we should compare activity window layout min width/height with require space for
multi window to determine if it can be put into multi window mode.
@hide
| ActivityInfo::shouldCheckMinWidthHeightForMultiWindow | java | Reginer/aosp-android-jar | android-32/src/android/content/pm/ActivityInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/android/content/pm/ActivityInfo.java | MIT |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.