Loading api/current.txt +7 −7 Original line number Diff line number Diff line Loading @@ -37082,6 +37082,13 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.LuhnChecksumValidator> CREATOR; } public final class RegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public RegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.RegexValidator> CREATOR; } public final class SaveCallback { method public void onFailure(java.lang.CharSequence); method public void onSuccess(); Loading Loading @@ -37122,13 +37129,6 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.SaveRequest> CREATOR; } public final class SimpleRegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public SimpleRegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.SimpleRegexValidator> CREATOR; } public abstract interface Transformation { } api/system-current.txt +7 −7 Original line number Diff line number Diff line Loading @@ -40272,6 +40272,13 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.LuhnChecksumValidator> CREATOR; } public final class RegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public RegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.RegexValidator> CREATOR; } public final class SaveCallback { method public void onFailure(java.lang.CharSequence); method public void onSuccess(); Loading Loading @@ -40312,13 +40319,6 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.SaveRequest> CREATOR; } public final class SimpleRegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public SimpleRegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.SimpleRegexValidator> CREATOR; } public abstract interface Transformation { } api/test-current.txt +8 −8 Original line number Diff line number Diff line Loading @@ -37274,6 +37274,14 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.LuhnChecksumValidator> CREATOR; } public final class RegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public RegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public boolean isValid(android.service.autofill.ValueFinder); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.RegexValidator> CREATOR; } public final class SaveCallback { method public void onFailure(java.lang.CharSequence); method public void onSuccess(); Loading Loading @@ -37314,14 +37322,6 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.SaveRequest> CREATOR; } public final class SimpleRegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public SimpleRegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public boolean isValid(android.service.autofill.ValueFinder); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.SimpleRegexValidator> CREATOR; } public abstract interface Transformation { } core/java/android/service/autofill/CustomDescription.java +7 −7 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ import com.android.internal.util.Preconditions; * * <p>This is useful when the autofill service needs to show a detailed view of what would be saved; * for example, when the screen contains a credit card, it could display a logo of the credit card * bank, the last for digits of the credit card number, and its expiration number. * bank, the last four digits of the credit card number, and its expiration number. * * <p>A custom description is made of 2 parts: * <ul> Loading Loading @@ -63,16 +63,16 @@ import com.android.internal.util.Preconditions; * // Image child - different logo for each bank, based on credit card prefix * builder.addChild(R.id.templateccLogo, * new ImageTransformation.Builder(ccNumberId) * .addOption("^4815.*$", R.drawable.ic_credit_card_logo1) * .addOption("^1623.*$", R.drawable.ic_credit_card_logo2) * .addOption("^42.*$", R.drawable.ic_credit_card_logo3); * .addOption(Pattern.compile(""^4815.*$"), R.drawable.ic_credit_card_logo1) * .addOption(Pattern.compile(""^1623.*$"), R.drawable.ic_credit_card_logo2) * .addOption(Pattern.compile(""^42.*$"), R.drawable.ic_credit_card_logo3); * // Masked credit card number (as .....LAST_4_DIGITS) * builder.addChild(R.id.templateCcNumber, new CharSequenceTransformation.Builder() * .addField(ccNumberId, "^.*(\\d\\d\\d\\d)$", "...$1") * .addField(ccNumberId, Pattern.compile(""^.*(\\d\\d\\d\\d)$"), "...$1") * // Expiration date as MM / YYYY: * builder.addChild(R.id.templateExpDate, new CharSequenceTransformation.Builder() * .addField(ccExpMonthId, "^(\\d\\d)$", "Exp: $1") * .addField(ccExpYearId, "^(\\d\\d)$", "/$1"); * .addField(ccExpMonthId, Pattern.compile(""^(\\d\\d)$"), "Exp: $1") * .addField(ccExpYearId, Pattern.compile(""^(\\d\\d)$"), "/$1"); * </pre> * * <p>See {@link ImageTransformation}, {@link CharSequenceTransformation} for more info about these Loading core/java/android/service/autofill/SimpleRegexValidator.java→core/java/android/service/autofill/RegexValidator.java +10 −10 Original line number Diff line number Diff line Loading @@ -34,9 +34,9 @@ import java.util.regex.Pattern; * * <p>See {@link SaveInfo.Builder#setValidator(Validator)} for examples. */ public final class SimpleRegexValidator extends InternalValidator implements Validator, Parcelable { public final class RegexValidator extends InternalValidator implements Validator, Parcelable { private static final String TAG = "SimpleRegexValidator"; private static final String TAG = "RegexValidator"; private final AutofillId mId; private final Pattern mRegex; Loading @@ -49,7 +49,7 @@ public final class SimpleRegexValidator extends InternalValidator implements Val * matches the contents of the field identified by {@code id}, it returns {@code true}; * otherwise, it returns {@code false}. */ public SimpleRegexValidator(@NonNull AutofillId id, @NonNull Pattern regex) { public RegexValidator(@NonNull AutofillId id, @NonNull Pattern regex) { mId = Preconditions.checkNotNull(id); mRegex = Preconditions.checkNotNull(regex); } Loading @@ -76,7 +76,7 @@ public final class SimpleRegexValidator extends InternalValidator implements Val public String toString() { if (!sDebug) return super.toString(); return "SimpleRegexValidator: [id=" + mId + ", regex=" + mRegex + "]"; return "RegexValidator: [id=" + mId + ", regex=" + mRegex + "]"; } ///////////////////////////////////// Loading @@ -93,17 +93,17 @@ public final class SimpleRegexValidator extends InternalValidator implements Val parcel.writeSerializable(mRegex); } public static final Parcelable.Creator<SimpleRegexValidator> CREATOR = new Parcelable.Creator<SimpleRegexValidator>() { public static final Parcelable.Creator<RegexValidator> CREATOR = new Parcelable.Creator<RegexValidator>() { @Override public SimpleRegexValidator createFromParcel(Parcel parcel) { return new SimpleRegexValidator(parcel.readParcelable(null), public RegexValidator createFromParcel(Parcel parcel) { return new RegexValidator(parcel.readParcelable(null), (Pattern) parcel.readSerializable()); } @Override public SimpleRegexValidator[] newArray(int size) { return new SimpleRegexValidator[size]; public RegexValidator[] newArray(int size) { return new RegexValidator[size]; } }; } Loading
api/current.txt +7 −7 Original line number Diff line number Diff line Loading @@ -37082,6 +37082,13 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.LuhnChecksumValidator> CREATOR; } public final class RegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public RegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.RegexValidator> CREATOR; } public final class SaveCallback { method public void onFailure(java.lang.CharSequence); method public void onSuccess(); Loading Loading @@ -37122,13 +37129,6 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.SaveRequest> CREATOR; } public final class SimpleRegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public SimpleRegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.SimpleRegexValidator> CREATOR; } public abstract interface Transformation { }
api/system-current.txt +7 −7 Original line number Diff line number Diff line Loading @@ -40272,6 +40272,13 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.LuhnChecksumValidator> CREATOR; } public final class RegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public RegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.RegexValidator> CREATOR; } public final class SaveCallback { method public void onFailure(java.lang.CharSequence); method public void onSuccess(); Loading Loading @@ -40312,13 +40319,6 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.SaveRequest> CREATOR; } public final class SimpleRegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public SimpleRegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.SimpleRegexValidator> CREATOR; } public abstract interface Transformation { }
api/test-current.txt +8 −8 Original line number Diff line number Diff line Loading @@ -37274,6 +37274,14 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.LuhnChecksumValidator> CREATOR; } public final class RegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public RegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public boolean isValid(android.service.autofill.ValueFinder); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.RegexValidator> CREATOR; } public final class SaveCallback { method public void onFailure(java.lang.CharSequence); method public void onSuccess(); Loading Loading @@ -37314,14 +37322,6 @@ package android.service.autofill { field public static final android.os.Parcelable.Creator<android.service.autofill.SaveRequest> CREATOR; } public final class SimpleRegexValidator implements android.os.Parcelable android.service.autofill.Validator { ctor public SimpleRegexValidator(android.view.autofill.AutofillId, java.util.regex.Pattern); method public int describeContents(); method public boolean isValid(android.service.autofill.ValueFinder); method public void writeToParcel(android.os.Parcel, int); field public static final android.os.Parcelable.Creator<android.service.autofill.SimpleRegexValidator> CREATOR; } public abstract interface Transformation { }
core/java/android/service/autofill/CustomDescription.java +7 −7 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ import com.android.internal.util.Preconditions; * * <p>This is useful when the autofill service needs to show a detailed view of what would be saved; * for example, when the screen contains a credit card, it could display a logo of the credit card * bank, the last for digits of the credit card number, and its expiration number. * bank, the last four digits of the credit card number, and its expiration number. * * <p>A custom description is made of 2 parts: * <ul> Loading Loading @@ -63,16 +63,16 @@ import com.android.internal.util.Preconditions; * // Image child - different logo for each bank, based on credit card prefix * builder.addChild(R.id.templateccLogo, * new ImageTransformation.Builder(ccNumberId) * .addOption("^4815.*$", R.drawable.ic_credit_card_logo1) * .addOption("^1623.*$", R.drawable.ic_credit_card_logo2) * .addOption("^42.*$", R.drawable.ic_credit_card_logo3); * .addOption(Pattern.compile(""^4815.*$"), R.drawable.ic_credit_card_logo1) * .addOption(Pattern.compile(""^1623.*$"), R.drawable.ic_credit_card_logo2) * .addOption(Pattern.compile(""^42.*$"), R.drawable.ic_credit_card_logo3); * // Masked credit card number (as .....LAST_4_DIGITS) * builder.addChild(R.id.templateCcNumber, new CharSequenceTransformation.Builder() * .addField(ccNumberId, "^.*(\\d\\d\\d\\d)$", "...$1") * .addField(ccNumberId, Pattern.compile(""^.*(\\d\\d\\d\\d)$"), "...$1") * // Expiration date as MM / YYYY: * builder.addChild(R.id.templateExpDate, new CharSequenceTransformation.Builder() * .addField(ccExpMonthId, "^(\\d\\d)$", "Exp: $1") * .addField(ccExpYearId, "^(\\d\\d)$", "/$1"); * .addField(ccExpMonthId, Pattern.compile(""^(\\d\\d)$"), "Exp: $1") * .addField(ccExpYearId, Pattern.compile(""^(\\d\\d)$"), "/$1"); * </pre> * * <p>See {@link ImageTransformation}, {@link CharSequenceTransformation} for more info about these Loading
core/java/android/service/autofill/SimpleRegexValidator.java→core/java/android/service/autofill/RegexValidator.java +10 −10 Original line number Diff line number Diff line Loading @@ -34,9 +34,9 @@ import java.util.regex.Pattern; * * <p>See {@link SaveInfo.Builder#setValidator(Validator)} for examples. */ public final class SimpleRegexValidator extends InternalValidator implements Validator, Parcelable { public final class RegexValidator extends InternalValidator implements Validator, Parcelable { private static final String TAG = "SimpleRegexValidator"; private static final String TAG = "RegexValidator"; private final AutofillId mId; private final Pattern mRegex; Loading @@ -49,7 +49,7 @@ public final class SimpleRegexValidator extends InternalValidator implements Val * matches the contents of the field identified by {@code id}, it returns {@code true}; * otherwise, it returns {@code false}. */ public SimpleRegexValidator(@NonNull AutofillId id, @NonNull Pattern regex) { public RegexValidator(@NonNull AutofillId id, @NonNull Pattern regex) { mId = Preconditions.checkNotNull(id); mRegex = Preconditions.checkNotNull(regex); } Loading @@ -76,7 +76,7 @@ public final class SimpleRegexValidator extends InternalValidator implements Val public String toString() { if (!sDebug) return super.toString(); return "SimpleRegexValidator: [id=" + mId + ", regex=" + mRegex + "]"; return "RegexValidator: [id=" + mId + ", regex=" + mRegex + "]"; } ///////////////////////////////////// Loading @@ -93,17 +93,17 @@ public final class SimpleRegexValidator extends InternalValidator implements Val parcel.writeSerializable(mRegex); } public static final Parcelable.Creator<SimpleRegexValidator> CREATOR = new Parcelable.Creator<SimpleRegexValidator>() { public static final Parcelable.Creator<RegexValidator> CREATOR = new Parcelable.Creator<RegexValidator>() { @Override public SimpleRegexValidator createFromParcel(Parcel parcel) { return new SimpleRegexValidator(parcel.readParcelable(null), public RegexValidator createFromParcel(Parcel parcel) { return new RegexValidator(parcel.readParcelable(null), (Pattern) parcel.readSerializable()); } @Override public SimpleRegexValidator[] newArray(int size) { return new SimpleRegexValidator[size]; public RegexValidator[] newArray(int size) { return new RegexValidator[size]; } }; }