cards
Cards SDK for Android
The Cards SDK is a solution to ease the integration with the Alviere services.
Features
Card Issuance
Create Card
List Cards
Get Card
Get Card Image
Get Card Sensitive Data
Update Card
Cancel Card
Activate Card
Freeze Card
Unfreeze Card
Incentives
List Incentive Rules
Get Incentive Rule
Digital Wallet
Add card to digital wallet
Requirements
Android Studio 4.0 or above
Android 5.0 (API level 21) or above
Java 11+
Maven Central Integration
Add Maven Central to project repositories
repositories {
...
mavenCentral()
}
Add Sdk dependency to module's build.gradle file using the latest version.
dependencies {
...
implementation 'com.alviere.android:cards:0.9.17'
}
Manual Integration
Get the latest versions of
cards.aar
andalcore.aar
, and open up the project structure by right-clicking on your project and choosing Open Module Settings or choosing File Project Structure…. Click the + button in the top left to add a new module.
Choose Import .JAR/.AAR Package and click the Next button.
Find your cards.aar file using the folder button beside the File name field. Android Studio will automatically create a subproject name. Just click Finish and repeat the process for the alcore.aar file.
Gradle will sync, which may take a few minutes. You should have the following implementation statements on your module's build.gradle file. Please note that sometimes Android Studio generates these statements on the project's build.gradle file. In that case, move them to the module's one.
...
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
...
implementation project(path: ':alcore')
implementation project(path: ':cards')
}
Make sure you have enabled Java 11 language feature support. To do so, guarantee that the following configurations are on the module's build.gradle file.
...
android {
...
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
kotlinOptions {
jvmTarget = JavaVersion.VERSION_11.toString()
}
}
Now that you have added the .aar modules, you need to add its dependencies as shown below. Once complete, sync gradle again.
apply plugin: 'com.android.application'
apply plugin: 'kotlin-kapt'
...
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
...
implementation project(path: ':alcore')
implementation project(path: ':cards')
...
}
Usage
Before you can use the Cards Sdk and if you want to call the card issuance and management services you need to first start the CardsSdk
. Keep in mind that the process of starting the Sdk it will be run in the UI thread and cannot be run in the IO thread.
CardsSdk.init()
On your android application class, setup Alviere Initialization.
class AndroidApplication : Application() {
override fun onCreate() {
super.onCreate()
Alviere.init(this, EnvironmentOption.PRD)
}
}
Kotlin Coroutines
Optionally for every Sdk callback entry function without UI, there is an alternative suspend function with the same name without callback. Internal code will run with withContext(Dispatchers.IO)
and will return an object of type Response<T>
val response = ...
when (response) {
is Response.Success -> { response.data }
is Response.Error -> { response.metadata }
}
Card Issuance
This section describes how to issue and manage cards with the Alviere platform.
Declare the callback
These callbacks are the main communication back channel to your application. For each action there is one method associated as follows. In addition to these methods, there is also an event method for handling events. Callbacks will always run on main thread.
private val createCardSdkCallback = object : CreateCardSdkCallback {
override fun onSuccess(issuedCardDetails: IssuedCardDetailsModel) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val listCardsSdkCallback = object : ListCardsSdkCallback {
override fun onSuccess(issuedCards: List<IssuedCardDetailsModel>) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val getCardSdkCallback = object : GetCardSdkCallback {
override fun onSuccess(issuedCardDetails: IssuedCardDetailsModel) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val getCardImageSdkCallback = object : GetCardImageSdkCallback {
override fun onSuccess(issuedCardImage: Bitmap) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val getCardSensitiveDataSdkCallback = object : GetCardSensitiveDataSdkCallback {
override fun onSuccess(issuedCardSensitiveData: CardSensitiveDataModel) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val updateCardSdkCallback = object : UpdateCardSdkCallback {
override fun onSuccess(issuedCardDetails: IssuedCardDetailsModel) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val cancelCardSdkCallback = object : CancelCardSdkCallback {
override fun onSuccess() { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val activateCardSdkCallback = object : ActivateCardSdkCallback {
override fun onSuccess() { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val freezeCardSdkCallback = object : FreezeCardSdkCallback {
override fun onSuccess() { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val unfreezeCardSdkCallback = object : UnfreezeCardSdkCallback {
override fun onSuccess() { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
onSuccess
This callback method is called when a request was successfully executed. Use this to issue and manage cards of a user's wallet with the Alviere API.
onEvent
This callback method is called when the user exited from the Cards SDK, when an error occurred, or when certain events in the Cards SDK flow have occurred. This allows your application to get more information about what is going on as the user goes through the Cards SDK flow. In case of an error, you may want to display information related to the error to the user and have them try doing the action again.
Create Card
To create a new issued card, use the Cards Sdk service method CardsSdk.createCard
. Pass the session_token
, the wallet_uuid
, the IssueCardRequest
model and the CreateCardSdkCallback
.
val model = IssueCardRequest(...)
CardsSdk.createCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
data = model,
clientCallback = createCardSdkCallback
)
The result of this action will return the newly created IssuedCardDetailsModel
on onSuccess(issuedCardDetails: IssuedCardDetailsModel)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
List Cards
To get a list of cards from a wallet, use the Cards Sdk service method CardsSdk.listCards
. Pass the session_token
, the wallet_uuid
, the ListCardsSdkCallback
and the limit
/offset
, optionally.
CardsSdk.listCards(
sessionToken = session_token,
walletUuid = wallet_uuid,
clientCallback = listCardsSdkCallback
)
The result of this action will return the user's wallet cards List<IssuedCardDetailsModel>
on onSuccess(issuedCards: List<IssuedCardDetailsModel>)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Get Card
To get a card, use the Cards Sdk service method CardsSdk.getCard
. Pass the session_token
, the wallet_uuid
, the card_uuid
and the GetCardSdkCallback
.
CardsSdk.getCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
clientCallback = getCardSdkCallback
)
The result of this action will return the issued card of a wallet IssuedCardDetailsModel
on onSuccess(issuedCardDetails: IssuedCardDetailsModel)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Get Card Image
To get a card image, use the Cards Sdk service method CardsSdk.getCardImage
. Pass the session_token
, the wallet_uuid
, the card_uuid
and the GetCardImageSdkCallback
.
CardsSdk.getCardImage(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
clientCallback = getCardImageSdkCallback
)
The result of this action will return the issued card image Android Bitmap
on onSuccess(issuedCardImage: Bitmap)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Get Card Sensitive Data
To get a card sensitive data, use the Cards Sdk service method CardsSdk.getCardSensitiveData
. Pass the session_token
, the wallet_uuid
, the card_uuid
and the GetCardSensitiveDataSdkCallback
.
CardsSdk.getCardSensitiveData(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
clientCallback = getCardSensitiveDataSdkCallback
)
The result of this action will return the issued card sensitive data IssuedCardSensitiveDataModel
on onSuccess(issuedCardSensitiveData: CardSensitiveDataModel)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Update Card
To update a card, use the Cards Sdk service method CardsSdk.updateCard
. Pass the session_token
, the wallet_uuid
, the card_uuid
, the CardUpdateRequest
model and the UpdateCardSdkCallback
.
val model = CardUpdateRequest(...)
CardsSdk.updateCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
data = model,
clientCallback = updateCardSdkCallback
)
The result of this action will return the updated card IssuedCardDetailsModel
on onSuccess(issuedCardDetails: IssuedCardDetailsModel)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Cancel Card
To cancel a card, use the Cards Sdk service method CardsSdk.cancelCard
. Pass the session_token
, the wallet_uuid
, the card_uuid
and the CancelCardSdkCallback
.
CardsSdk.cancelCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
clientCallback = cancelCardSdkCallback
)
The result of this action will return on onSuccess()
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Activate Card
To activate a card, use the Cards Sdk service method CardsSdk.activateCard
. Pass the session_token
, the wallet_uuid
, the card_uuid
, the ActivateCardRequest
model and the ActivateCardSdkCallback
.
val model = ActivateCardRequest(...)
CardsSdk.activateCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
data = model,
clientCallback = activateCardSdkCallback
)
The result of this action will return on onSuccess()
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Freeze Card
To freeze a card, use the Cards Sdk service method CardsSdk.freezeCard
. Pass the session_token
, the wallet_uuid
, the card_uuid
and the FreezeCardSdkCallback
.
CardsSdk.freezeCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
clientCallback = freezeCardSdkCallback
)
The result of this action will return on onSuccess()
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Unfreeze Card
To unfreeze a card, use the Cards Sdk service method CardsSdk.unfreezeCard
. Pass the session_token
, the wallet_uuid
, the card_uuid
and the UnfreezeCardSdkCallback
.
CardsSdk.unfreezeCard(
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
clientCallback = unfreezeCardSdkCallback
)
The result of this action will return on onSuccess()
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Incentives
This section describes how to manage incentives with the Alviere platform.
Declare the callback
These callbacks are the main communication back channel to your application. For each action there is one method associated as follows. In addition to these methods, there is also an event method for handling events. Callbacks will always run on main thread.
private val listIncentiveRulesSdkCallback = object : ListIncentiveRulesSdkCallback {
override fun onSuccess(incentiveRules: List<IncentiveRuleDetailsModel>) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
private val getIncentiveRuleSdkCallback = object : GetIncentiveRuleSdkCallback {
override fun onSuccess(incentiveRuleDetails: IncentiveRuleDetailsModel) { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
onSuccess
This callback method is called when a request was successfully executed. Use this to manage incentives with the Alviere API.
onEvent
This callback method is called when the user exited from the Cards SDK, when an error occurred, or when certain events in the Cards SDK flow have occurred. This allows your application to get more information about what is going on as the user goes through the Cards SDK flow. In case of an error, you may want to display information related to the error to the user and have them try doing the action again.
List Incentive Rules
To get a list of incentive rules, use the Cards Sdk service method CardsSdk.listIncentiveRules
. Pass the session_token
, the ListIncentiveRulesSdkCallback
and the limit
/offset
/incentiveScope
/incentiveType
, optionally.
CardsSdk.listIncentiveRules(
sessionToken = session_token,
clientCallback = listIncentiveRulesSdkCallback
)
The result of this action will return the incentive rules List<IncentiveRuleDetailsModel>
on onSuccess(incentiveRules: List<IncentiveRuleDetailsModel>)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Get Incentive Rule
To get a incentive rule, use the Cards Sdk service method CardsSdk.getIncentiveRule
. Pass the session_token
, the rule_uuid
and the GetIncentiveRuleSdkCallback
.
CardsSdk.getIncentiveRule(
sessionToken = session_token,
ruleUuid = rule_uuid,
clientCallback = getIncentiveRuleSdkCallback
)
The result of this action will return the incentive rule IncentiveRuleDetailsModel
on onSuccess(incentiveRuleDetails: IncentiveRuleDetailsModel)
and any errors will be returned on onEvent(event: String, metadata: Map<String, String>?)
, both from the callback.
Digital Wallet
This section outlines the integration with Alviere to manage digital wallets of Google and Samsung.
Declare the callback
These callbacks are the main communication back channel to your application. For each action there is one method associated as follows. In addition to this methods, there is also an event method for handling events. Callbacks will always run on main thread.
private val addCardDigitalWalletSdkCallback = object : AddCardDigitalWalletSdkCallback {
override fun onSuccess() { /* handle success */ }
override fun onEvent(event: String, metadata: Map<String, String>?) { /* handle event */ }
}
onSuccess
This callback method is called when a card was successfully added to a digital wallet.
onEvent
This callback method is called when the user exited from the Cards SDK, when an error occurred, or when certain events in the Cards SDK flow have occurred. This allows your application to get more information about what is going on as the user goes through the Cards SDK flow. In case of an error, you may want to display information related to the error to the user and have them try doing the action again.
UI - Add card to digital wallet - SAMSUNG
The Add card to Samsung digital wallet is implemented through Activity or through the navigation controller. To get started, set the Cards Sdk event listener.
CardsSdk.setEventListener(addCardDigitalWalletSdkCallback)
Activity
To start using this feature on an activity, create an Intent
using CardsSdk.addCardDigitalWalletSamsungPayByIntent, pass the parent_activity
, the session_token
, the wallet_uuid
,the card_uuid
, the CardBrandModel
and the samsung_service_id
.
val intent = CardsSdk.addCardDigitalWalletSamsungPayByIntent(
parentActivity = parent_activity,
sessionToken = session_token,
walletUuid = wallet_uuid,
cardUuid = card_uuid,
cardBrand = CardBrandModel.MASTERCARD,
samsungServiceId = samsung_service_id
)
startActivity(intent)
Navigation Controller
To start using this feature on a navigation controller, add the destination CradsActivity
to your navigation graph and connect it. An action will be generated that will have to have the arguments embedded, as follows.
<fragment
android:id="@+id/digital_wallet_fragment"
android:name="com.example.app.DigitalWalletFragment">
<action
android:id="@+id/action_digital_wallet_fragment_to_add_card_digital_wallet_samsung_pay_by_activity"
app:destination="@id/add_card_digital_wallet_samsung_pay_by_activity" />
</fragment>
<activity
android:id="@+id/add_card_digital_wallet_samsung_pay_by_activity"
android:name="com.alviere.android.cards.activity.view.CardsActivity">
<argument
android:name="cards_extra_feature_frag"
app:argType="com.alviere.android.cards.CardsSdk$Features" />
<argument
android:name="cards_extra_session_token"
app:argType="string" />
<argument
android:name="cards_extra_wallet_uuid"
app:argType="string" />
<argument
android:name="cards_extra_card_uuid"
app:argType="string" />
<argument
android:name="cards_extra_card_brand"
app:argType="com.alviere.android.cards.sdk.model.common.CardBrandModel" />
<argument
android:name="cards_extra_samsung_service_id"
app:argType="string" />
</activity>
Using Safe Args a class is created for each destination where an action originates. The name of this class is the name of the originating destination, appended with the word "Directions". For example, if the originating destination is a fragment that is named DigitalWalletFragment
, the generated class would be called DigitalWalletFragmentDirections
. This class has a method for each action defined in the originating destination, such as actionDigitalWalletFragmentToAddCardDigitalWalletSamsungPayByActivity()
that returns a NavDirections object. This returned NavDirections object can then be passed directly to navigate(), as shown in the following example:
view.findNavController().navigate(
DigitalWalletFragmentDirections.actionDigitalWalletFragmentToAddCardDigitalWalletSamsungPayByActivity(
cardsExtraFeatureFrag = CardsSdk.Features.ADD_CARD_DIGITAL_WALLET_SAMSUNG,
cardsExtraSessionToken = session_token,
cardsExtraWalletUuid = wallet_uuid,
cardsExtraCardUuid = card_uuid,
cardsExtraCardBrand = CardBrandModel.MASTERCARD,
cardsExtraSamsungServiceId = samsiung_service_id
)
)
Customize view components
In addition to all Cards Sdk functionalities, the Alviere Sdks also provides the ability to customize view components.
Custom view components can be configured in two ways. The easiest (and recommended) method is by overriding colors.xml_, strings.xml and dimens.xml resources, setting the key and value according to the following table. Alternatively, you can create customization object.
Override resources
To start using the customization by resources just override the keys that you want to customize.
Themes
The Cards Sdk for Android allows you to customize the main UI Theme used by activities. To do so, you will need to override the theme key that you want to change on your themes.xml file from values and values-night folder. Some UI elements use specific colors that need to be override apart in values and values-night.
<style name="CardsSdkTheme" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
<item name="colorPrimary">@color/alviere_sdk_cards_color_primary</item>
<item name="colorPrimaryVariant">@color/alviere_sdk_cards_color_primary_variant</item>
<item name="colorOnPrimary">@color/alviere_sdk_cards_color_on_primary</item>
<item name="colorSecondary">@color/alviere_sdk_cards_color_secondary</item>
<item name="colorSecondaryVariant">@color/alviere_sdk_cards_color_secondary_variant</item>
<item name="colorOnSecondary">@color/alviere_sdk_cards_color_on_secondary</item>
<item name="android:statusBarColor">@color/alviere_sdk_cards_color_status_bar</item>
<item name="android:navigationBarColor">@color/alviere_sdk_cards_color_navigation_bar</item>
<item name="android:windowBackground">@color/alviere_sdk_cards_color_background</item>
<item name="android:fontFamily">@string/alviere_sdk_cards_font</item>
<item name="android:windowLightNavigationBar" tools:targetApi="o_mr1">true</item>
</style>
<style name="CardsSdkTheme.NoActionBar">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
</style>
Fonts
The Cards Sdk for Android allows you to customize the UI font. To do so, you will need to override the font key that you want to change on your strings.xml file. The next section details a list of the current available keys.
.-----------------------------------------------------------------.--------------------------------.
| Key | CardsCustomize Support |
:-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_font | No |
'-----------------------------------------------------------------+--------------------------------'
Colors
The Cards SDK for Android allows you to customize the UI colors. To do so, you will need to override the color key that you want to change on your colors.xml file from values and values-night folders. The next section details a list of the current available keys.
.-----------------------------------------------------------------.--------------------------------.
| Key | CardsCustomize Support |
:-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_color_primary | No |
'-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_color_primary_variant | No |
'-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_color_on_primary | No |
'-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_color_secondary | No |
'-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_color_secondary_variant | No |
'-----------------------------------------------------------------'--------------------------------'
| alviere_sdk_cards_color_on_secondary | No |
'-----------------------------------------------------------------'--------------------------------'
| alviere_sdk_cards_color_status_bar | No |
'-----------------------------------------------------------------'--------------------------------'
| alviere_sdk_cards_color_navigation_bar | No |
'-----------------------------------------------------------------'--------------------------------'
| alviere_sdk_cards_color_background | No |
'-----------------------------------------------------------------'--------------------------------'
.-----------------------------------------------------------------:--------------------------------.
| alviere_sdk_cards_digital_wallet_background | Yes |
:-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_digital_wallet_text_color | Yes (alviereTextView) |
'-----------------------------------------------------------------'--------------------------------'
.-----------------------------------------------------------------.--------------------------------.
| alviere_sdk_cards_loading_bar | Yes |
'-----------------------------------------------------------------'--------------------------------'
.-----------------------------------------------------------------.--------------------------------.
| alviere_sdk_cards_toolbar_background | Yes |
:-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_toolbar_title_text_color | No |
:-----------------------------------------------------------------+--------------------------------:
| alviere_sdk_cards_toolbar_buttons_color | No |
'-----------------------------------------------------------------'--------------------------------'
Text and Localization
The Cards Sdk for Android allows you to customize the UI text. To do so, you will need to override the string key that you want to change on your strings.xml file. The next section details a list of the current available keys. Currently, the SDK only supports english.
.-------------------------------------------------------------------.------------------------------------------------.--------------------------.
| Key | English Value | CardsCustomize Support |
:-------------------------------------------------------------------+------------------------------------------------+--------------------------:
| alviere_sdk_cards_digital_wallet_samsung_add_card_title | Add Card | Yes |
:-------------------------------------------------------------------+------------------------------------------------+--------------------------:
| alviere_sdk_cards_digital_wallet_samsung_add_card_message | Adding card to wallet. | Yes |
:-------------------------------------------------------------------+------------------------------------------------+--------------------------:
| alviere_sdk_cards_digital_wallet_samsung_not_supported_message | Samsung wallet not installed or not supported.| Yes |
:-------------------------------------------------------------------+------------------------------------------------+--------------------------'
Dimensions
The Cards Sdk for Android allows you to customize the UI dimensions. To do so, you will need to override the dimension key that you want to change on your dimens.xml file. The next section details a list of the current available keys.
.-------------------------------------------------------------------.------------------------------.
| Key | CardsCustomize Support |
:-------------------------------------------------------------------+------------------------------:
| alviere_sdk_cards_digital_wallet_text_size | Yes |
:-------------------------------------------------------------------+------------------------------'
Customization object
To start using the CardsCustomize
create the custom object and set it by CardsSdk.setCustomize. This will override only the values that you want to customize.
First we have customization objects by features, as follows:
.---------------------------.----------------------------.------------------------------------------.
| Class | Attribute | Description |
:---------------------------+----------------------------+------------------------------------------:
| CardsCustomize | digitalWalletCustomize | Add card to digital wallet customization|
'---------------------------'----------------------------'------------------------------------------'
Then we have all the view components for each of these features. As follows:
.---------------------------.----------------------------.-----------------------------------------.
| Class | Attribute | Description |
:---------------------------+----------------------------+-----------------------------------------:
| ToolbarCustomize | backgroundColorRes | Background color resource |
| :----------------------------+-----------------------------------------:
| | showBackButton | Back button visibility |
| :----------------------------+-----------------------------------------:
| | showCloseButton | Close button visibility |
'---------------------------'----------------------------'-----------------------------------------'
.---------------------------.----------------------------.-----------------------------------------.
| Class | Attribute | Description |
:---------------------------+----------------------------+-----------------------------------------:
| AlviereTextViewCustomize | textColorRes | text color resource |
| :----------------------------+-----------------------------------------:
| | textSizeRes | Text size resource |
| :----------------------------+-----------------------------------------:
| | textColor | Text color |
| :----------------------------+-----------------------------------------:
| | textSize | Text size |
'---------------------------'----------------------------'-----------------------------------------'