@Test public void getCardNumber_whenValidNumberIsChangedToInvalid_returnsNull() { mCardNumberEditText.setText(VALID_AMEX_WITH_SPACES); ViewTestUtils.sendDeleteKeyEvent(mCardNumberEditText); assertNull(mCardNumberEditText.getCardNumber()); }
@Nullable public String getCardNumber() { return mIsCardNumberValid ? StripeTextUtils.removeSpacesAndHyphens(getText().toString()) : null; }
CardNumberEditText extends StripeEditText { @Nullable public String getCardNumber() { return mIsCardNumberValid ? StripeTextUtils.removeSpacesAndHyphens(getText().toString()) : null; } }
CardNumberEditText extends StripeEditText { @Nullable public String getCardNumber() { return mIsCardNumberValid ? StripeTextUtils.removeSpacesAndHyphens(getText().toString()) : null; } CardNumberEditText(Context context);  CardNumberEditText(Context context, AttributeSet attrs);  CardNumberEditText(Context context, AttributeSet attrs, int defStyleAttr); }
CardNumberEditText extends StripeEditText { @Nullable public String getCardNumber() { return mIsCardNumberValid ? StripeTextUtils.removeSpacesAndHyphens(getText().toString()) : null; } CardNumberEditText(Context context);  CardNumberEditText(Context context, AttributeSet attrs);  CardNumberEditText(Context context, AttributeSet attrs, int defStyleAttr); @NonNull @Card.CardBrand String getCardBrand(); @Nullable String getCardNumber(); int getLengthMax(); boolean isCardNumberValid(); }
CardNumberEditText extends StripeEditText { @Nullable public String getCardNumber() { return mIsCardNumberValid ? StripeTextUtils.removeSpacesAndHyphens(getText().toString()) : null; } CardNumberEditText(Context context);  CardNumberEditText(Context context, AttributeSet attrs);  CardNumberEditText(Context context, AttributeSet attrs, int defStyleAttr); @NonNull @Card.CardBrand String getCardBrand(); @Nullable String getCardNumber(); int getLengthMax(); boolean isCardNumberValid();  }