Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f67f0a58 authored by Abodunrinwa Toki's avatar Abodunrinwa Toki
Browse files

Change package for LangId and SmartSelection.

Package change from android.text to android.view.textclassifier.
This change was delayed until the native library code was updated
to reflect this package change.

Test: cts-tradefed run cts-dev -m CtsViewTestCases -t android.view.textclassifier.cts.TextClassificationManagerTest
Bug: 34777495
Change-Id: I723aaf79f8fbed4758bb4ee6727dfb6a8e35bf99
parent 57066148
Loading
Loading
Loading
Loading
+3 −6
Original line number Diff line number Diff line
@@ -13,16 +13,13 @@
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package android.text;
package android.view.textclassifier;

/**
 *  Java wrapper for LangId native library interface.
 *  This class is used to detect languages in text.
 *  @hide
 */
public final class LangId {
    // TODO: Move this to android.view.textclassifier and make it package-private.
    // We'll have to update the native library code to do this.
final class LangId {

    static {
        System.loadLibrary("smart-selection_jni");
@@ -33,7 +30,7 @@ public final class LangId {
    /**
     * Creates a new instance of LangId predictor, using the provided model image.
     */
    public LangId(int fd) {
    LangId(int fd) {
        mModelPtr = nativeNew(fd);
    }

+3 −6
Original line number Diff line number Diff line
@@ -14,16 +14,13 @@
 * limitations under the License.
 */

package android.text;
package android.view.textclassifier;

/**
 *  Java wrapper for SmartSelection native library interface.
 *  This library is used for detecting entities in text.
 *  @hide
 */
public final class SmartSelection {
    // TODO: Move this to android.view.textclassifier and make it package-private.
    // We'll have to update the native library code to do this.
final class SmartSelection {

    static {
        System.loadLibrary("smart-selection_jni");
@@ -35,7 +32,7 @@ public final class SmartSelection {
     * Creates a new instance of SmartSelect predictor, using the provided model image,
     * given as a file descriptor.
     */
    public SmartSelection(int fd) {
    SmartSelection(int fd) {
        mCtx = nativeNew(fd);
    }

+0 −1
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@ package android.view.textclassifier;
import android.annotation.NonNull;
import android.content.Context;
import android.os.ParcelFileDescriptor;
import android.text.LangId;
import android.util.Log;

import com.android.internal.util.Preconditions;
+0 −1
Original line number Diff line number Diff line
@@ -27,7 +27,6 @@ import android.graphics.drawable.Drawable;
import android.icu.text.BreakIterator;
import android.net.Uri;
import android.os.ParcelFileDescriptor;
import android.text.SmartSelection;
import android.text.Spannable;
import android.text.TextUtils;
import android.text.method.WordIterator;