diff options
| author | 2021-04-14 00:31:16 +0000 | |
|---|---|---|
| committer | 2021-04-14 00:31:16 +0000 | |
| commit | 23bbd41fdefd1c272824f0e2a2e9cb0bc06105dc (patch) | |
| tree | 2ea5f1263273b2fe5ace6fd0f2fab15e35a245a8 | |
| parent | 97b4639efa162db8222967dfa575e44751a5b82c (diff) | |
| parent | 839387b75d378e855099208c78965614bf402a46 (diff) | |
Merge "[RCS]Migrate from getEncodedMessage() to toEncodedMessage()"
| -rw-r--r-- | core/api/system-current.txt | 1 | ||||
| -rw-r--r-- | telephony/java/android/telephony/ims/SipMessage.java | 17 |
2 files changed, 0 insertions, 18 deletions
diff --git a/core/api/system-current.txt b/core/api/system-current.txt index 5edd16a4b970..1102a0d66697 100644 --- a/core/api/system-current.txt +++ b/core/api/system-current.txt @@ -12004,7 +12004,6 @@ package android.telephony.ims { method public int describeContents(); method @Nullable public String getCallIdParameter(); method @NonNull public byte[] getContent(); - method @Deprecated @NonNull public byte[] getEncodedMessage(); method @NonNull public String getHeaderSection(); method @NonNull public String getStartLine(); method @NonNull public String getViaBranchParameter(); diff --git a/telephony/java/android/telephony/ims/SipMessage.java b/telephony/java/android/telephony/ims/SipMessage.java index d21fcab264d3..391372ac8ac1 100644 --- a/telephony/java/android/telephony/ims/SipMessage.java +++ b/telephony/java/android/telephony/ims/SipMessage.java @@ -203,23 +203,6 @@ public final class SipMessage implements Parcelable { } /** - * @return the UTF-8 encoded SIP message. - * @deprecated Use {@link #toEncodedMessage} instead - */ - @Deprecated - public @NonNull byte[] getEncodedMessage() { - byte[] header = new StringBuilder() - .append(mStartLine) - .append(mHeaderSection) - .append(CRLF) - .toString().getBytes(UTF_8); - byte[] sipMessage = new byte[header.length + mContent.length]; - System.arraycopy(header, 0, sipMessage, 0, header.length); - System.arraycopy(mContent, 0, sipMessage, header.length, mContent.length); - return sipMessage; - } - - /** * According RFC-3261 section 7, SIP is a text protocol and uses the UTF-8 charset. Its format * consists of a start-line, one or more header fields, an empty line indicating the end of the * header fields, and an optional message-body. |