Loading core/java/android/view/textclassifier/ConversationAction.java +1 −1 Original line number Diff line number Diff line Loading @@ -266,7 +266,7 @@ public final class ConversationAction implements Parcelable { mAction, mTextReply, mScore, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } } core/java/android/view/textclassifier/ConversationActions.java +1 −1 Original line number Diff line number Diff line Loading @@ -275,7 +275,7 @@ public final class ConversationActions implements Parcelable { mAuthor, mReferenceTime, mText == null ? null : new SpannedString(mText), mExtras == null ? new Bundle() : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } } Loading core/java/android/view/textclassifier/TextClassification.java +2 −2 Original line number Diff line number Diff line Loading @@ -521,7 +521,7 @@ public final class TextClassification implements Parcelable { } private Bundle buildExtras(EntityConfidence entityConfidence) { final Bundle extras = mExtras == null ? new Bundle() : mExtras.deepCopy(); final Bundle extras = mExtras == null ? new Bundle() : mExtras; if (mActionIntents.stream().anyMatch(Objects::nonNull)) { ExtrasUtils.putActionsIntents(extras, mActionIntents); } Loading Loading @@ -713,7 +713,7 @@ public final class TextClassification implements Parcelable { public Request build() { return new Request(new SpannedString(mText), mStartIndex, mEndIndex, mDefaultLocales, mReferenceTime, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } Loading core/java/android/view/textclassifier/TextLanguage.java +6 −10 Original line number Diff line number Diff line Loading @@ -113,12 +113,11 @@ public final class TextLanguage implements Parcelable { * Returns a bundle containing non-structured extra information about this result. What is * returned in the extras is specific to the {@link TextClassifier} implementation. * * <p><b>NOTE: </b>Each call to this method returns a new bundle copy so clients should prefer * to hold a reference to the returned bundle rather than frequently calling this method. * <p><b>NOTE: </b>Do not modify this bundle. */ @NonNull public Bundle getExtras() { return mBundle.deepCopy(); return mBundle; } @Override Loading Loading @@ -199,7 +198,7 @@ public final class TextLanguage implements Parcelable { */ @NonNull public TextLanguage build() { mBundle = mBundle == null ? new Bundle() : mBundle.deepCopy(); mBundle = mBundle == null ? Bundle.EMPTY : mBundle; return new TextLanguage( mId, new EntityConfidence(mEntityConfidenceMap), Loading Loading @@ -263,13 +262,11 @@ public final class TextLanguage implements Parcelable { /** * Returns a bundle containing non-structured extra information about this request. * * <p><b>NOTE: </b>Each call to this method returns a new bundle copy so clients should * prefer to hold a reference to the returned bundle rather than frequently calling this * method. * <p><b>NOTE: </b>Do not modify this bundle. */ @NonNull public Bundle getExtras() { return mExtra.deepCopy(); return mExtra; } @Override Loading Loading @@ -327,8 +324,7 @@ public final class TextLanguage implements Parcelable { */ @NonNull public Request build() { mBundle = mBundle == null ? new Bundle() : mBundle.deepCopy(); return new Request(mText.toString(), mBundle); return new Request(mText.toString(), mBundle == null ? Bundle.EMPTY : mBundle); } } } Loading core/java/android/view/textclassifier/TextLinks.java +2 −2 Original line number Diff line number Diff line Loading @@ -493,7 +493,7 @@ public final class TextLinks implements Parcelable { return new Request( mText, mDefaultLocales, mEntityConfig, mLegacyFallback, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } Loading Loading @@ -702,7 +702,7 @@ public final class TextLinks implements Parcelable { @NonNull public TextLinks build() { return new TextLinks(mFullText, mLinks, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } } Loading
core/java/android/view/textclassifier/ConversationAction.java +1 −1 Original line number Diff line number Diff line Loading @@ -266,7 +266,7 @@ public final class ConversationAction implements Parcelable { mAction, mTextReply, mScore, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } }
core/java/android/view/textclassifier/ConversationActions.java +1 −1 Original line number Diff line number Diff line Loading @@ -275,7 +275,7 @@ public final class ConversationActions implements Parcelable { mAuthor, mReferenceTime, mText == null ? null : new SpannedString(mText), mExtras == null ? new Bundle() : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } } Loading
core/java/android/view/textclassifier/TextClassification.java +2 −2 Original line number Diff line number Diff line Loading @@ -521,7 +521,7 @@ public final class TextClassification implements Parcelable { } private Bundle buildExtras(EntityConfidence entityConfidence) { final Bundle extras = mExtras == null ? new Bundle() : mExtras.deepCopy(); final Bundle extras = mExtras == null ? new Bundle() : mExtras; if (mActionIntents.stream().anyMatch(Objects::nonNull)) { ExtrasUtils.putActionsIntents(extras, mActionIntents); } Loading Loading @@ -713,7 +713,7 @@ public final class TextClassification implements Parcelable { public Request build() { return new Request(new SpannedString(mText), mStartIndex, mEndIndex, mDefaultLocales, mReferenceTime, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } Loading
core/java/android/view/textclassifier/TextLanguage.java +6 −10 Original line number Diff line number Diff line Loading @@ -113,12 +113,11 @@ public final class TextLanguage implements Parcelable { * Returns a bundle containing non-structured extra information about this result. What is * returned in the extras is specific to the {@link TextClassifier} implementation. * * <p><b>NOTE: </b>Each call to this method returns a new bundle copy so clients should prefer * to hold a reference to the returned bundle rather than frequently calling this method. * <p><b>NOTE: </b>Do not modify this bundle. */ @NonNull public Bundle getExtras() { return mBundle.deepCopy(); return mBundle; } @Override Loading Loading @@ -199,7 +198,7 @@ public final class TextLanguage implements Parcelable { */ @NonNull public TextLanguage build() { mBundle = mBundle == null ? new Bundle() : mBundle.deepCopy(); mBundle = mBundle == null ? Bundle.EMPTY : mBundle; return new TextLanguage( mId, new EntityConfidence(mEntityConfidenceMap), Loading Loading @@ -263,13 +262,11 @@ public final class TextLanguage implements Parcelable { /** * Returns a bundle containing non-structured extra information about this request. * * <p><b>NOTE: </b>Each call to this method returns a new bundle copy so clients should * prefer to hold a reference to the returned bundle rather than frequently calling this * method. * <p><b>NOTE: </b>Do not modify this bundle. */ @NonNull public Bundle getExtras() { return mExtra.deepCopy(); return mExtra; } @Override Loading Loading @@ -327,8 +324,7 @@ public final class TextLanguage implements Parcelable { */ @NonNull public Request build() { mBundle = mBundle == null ? new Bundle() : mBundle.deepCopy(); return new Request(mText.toString(), mBundle); return new Request(mText.toString(), mBundle == null ? Bundle.EMPTY : mBundle); } } } Loading
core/java/android/view/textclassifier/TextLinks.java +2 −2 Original line number Diff line number Diff line Loading @@ -493,7 +493,7 @@ public final class TextLinks implements Parcelable { return new Request( mText, mDefaultLocales, mEntityConfig, mLegacyFallback, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } Loading Loading @@ -702,7 +702,7 @@ public final class TextLinks implements Parcelable { @NonNull public TextLinks build() { return new TextLinks(mFullText, mLinks, mExtras == null ? Bundle.EMPTY : mExtras.deepCopy()); mExtras == null ? Bundle.EMPTY : mExtras); } } }