Commit fb4256b3 authored by Gandha Ryanto's avatar Gandha Ryanto

Initial Project

parents
File added
# Built application files
*.apk
*.ap_
# Files for the ART/Dalvik VM
*.dex
# Java class files
*.class
# Generated files
bin/
gen/
out/
# Gradle files
.gradle/
build/
# Local configuration file (sdk path, etc)
local.properties
# Proguard folder generated by Eclipse
proguard/
# Log Files
*.log
# Android Studio Navigation editor temp files
.navigation/
# Android Studio captures folder
captures/
# IntelliJ
*.iml
.idea/workspace.xml
.idea/tasks.xml
.idea/gradle.xml
.idea/assetWizardSettings.xml
.idea/dictionaries
.idea/libraries
.idea/caches
# Keystore files
# Uncomment the following line if you do not want to check your keystore files in.
#*.jks
# External native build folder generated in Android Studio 2.2 and later
.externalNativeBuild
# Google Services (e.g. APIs or Firebase)
google-services.json
# Freeline
freeline.py
freeline/
freeline_project_description.json
# fastlane
fastlane/report.xml
fastlane/Preview.html
fastlane/screenshots
fastlane/test_output
fastlane/readme.md
.idea/
configurations.maybeCreate("default")
artifacts.add("default", file('aar-deviceid-release.aar'))
\ No newline at end of file
File added
apply plugin: 'com.android.application'
android {
compileSdkVersion 29
defaultConfig {
//applicationId "co.id.mdd.isiin"
applicationId "com.mdd.updateaja"
minSdkVersion 22
targetSdkVersion 29
versionCode 1
versionName "1.0.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:29.0.0'
implementation 'com.android.support.constraint:constraint-layout:2.0.4'
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
implementation "androidx.preference:preference:1.1.1"
implementation 'com.google.android.material:material:1.2.1'
testImplementation 'junit:junit:4.13.1'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation fileTree(include: ['*.aar'], dir: 'libs')
implementation 'com.squareup.okhttp3:okhttp:4.1.1'
implementation 'com.squareup.retrofit2:adapter-rxjava2:2.4.0'
//retrofit
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
implementation 'com.squareup.okhttp3:logging-interceptor:4.1.1'
implementation 'com.squareup.retrofit2:converter-scalars:2.3.0'
implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
implementation 'io.reactivex.rxjava2:rxjava:2.2.19'
// sweetAlert
implementation 'com.github.f0ris.sweetalert:library:1.6.2'
implementation 'com.jakewharton:butterknife:10.2.0'
implementation 'com.bugfender.sdk:android:3.0.8'
annotationProcessor 'com.jakewharton:butterknife-compiler:10.1.0'
implementation(group: 'com.mdd.payment', name: 'aar-deviceid-release', version: '2.0.7', ext: 'aar')
implementation(group: 'com.mdd.service', name: 'partner-connect', version: '2.4.2', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'mybanklibrary-release', version: '3.7.1', ext: 'aar')
implementation(group: 'com.mdd.topup', name: 'update-balance', version: '3.2.7-mobile-rev1', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'z91library-release', version: '2.1.2', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'organicdrv-release', version: '2.1.2', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'wepoylibrary-release', version: '2.2.6', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'paxlibrary-release', version: '2.1.4', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'nativecripto-release', version: '2.0.1', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'isodeplibrary-release', version: '2.1.2', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'brizzilib-release', version: '1.1.2', ext: 'aar')
implementation(group: 'com.mdd.library', name: 'brizzi-release-sbox', version: '1.3', ext: 'aar')
implementation 'io.sentry:sentry-android:3.1.0'
// implementation project(path: ':unik-update-balance-lib-release')
}
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}
# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable
# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile
{
"version": 1,
"artifactType": {
"type": "APK",
"kind": "Directory"
},
"applicationId": "com.mdd.isiinaja",
"variantName": "release",
"elements": [
{
"type": "SINGLE",
"filters": [],
"properties": [],
"versionCode": 1,
"versionName": "1.0.0",
"enabled": true,
"outputFile": "app-release.apk"
}
]
}
\ No newline at end of file
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":6,"versionName":"1.1.4","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}]
\ No newline at end of file
package id.mcash.emoney;
import android.content.Context;
import android.support.test.InstrumentationRegistry;
import android.support.test.runner.AndroidJUnit4;
import org.junit.Test;
import org.junit.runner.RunWith;
import static org.junit.Assert.*;
/**
* Instrumented test, which will execute on an Android device.
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
@RunWith(AndroidJUnit4.class)
public class ExampleInstrumentedTest {
@Test
public void useAppContext() {
// Context of the app under test.
Context appContext = InstrumentationRegistry.getTargetContext();
assertEquals("id.mcash.emoney", appContext.getPackageName());
}
}
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.mdd.updateaja">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.NFC" />
<uses-feature android:name="android.hardware.nfc" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<application
android:name="com.mdd.updateaja.MyApp"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:networkSecurityConfig="@xml/network_security_config"
android:roundIcon="@mipmap/ic_launcher"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<meta-data
android:name="io.sentry.dsn"
android:value="https://4b0126109eeb42deb732f2a4bac79bfa@o420266.ingest.sentry.io/5515708" />
<activity
android:name="com.mdd.updateaja.MainActivity"
android:screenOrientation="portrait">
<meta-data
android:name="android.nfc.action.TECH_DISCOVERED"
android:resource="@xml/nfc_tech_filter" />
</activity>
<activity
android:name="com.mdd.updateaja.SplashscreenActivity"
android:screenOrientation="portrait"
android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<action android:name="android.nfc.action.TECH_DISCOVERED" />
</intent-filter>
</activity>
<meta-data
android:name="preloaded_fonts"
android:resource="@array/preloaded_fonts" />
</application>
</manifest>
\ No newline at end of file
package com.mdd.updateaja;
import com.mdd.topupUnik.ubal.InitReader;
/**
* Created by Husnan on 14/05/2020
*/
public interface InitListener {
void onInitReaderComplete(InitReader reader);
}
package com.mdd.updateaja;
import android.Manifest;
import android.app.PendingIntent;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.content.pm.PackageManager;
import android.media.MediaPlayer;
import android.nfc.NfcAdapter;
import android.nfc.NfcManager;
import android.nfc.Tag;
import android.os.AsyncTask;
import android.os.Build;
import android.os.Bundle;
import android.os.StrictMode;
import android.speech.tts.TextToSpeech;
import android.util.Log;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import android.widget.Toast;
import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatActivity;
import androidx.core.app.ActivityCompat;
import androidx.core.content.ContextCompat;
import com.google.android.material.card.MaterialCardView;
import com.mdd.topupUnik.ubal.ApiUtils;
import com.mdd.topupUnik.ubal.InitReader;
import com.mdd.topupUnik.ubal.MainCardProcessor;
import com.mdd.topupUnik.ubal.SuccessUpdateBalance;
import com.mdd.topupUnik.ubal.UpdateBalanceView;
import com.mdd.topupUnik.ubal.lib.CardInfo;
import com.mdd.topupUnik.ubal.lib.CardInfoCommand;
import com.mdd.topupUnik.ubal.lib.CommandResult;
import java.net.InetAddress;
import java.util.Locale;
import butterknife.BindView;
import butterknife.ButterKnife;
import cn.pedant.SweetAlert.SweetAlertDialog;
import id.emhusnan.mdd.service.MDDUpdateBalanceView;
import static android.view.View.GONE;
import static com.medicom.organicdrv.utilsLib.ByteArrayToHexString;
public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceView, InitListener, NfcAdapter.ReaderCallback {
@BindView(R.id.logo_atas)
View logoAtas;
@BindView(R.id.card_number)
TextView cardNumber;
@BindView(R.id.iv_refresh)
ImageView ivRefresh;
@BindView(R.id.iv_logoresult)
ImageView logoResult;
@BindView(R.id.result_balance)
TextView resultBalance;
@BindView(R.id.tv_amount)
TextView tvAmount;
@BindView(R.id.result_amount)
TextView resultAmount;
@BindView(R.id.tv_newbalance)
TextView tvNewBalance;
@BindView(R.id.result_newbalance)
TextView resultNewBalance;
@BindView(R.id.c_result)
MaterialCardView mvResult;
@BindView(R.id.tap_card)
TextView tapCard;
private MainCardProcessor cardProcessor;
InitReader reader = null;
String TAG = "MainActivity";
Intent newIntent;
int amount = 0;
int prevBalance = 0;
CommandResult<CardInfo> execute;
TextToSpeech textToSpeech;
@Override
protected void onCreate(Bundle savedInstanceState) {
validateHasPermissions();
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
ButterKnife.bind(this);
getSupportActionBar().hide();
initCardProcessor();
if (isInternetAvailable()) {
NfcManager manager = (NfcManager) getSystemService(Context.NFC_SERVICE);
NfcAdapter adapter = manager.getDefaultAdapter();
Log.d(TAG, "adapter:" + adapter + "," + Build.MODEL + "," + Build.BRAND);
} else {
Toast.makeText(MainActivity.this, getResources().getString(R.string.connection_error), Toast.LENGTH_SHORT).show();
}
ivRefresh.setOnClickListener(v -> refreshUi());
}
private void initCardProcessor() {
cardProcessor = new MainCardProcessor(MainActivity.this, reader, new UpdateBalanceView() {
@Override
public void onUpdateBalanceSuccess(SuccessUpdateBalance successUpdateBalance) {
runOnUiThread(() -> MainActivity.this.onUpdateBalaceSuccess(successUpdateBalance));
}
@Override
public void onUpdateBalanceError(String reason) {
runOnUiThread(() -> MainActivity.this.onUpdateBalanceError(reason));
}
@Override
public void onCardDetected(CardInfo cardInfo) {
Log.d("Card", "card kedetek nih");
runOnUiThread(() -> MainActivity.this.onBalanceInfoAvailable(cardInfo));
}
@Override
public void onErrorNfcCardMsg(int errorCode) {
runOnUiThread(() -> MainActivity.this.onNFcCardNotSupported(errorCode));
}
}, ApiUtils.prod_environment, MyConstant.enabledBri);
textToSpeech = new TextToSpeech(getApplicationContext(), i -> {
if (i == TextToSpeech.SUCCESS) {
textToSpeech.setLanguage(new Locale("id", "ID"));
}
});
}
private void refreshUi() {
runOnUiThread(() -> {
mvResult.setVisibility(GONE);
tapCard.setVisibility(View.VISIBLE);
logoAtas.setBackgroundResource(R.drawable.bg_isiinaja);
resultBalance.setText("Rp. " + 0);
cardNumber.setText("xxxx xxxx xxxx xxxx");
});
beep();
}
private void validateHasPermissions() {
if (Build.VERSION.SDK_INT > 9) {
StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();
StrictMode.setThreadPolicy(policy);
}
// permission READ_PHONE_STATE
if (ContextCompat.checkSelfPermission(this,
android.Manifest.permission.READ_PHONE_STATE) != PackageManager.PERMISSION_GRANTED) {
Toast.makeText(this, "Please grant permission", Toast.LENGTH_SHORT).show();
if (ActivityCompat.shouldShowRequestPermissionRationale(this,
android.Manifest.permission.READ_PHONE_STATE)) {
} else {
ActivityCompat.requestPermissions(this,
new String[]{android.Manifest.permission.READ_PHONE_STATE,
android.Manifest.permission.INTERNET,
Manifest.permission.READ_EXTERNAL_STORAGE},
1);
}
} else {
Log.d(TAG, "--> Init Aar");
((MyApp) getApplication()).initAar(this);
}
}
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
((MyApp) getApplication()).initAar(this);
}
private boolean isInternetAvailable() {
try {
InetAddress ipAddr = InetAddress.getByName("google.com");
return !ipAddr.equals("");
} catch (Exception e) {
return false;
}
}
@Override
protected void onResume() {
super.onResume();
Log.e("onResume", "onresume");
if (MyConstant.enabledBri) {
Intent intent = new Intent(this, MainActivity.class);
intent.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP);
PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent, 0);
IntentFilter[] filters = new IntentFilter[]{};
cardProcessor.getNfcAdapter().enableForegroundDispatch(this, pendingIntent, filters, null);
} else {
if (isInternetAvailable()) {
NfcManager manager = (NfcManager) getSystemService(Context.NFC_SERVICE);
NfcAdapter adapter = manager.getDefaultAdapter();
final int READER_FLAGS = NfcAdapter.FLAG_READER_NFC_A | NfcAdapter.FLAG_READER_SKIP_NDEF_CHECK;
if (adapter != null && adapter.isEnabled()) {
adapter.enableReaderMode(this, this, READER_FLAGS, null);
}
} else {
Toast.makeText(MainActivity.this, getResources().getString(R.string.connection_error), Toast.LENGTH_SHORT).show();
}
}
}
@Override
public void onTagDiscovered(Tag tag) {
Log.d(TAG, "--> TagDiscover");
execute(tag);
}
private void execute(Tag tag) {
Log.d("Execute", "execute dipanggil");
AsyncTask.execute(() -> {
if (reader != null) {
try {
cardProcessor.lockIsoDepCard(tag);
} catch (Exception e) {
e.printStackTrace();
return;
}
String cardUid = ByteArrayToHexString(tag.getId());
Log.d("TagFromIntent", cardUid);
boolean hasCardUid = !cardUid.isEmpty();
if (hasCardUid) {
Log.d(TAG, "---> Send to UI Card Found");
CardInfoCommand command = new CardInfoCommand(reader.myReader);
Log.e("myReader", "Myreader : " + reader.myReader);
execute = command.execute(cardUid);
CardInfo detectedCardInfo = execute.getResult();
Log.d(TAG, "--> Card info : " + detectedCardInfo);
Log.d(TAG, "--> execute : " + execute.isSuccess());
if (execute.isSuccess()) {
if (detectedCardInfo.getBankType().toLowerCase().contains("dki")
|| detectedCardInfo.getBankType().toLowerCase().contains("bca")) {
runOnUiThread(() -> {
MainActivity.this.onBalanceInfoAvailable(detectedCardInfo);
});
} else {
cardProcessor.getBalance(detectedCardInfo, newIntent);
cardProcessor.updateBalance(detectedCardInfo, 1, newIntent);
}
} else {
if (MyConstant.enabledBri) {
runOnUiThread(() -> {
cardProcessor.getBalanceBri(newIntent);
});
} else {
runOnUiThread(() -> {
Log.e(TAG, "--> Message : " + execute.getMessage());
MainActivity.this.onUpdateBalanceError("Kartu belum didukung");
refreshUi();
cardProcessor.unlockIsoDepCard();
});
}
}
cardProcessor.unlockIsoDepCard();
} else {
//wrong card type
cardProcessor.unlockIsoDepCard();
}
}
});
}
public void beep() {
MediaPlayer mp = MediaPlayer.create(this, R.raw.beep);
mp.start();
}
@Override
public void onInitReaderComplete(InitReader reader) {
this.reader = reader;
cardProcessor = new MainCardProcessor(MainActivity.this, reader, new UpdateBalanceView() {
@Override
public void onUpdateBalanceSuccess(SuccessUpdateBalance successUpdateBalance) {
runOnUiThread(() -> MainActivity.this.onUpdateBalaceSuccess(successUpdateBalance));
}
@Override
public void onUpdateBalanceError(String reason) {
runOnUiThread(() -> MainActivity.this.onUpdateBalanceError(reason));
}
@Override
public void onCardDetected(CardInfo cardInfo) {
runOnUiThread(() -> MainActivity.this.onBalanceInfoAvailable(cardInfo));
if (!execute.isSuccess()) {
cardProcessor.updateBalanceBri(newIntent, "1");
}
}
@Override
public void onErrorNfcCardMsg(int errorCode) {
runOnUiThread(() -> MainActivity.this.onNFcCardNotSupported(errorCode));
}
}, ApiUtils.prod_environment, MyConstant.enabledBri);
}
@Override
public void onNFcCardNotSupported(int i) {
refreshUi();
Utils.dismissProgressDialog();
Utils.showDialog(this, "Gagal baca kartu", 1);
beep();
}
@Override
public void onNfcCardFound() {
Utils.dismissProgressDialog();
tapCard.setVisibility(GONE);
Utils.showDialog(this, "Mohon tunggu dan tempelkan kartu dengan benar", SweetAlertDialog.PROGRESS_TYPE);
}
@Override
public void onFinishOperation() {
}
@Override
public void onBalanceInfoAvailable(CardInfo cardInfo) {
Utils.dismissProgressDialog();
mvResult.setVisibility(View.VISIBLE);
prevBalance = cardInfo.getBalance();
String number = cardInfo.getCardNumber();
tvAmount.setVisibility(GONE);
resultAmount.setVisibility(GONE);
tvNewBalance.setVisibility(GONE);
resultNewBalance.setVisibility(GONE);
number = number.substring(0, 4) + " " + number.substring(4, 8) + " " + number.substring(8, 12) + " " + number.substring(12, number.length());
if (cardInfo.getBankType().toLowerCase().contains("mandiri")) {
logoAtas.setBackgroundResource(R.drawable.bg_emoney);
resultBalance.setText("Rp. " + String.format("%,d", cardInfo.getBalance()));
logoResult.setImageResource(R.drawable.bank_mandiri_logo);
cardNumber.setText(number);
} else if (cardInfo.getBankType().toLowerCase().contains("bca")) {
logoAtas.setBackgroundResource(R.drawable.bg_flazz);
resultBalance.setText("Rp. " + String.format("%,d", cardInfo.getBalance()));
logoResult.setImageResource(R.drawable.bca_logo);
cardNumber.setText(number);
tapCard.setVisibility(GONE);
} else if (cardInfo.getBankType().toLowerCase().contains("dki")) {
logoAtas.setBackgroundResource(R.drawable.bg_jackcard);
resultBalance.setText("Rp. " + String.format("%,d", cardInfo.getBalance()));
logoResult.setImageResource(R.drawable.dki_logo);
cardNumber.setText(number);
tapCard.setVisibility(GONE);
} else if (cardInfo.getBankType().toLowerCase().contains("bni")) {
logoAtas.setBackgroundResource(R.drawable.bg_tapcash);
resultBalance.setText("Rp. " + String.format("%,d", cardInfo.getBalance()));
logoResult.setImageResource(R.drawable.bni_logo);
cardNumber.setText(number);
} else {
logoAtas.setBackgroundResource(R.drawable.bg_brizzi);
resultBalance.setText("Rp. " + String.format("%,d", cardInfo.getBalance()));
logoResult.setImageResource(R.drawable.bri_logo);
cardNumber.setText(number);
}
if (!cardInfo.getBankType().toLowerCase().contains("dki") && !cardInfo.getBankType().toLowerCase().contains("bca")) {
runOnUiThread(this::onNfcCardFound);
}
}
@Override
public void onUpdateBalaceSuccess(SuccessUpdateBalance successUpdateBalance) {
mvResult.setVisibility(View.VISIBLE);
Utils.dismissProgressDialog();
tvAmount.setVisibility(GONE);
resultAmount.setVisibility(GONE);
tvNewBalance.setVisibility(GONE);
resultNewBalance.setVisibility(GONE);
if (successUpdateBalance.getMessage().contains("Tidak ada Pending Balance")
|| successUpdateBalance.getMessage().equalsIgnoreCase("Zero Balance")) {
Utils.showDialog(this, successUpdateBalance.getMessage(), SweetAlertDialog.WARNING_TYPE);
} else {
Utils.showDialog(this, successUpdateBalance.getMessage(), SweetAlertDialog.SUCCESS_TYPE);
amount = successUpdateBalance.getBalance() - prevBalance;
tvAmount.setVisibility(View.VISIBLE);
resultAmount.setVisibility(View.VISIBLE);
resultAmount.setText("Rp. " + String.format("%,d", amount));
tvNewBalance.setVisibility(View.VISIBLE);
resultNewBalance.setVisibility(View.VISIBLE);
resultNewBalance.setText("Rp. " + String.format("%,d", successUpdateBalance.getBalance()));
}
// beep();
textToSpeech.speak(successUpdateBalance.getBalance() + "Rupiah", TextToSpeech.QUEUE_FLUSH, null);
}
@Override
public void onUpdateBalanceError(String s) {
Utils.dismissProgressDialog();
Utils.showDialog(this, "Update balance gagal, " + s, SweetAlertDialog.ERROR_TYPE);
tvAmount.setVisibility(GONE);
resultAmount.setVisibility(GONE);
tvNewBalance.setVisibility(GONE);
resultNewBalance.setVisibility(GONE);
beep();
}
@Override
public void onBeginOperation() {
Log.d(TAG, "--> OnBeginOperation");
Utils.showDialog(this, "Waiting", SweetAlertDialog.PROGRESS_TYPE);
}
@Override
protected void onNewIntent(Intent intent) {
super.onNewIntent(intent);
this.newIntent = intent;
Log.e("newIntent", "action " + newIntent.getAction());
Tag tagFromIntent = intent.getParcelableExtra(NfcAdapter.EXTRA_TAG);
Log.e(TAG, "tag " + ByteArrayToHexString(tagFromIntent.getId()));
execute(tagFromIntent);
}
}
\ No newline at end of file
package com.mdd.updateaja;
import android.Manifest;
import android.app.Application;
import android.content.Context;
import android.content.pm.PackageManager;
import android.os.Build;
import android.telephony.TelephonyManager;
import android.util.Log;
import android.widget.Toast;
import com.bugfender.sdk.Bugfender;
import com.mdd.aar.deviceid.AarDeviceId;
import com.mdd.aar.deviceid.DeviceEnvironment;
import com.mdd.aar.deviceid.exceptions.DeviceNotRegisteredException;
import com.mdd.topupUnik.ubal.InitReader;
import com.medicom.dudikov.mybanklibrary.halDriver;
import com.medicom.dudikov.mybanklibrary.nativeLib;
import id.emhusnan.mdd.service.ConfigService;
import id.emhusnan.mdd.service.MDDService;
import io.reactivex.SingleObserver;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
import io.reactivex.schedulers.Schedulers;
public class MyApp extends Application {
String accessToken = "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJpc3MiOiJhdXRoLXNlcnZpY2U6MS4wLjAiLCJzdWIiOnsibmFtZSI6IlRlc3RTdGFnIiwidXNlcm5hbWUiOiJUZXN0U3RhZyIsImF1dGhfbGV2ZWwiOiJNRVJDSEFOVCIsIm1pZCI6IjIwZjFmMTNmODA1MGFjY2QxYjNjNzFlOWUyYTQ0NzU3In0sImlhdCI6MTU5MzQxMzM5MCwiZXhwIjoxNzUxMTk4MTUwLCJuYmYiOjE1OTM0MTMzOTJ9.E6UJMKha5YCbri4KRExDV4zeA1ZBfabpW-O6SInxxvfyTTYnUZCEu58STBGrOCL0RuxTFp5Y-XEyoa932fQcTpMBMsKkvDmGeftJ0hmjzAxAjHTfUxUyEa-HHF1whsM4YQUG9CesEBjU9IUcE6Rs-jykYxuryvvqqop5BoEIwO71qQBrq6DtpwjwFk9hbNt0EKs_HmCpySfXQxorfLMbAVJCHBYoo4UVymUfwUbps7hW6eQwNoBnt11O59CRPf6uUVIfCrsaaBMcJI-mc214-EMyl3RmMbqNl_f_0ITEJhMtK2zbUFZ8dMrGdZZgWJxiHdmzxqdaEPDVshYi9Uo31w";
int idDriver = nativeLib.USE_NFC_NATIVE;
private InitReader reader;
@Override
public void onCreate() {
super.onCreate();
}
public void initAar(InitListener listener) {
Bugfender.init(this, "apHTg4GcGupkx86oSnew7mm8cpbnwhAX", BuildConfig.DEBUG);
Bugfender.enableCrashReporting();
Bugfender.enableUIEventLogging(this);
Bugfender.enableLogcatLogging();
ConfigService configService = new ConfigService();
configService.setMid(MyConstant.MID);
configService.setToken(MyConstant.TOKEN);
configService.setEnvironment(0);
if (idDriver == 1) {
// configService.setTid("1234");
TelephonyManager telephonyManager = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
if (checkSelfPermission(Manifest.permission.READ_PHONE_STATE) != PackageManager.PERMISSION_GRANTED) {
Toast.makeText(this, "Please grant permission", Toast.LENGTH_SHORT).show();
return;
} else {
AarDeviceId aarDeviceId = new AarDeviceId(this);
String deviceId = "";
try {
deviceId = aarDeviceId.getDeviceId();
Log.d("deviceId", deviceId);
} catch (DeviceNotRegisteredException e) {
aarDeviceId.init(accessToken, DeviceEnvironment.PROD);
}
configService.setTid(deviceId);
MDDService initialize = MDDService.with(this, configService);
if (initialize.isValid()) {
reader = initialize.getInitReader();
// listener.onInitReaderComplete(reader);
Log.d("reader", String.valueOf(reader));
Log.d("MyApp", "--> Build Version");
Toast.makeText(this, "Aktivasi library sukses", Toast.LENGTH_SHORT).show();
} else {
Toast.makeText(this, "Library belum aktif", Toast.LENGTH_SHORT).show();
}
}
} else {
AarDeviceId aarDeviceId = new AarDeviceId(this);
String deviceId = "";
try {
deviceId = aarDeviceId.getDeviceId();
} catch (DeviceNotRegisteredException e) {
aarDeviceId.init(accessToken, DeviceEnvironment.PROD);
}
configService.setTid(deviceId);
MDDService initialize = MDDService.with(this, configService);
if (initialize.isValid()) {
Log.d("MyApp", "--> aardeviceid");
reader = initialize.getInitReader();
Toast.makeText(this, "Aktivasi library sukses", Toast.LENGTH_SHORT).show();
} else {
Toast.makeText(this, "Library belum aktif", Toast.LENGTH_SHORT).show();
}
}
} else {
Log.d("lariKemana", "Lari ke else bro");
new RxReader().initEdcReader(this, nativeLib.USE_NFC_NATIVE)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(new SingleObserver<InitReader>() {
@Override
public void onSubscribe(Disposable d) {
}
@Override
public void onSuccess(InitReader initReader) {
listener.onInitReaderComplete(initReader);
reader = initReader;
Log.e("initReader", String.valueOf(initReader));
}
@Override
public void onError(Throwable e) {
}
});
}
}
public InitReader getReader() {
return reader;
}
}
package com.mdd.updateaja;
public class MyConstant {
public static boolean enabledBri = true;
//prod
public static String MID = "49df5f81d59fae23ec6f542372fc9497";
public static String TOKEN = "82ae0ec8da26bca26d3540b08defc17d";
// public static String MID = "1234567abc";
// public static String TOKEN = "165eea86947a4e9483d1902f93495fc6";
}
package com.mdd.updateaja;
import android.content.Context;
import android.provider.Settings;
import com.mdd.aar.deviceid.AarDeviceId;
import com.mdd.aar.deviceid.DeviceEnvironment;
import com.mdd.aar.deviceid.exceptions.DeviceNotRegisteredException;
import com.mdd.topupUnik.ubal.InitDebugCertificate;
import com.mdd.topupUnik.ubal.InitReader;
import com.medicom.dudikov.mybanklibrary.nativeLib;
import id.emhusnan.mdd.service.ConfigService;
import id.emhusnan.mdd.service.LibraryConfig;
import io.reactivex.Single;
/**
* Created by Husnan on 13/05/2020
*/
public class RxReader {
Single<InitReader> initEdcReader(Context context, int deviceDriver) {
return Single.create(emitter -> {
String accessToken = "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJpc3MiOiJhdXRoLXNlcnZpY2U6MS4wLjAiLCJzdWIiOnsibmFtZSI6IlRlc3RTdGFnIiwidXNlcm5hbWUiOiJUZXN0U3RhZyIsImF1dGhfbGV2ZWwiOiJNRVJDSEFOVCIsIm1pZCI6IjIwZjFmMTNmODA1MGFjY2QxYjNjNzFlOWUyYTQ0NzU3In0sImlhdCI6MTU5MzQxMzM5MCwiZXhwIjoxNzUxMTk4MTUwLCJuYmYiOjE1OTM0MTMzOTJ9.E6UJMKha5YCbri4KRExDV4zeA1ZBfabpW-O6SInxxvfyTTYnUZCEu58STBGrOCL0RuxTFp5Y-XEyoa932fQcTpMBMsKkvDmGeftJ0hmjzAxAjHTfUxUyEa-HHF1whsM4YQUG9CesEBjU9IUcE6Rs-jykYxuryvvqqop5BoEIwO71qQBrq6DtpwjwFk9hbNt0EKs_HmCpySfXQxorfLMbAVJCHBYoo4UVymUfwUbps7hW6eQwNoBnt11O59CRPf6uUVIfCrsaaBMcJI-mc214-EMyl3RmMbqNl_f_0ITEJhMtK2zbUFZ8dMrGdZZgWJxiHdmzxqdaEPDVshYi9Uo31w";
AarDeviceId aarDeviceId = new AarDeviceId(context);
try {
aarDeviceId.getDeviceId();
} catch (DeviceNotRegisteredException e) {
aarDeviceId.init(accessToken, DeviceEnvironment.PROD);
}
try {
String androidId = Settings.Secure.getString(context.getContentResolver(), "android_id");
ConfigService configService = new ConfigService();
configService.setMid(MyConstant.MID);
configService.setTid(androidId);
configService.setToken(MyConstant.TOKEN);
configService.setEnvironment(0);
LibraryConfig config = new LibraryConfig(
configService.getMid(),
configService.getTid(),
configService.getToken(),
accessToken
, configService.getEnvironment());
nativeLib nativeLibrary = new nativeLib(context, deviceDriver);
InitDebugCertificate debugCertificate = new InitDebugCertificate();
InitReader reader = debugCertificate.getDebug(nativeLibrary, context, deviceDriver, config, true);
emitter.onSuccess(reader);
} catch (Exception e) {
e.printStackTrace();
emitter.onError(e);
}
});
}
}
package com.mdd.updateaja;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;
public class SplashscreenActivity extends AppCompatActivity {
private Handler handler;
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_splashscreen);
handler = new Handler();
final Runnable r = new Runnable() {
public void run() {
Intent intent = new Intent(SplashscreenActivity.this, MainActivity.class);
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(intent);
}
};
handler.postDelayed(r, 3000);
}
}
package com.mdd.updateaja;
import android.content.Context;
import cn.pedant.SweetAlert.SweetAlertDialog;
public class Utils {
public static SweetAlertDialog sweetAlert;
public static void showDialog(Context context, String message, int type) {
switch (type) {
case 0:
new SweetAlertDialog(context)
.setTitleText("Here's a message!")
.setContentText(message)
.show();
break;
case 1:
new SweetAlertDialog(context, SweetAlertDialog.ERROR_TYPE)
.setTitleText("Opps ...")
.setContentText(message)
.show();
break;
case 2:
new SweetAlertDialog(context, SweetAlertDialog.SUCCESS_TYPE)
.setTitleText("Selamat")
.setContentText(message)
.show();
break;
case 3:
new SweetAlertDialog(context, SweetAlertDialog.WARNING_TYPE)
.setTitleText("Info")
.setContentText(message)
.show();
break;
case 4:
new SweetAlertDialog(context, SweetAlertDialog.CUSTOM_IMAGE_TYPE)
.setTitleText("Android")
.setContentText(message)
.show();
break;
case 5:
sweetAlert = new SweetAlertDialog(context, SweetAlertDialog.PROGRESS_TYPE);
sweetAlert.setCancelable(false);
sweetAlert.setTitleText("Sedang diproses ...");
sweetAlert.setContentText(message).show();
break;
}
}
public static void dismissProgressDialog() {
if (sweetAlert != null)
sweetAlert.dismiss();
}
public static SweetAlertDialog getProgressDialog() {
return sweetAlert;
}
}
<vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillType="evenOdd"
android:pathData="M32,64C32,64 38.39,52.99 44.13,50.95C51.37,48.37 70.14,49.57 70.14,49.57L108.26,87.69L108,109.01L75.97,107.97L32,64Z"
android:strokeWidth="1"
android:strokeColor="#00000000">
<aapt:attr name="android:fillColor">
<gradient
android:endX="78.5885"
android:endY="90.9159"
android:startX="48.7653"
android:startY="61.0927"
android:type="linear">
<item
android:color="#44000000"
android:offset="0.0" />
<item
android:color="#00000000"
android:offset="1.0" />
</gradient>
</aapt:attr>
</path>
<path
android:fillColor="#FFFFFF"
android:fillType="nonZero"
android:pathData="M66.94,46.02L66.94,46.02C72.44,50.07 76,56.61 76,64L32,64C32,56.61 35.56,50.11 40.98,46.06L36.18,41.19C35.45,40.45 35.45,39.3 36.18,38.56C36.91,37.81 38.05,37.81 38.78,38.56L44.25,44.05C47.18,42.57 50.48,41.71 54,41.71C57.48,41.71 60.78,42.57 63.68,44.05L69.11,38.56C69.84,37.81 70.98,37.81 71.71,38.56C72.44,39.3 72.44,40.45 71.71,41.19L66.94,46.02ZM62.94,56.92C64.08,56.92 65,56.01 65,54.88C65,53.76 64.08,52.85 62.94,52.85C61.8,52.85 60.88,53.76 60.88,54.88C60.88,56.01 61.8,56.92 62.94,56.92ZM45.06,56.92C46.2,56.92 47.13,56.01 47.13,54.88C47.13,53.76 46.2,52.85 45.06,52.85C43.92,52.85 43,53.76 43,54.88C43,56.01 43.92,56.92 45.06,56.92Z"
android:strokeWidth="1"
android:strokeColor="#00000000" />
</vector>
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#D7D7D7"
android:endColor="#808080"
android:angle="90" />
<corners
android:topLeftRadius="10dp"
android:bottomRightRadius="10dp">
</corners>
</shape>
</item>
<item android:drawable="@drawable/brizzi_logo" />
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="rectangle">
<solid android:color="#CABBBBBB"/>
<corners android:radius="10dp" />
</shape>
</item>
<item
android:left="0dp"
android:right="3dp"
android:top="3dp"
android:bottom="0dp">
<shape android:shape="rectangle">
<solid android:color="@color/bg_card"/>
<corners android:radius="2dp" />
</shape>
</item>
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#D7D7D7"
android:endColor="#808080"
android:angle="90" />
<corners
android:topLeftRadius="10dp"
android:bottomRightRadius="10dp">
</corners>
</shape>
</item>
<item android:drawable="@drawable/emoney" />
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#D7D7D7"
android:endColor="#808080"
android:angle="90" />
<corners
android:topLeftRadius="10dp"
android:bottomRightRadius="10dp">
</corners>
</shape>
</item>
<item android:drawable="@drawable/flazz_logo" />
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#006499"
android:endColor="#0093d7"
android:angle="90" />
<corners
android:radius="10dp">
</corners>
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#D7D7D7"
android:endColor="#808080"
android:angle="90" />
<corners
android:topLeftRadius="10dp"
android:bottomRightRadius="10dp">
</corners>
</shape>
</item>
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#D7D7D7"
android:endColor="#808080"
android:angle="90" />
<corners
android:topLeftRadius="10dp"
android:bottomRightRadius="10dp">
</corners>
</shape>
</item>
<item android:drawable="@drawable/jakcard_logo" />
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#D7D7D7"
android:endColor="#808080"
android:angle="90" />
<corners
android:topLeftRadius="10dp"
android:bottomRightRadius="10dp">
</corners>
</shape>
</item>
<item android:drawable="@drawable/tapcash_logo" />
</layer-list>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle" >
<corners
android:radius="20dp"/>
<stroke
android:width="0.5dp"
android:color="@color/bg_blue" />
<solid android:color="@color/bg_blue" />
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="#221f1f"/>
<corners android:radius="8dp"/>
<stroke
android:width="1dp"
android:color="#DCDCDC"/>
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillColor="#008577"
android:pathData="M0,0h108v108h-108z" />
<path
android:fillColor="#00000000"
android:pathData="M9,0L9,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,0L19,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M29,0L29,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M39,0L39,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M49,0L49,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M59,0L59,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M69,0L69,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M79,0L79,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M89,0L89,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M99,0L99,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,9L108,9"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,19L108,19"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,29L108,29"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,39L108,39"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,49L108,49"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,59L108,59"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,69L108,69"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,79L108,79"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,89L108,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,99L108,99"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,29L89,29"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,39L89,39"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,49L89,49"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,59L89,59"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,69L89,69"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,79L89,79"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M29,19L29,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M39,19L39,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M49,19L49,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M59,19L59,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M69,19L69,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M79,19L79,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
</vector>
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="#fff"/>
<corners android:radius="8dp"/>
<stroke
android:width="1dp"
android:color="#DCDCDC"/>
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<font-family xmlns:app="http://schemas.android.com/apk/res-auto"
app:fontProviderAuthority="com.google.android.gms.fonts"
app:fontProviderPackage="com.google.android.gms"
app:fontProviderQuery="Allerta"
app:fontProviderCerts="@array/com_google_android_gms_fonts_certs">
</font-family>
<?xml version="1.0" encoding="utf-8"?>
<font-family xmlns:app="http://schemas.android.com/apk/res-auto"
app:fontProviderAuthority="com.google.android.gms.fonts"
app:fontProviderPackage="com.google.android.gms"
app:fontProviderQuery="Wendy One"
app:fontProviderCerts="@array/com_google_android_gms_fonts_certs">
</font-family>
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="7dp">
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/constraintLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:layout_editor_absoluteX="7dp"
tools:layout_editor_absoluteY="7dp">
<TextView
android:id="@+id/title_app"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableLeft="@drawable/logo_isiinaja"
android:drawablePadding="5dp"
android:fontFamily="@font/allerta"
android:text="Isiin Aja"
android:textSize="25sp"
app:layout_constraintBottom_toTopOf="@+id/c_card"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.498"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.43" />
<com.google.android.material.card.MaterialCardView
android:id="@+id/c_card"
android:layout_width="match_parent"
android:layout_height="230dp"
android:layout_margin="5dp"
app:cardCornerRadius="10dp"
app:cardElevation="3dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.13">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<View
android:id="@+id/view"
android:layout_width="match_parent"
android:layout_height="230dp"
android:background="@drawable/bg_gradient"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.496"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.053" />
<View
android:id="@+id/logo_atas"
android:layout_width="77dp"
android:layout_height="50dp"
android:background="@drawable/bg_isiinaja"
app:layout_constraintBottom_toBottomOf="@+id/view"
app:layout_constraintEnd_toEndOf="@+id/view"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="@+id/view"
app:layout_constraintTop_toTopOf="@+id/view"
app:layout_constraintVertical_bias="0.0" />
<TextView
android:id="@+id/card_number"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:text="xxxx xxxx xxxx xxxx"
android:textColor="#fff"
android:textSize="23sp"
app:layout_constraintBottom_toBottomOf="@+id/view"
app:layout_constraintEnd_toEndOf="@+id/view"
app:layout_constraintHorizontal_bias="0.196"
app:layout_constraintStart_toStartOf="@+id/view"
app:layout_constraintTop_toTopOf="@+id/view"
app:layout_constraintVertical_bias="0.788" />
<ImageView
android:id="@+id/iv_refresh"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/logo_refresh"
app:layout_constraintBottom_toBottomOf="@+id/view"
app:layout_constraintEnd_toEndOf="@+id/view"
app:layout_constraintHorizontal_bias="0.923"
app:layout_constraintStart_toStartOf="@+id/view"
app:layout_constraintTop_toTopOf="@+id/view"
app:layout_constraintVertical_bias="0.848" />
</androidx.constraintlayout.widget.ConstraintLayout>
</com.google.android.material.card.MaterialCardView>
<com.google.android.material.card.MaterialCardView
android:id="@+id/c_result"
android:layout_width="match_parent"
android:layout_height="180dp"
android:layout_margin="5dp"
android:elevation="2dp"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/c_card"
app:layout_constraintVertical_bias="0.13999999">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="5dp">
<ImageView
android:id="@+id/iv_logoresult"
android:layout_width="100dp"
android:layout_height="67dp"
android:src="@drawable/bank_mandiri_logo"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.0" />
<TextView
android:id="@+id/tv_balance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Saldo Awal"
android:textSize="17sp"
android:textStyle="bold"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/iv_logoresult"
app:layout_constraintVertical_bias="0.0" />
<TextView
android:id="@+id/result_balance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Rp. 1000"
android:textSize="17sp"
android:textStyle="bold"
app:layout_constraintBottom_toBottomOf="@id/tv_balance"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@+id/tv_balance" />
<TextView
android:id="@+id/tv_amount"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="2dp"
android:text="Nilai Topup"
android:textSize="17sp"
android:textStyle="bold"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/tv_balance"
app:layout_constraintVertical_bias="0.25" />
<TextView
android:id="@+id/result_amount"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Rp. 1000"
android:textSize="17sp"
android:textStyle="bold"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="@id/tv_amount"
app:layout_constraintEnd_toEndOf="@+id/result_balance"
app:layout_constraintTop_toTopOf="@+id/tv_amount" />
<TextView
android:id="@+id/tv_newbalance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="Saldo Akhir"
android:textSize="17sp"
android:textStyle="bold"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/tv_amount" />
<TextView
android:id="@+id/result_newbalance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Rp. 1000"
android:textSize="17sp"
android:textStyle="bold"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="@id/tv_newbalance"
app:layout_constraintEnd_toEndOf="@+id/result_amount"
app:layout_constraintTop_toTopOf="@+id/tv_newbalance" />
</androidx.constraintlayout.widget.ConstraintLayout>
</com.google.android.material.card.MaterialCardView>
<ImageView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:alpha="0.3"
android:scaleType="centerCrop"
android:src="@drawable/bg_bawah"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@id/c_card"
tools:layout_editor_absoluteX="10dp" />
</androidx.constraintlayout.widget.ConstraintLayout>
<com.google.android.material.card.MaterialCardView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:elevation="2dp"
android:padding="5dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="@+id/constraintLayout"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/constraintLayout">
<TextView
android:id="@+id/tap_card"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:fontFamily="@font/allerta"
android:gravity="center"
android:text="Silahkan tempel kartu Anda"
android:textSize="23sp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@+id/c_card"
app:layout_constraintVertical_bias="0.102"
tools:layout_editor_absoluteX="16dp" />
</com.google.android.material.card.MaterialCardView>
</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/bg_blue">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<ImageView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:rotation="180"
android:layout_weight="1"
android:src="@drawable/blue_modern_technologi" />
<ImageView
android:layout_weight="1
"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:src="@drawable/blue_modern_technologi" />
</LinearLayout>
<ImageView
android:layout_width="100dp"
android:layout_height="100dp"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:src="@drawable/isiinajalogo" />
</RelativeLayout>
\ No newline at end of file
<resources>
<string name="app_name">Isiin Aja</string>
<string name="card_number">Nomor Kartu</string>
<string name="old_balance">Saldo lama</string>
<string name="new_balance">Saldo Baru</string>
<string name="amount">Jumlah Topup</string>
<string name="balance">Saldo</string>
<string name="check_balance">Check Balance</string>
<string name="update_balance">Update Balance</string>
<string name="update_success">Update Sukses</string>
<string name="tap_card">Tempelkan Kartu</string>
<string name="card_info">Info Kartu</string>
<string name="keep_tap">Silahkan tunggu, harap kartu selalu ditempelkan</string>
<string name="nfc_not_found">NFC reader tidak ada atau tidak aktif</string>
<string name="no_pending_balance">Tidak ada pending balance</string>
<string name="card_detect_error">Kartu tidak terbaca</string>
<string name="update_balance_failed">Update Balance Gagal, silahkan tempelkan kembali [%s]</string>
<string name="update_balance_data_missmatch">Maaf saat ini tidak bisa melakukan update balance, Silahkan update balance di ATM mandiri terdekat</string>
<string name="reversal_failed">Update Balance Gagal, silahkan tempelkan kembali. [%s]</string>
<string name="reversal_success">Update Balance Gagal, Silahkan tempelkan kembali [00]</string>
<string name="write_card_failed">Update Balance Gagal, Silahkan tempelkan kembali. [%s]</string>
<string name="tap_for_reversal">Tempelkan Untuk melakukan reversal</string>
<string name="loading">Silahkan Tunggu.</string>
<string name="loading_reversal">Silahkan Tunggu..</string>
<string name="copied">Copy nomor kartu</string>
<string name="error_not_setup">Loading setup</string>
<string name="connection_error">Koneksi bermasalah</string>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#008577</color>
<color name="colorPrimaryDark">#00574B</color>
<color name="colorAccent">#D81B60</color>
<color name="text_label">#ffffff</color>
<color name="text_label2">#414042</color>
<color name="text_success">#22bb33</color>
<color name="text_error">#bb2124</color>
<color name="text_warning">#f0ad4e</color>
<color name="text_normal">#000</color>
<color name="bg_blue">#3498eb</color>
<color name="bg_card">#aa4a30</color>
</resources>
<resources>
<dimen name="fab_margin">16dp</dimen>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<array name="com_google_android_gms_fonts_certs">
<item>@array/com_google_android_gms_fonts_certs_dev</item>
<item>@array/com_google_android_gms_fonts_certs_prod</item>
</array>
<string-array name="com_google_android_gms_fonts_certs_dev">
<item>
MIIEqDCCA5CgAwIBAgIJANWFuGx90071MA0GCSqGSIb3DQEBBAUAMIGUMQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEQMA4GA1UEChMHQW5kcm9pZDEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDEiMCAGCSqGSIb3DQEJARYTYW5kcm9pZEBhbmRyb2lkLmNvbTAeFw0wODA0MTUyMzM2NTZaFw0zNTA5MDEyMzM2NTZaMIGUMQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEQMA4GA1UEChMHQW5kcm9pZDEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDEiMCAGCSqGSIb3DQEJARYTYW5kcm9pZEBhbmRyb2lkLmNvbTCCASAwDQYJKoZIhvcNAQEBBQADggENADCCAQgCggEBANbOLggKv+IxTdGNs8/TGFy0PTP6DHThvbbR24kT9ixcOd9W+EaBPWW+wPPKQmsHxajtWjmQwWfna8mZuSeJS48LIgAZlKkpFeVyxW0qMBujb8X8ETrWy550NaFtI6t9+u7hZeTfHwqNvacKhp1RbE6dBRGWynwMVX8XW8N1+UjFaq6GCJukT4qmpN2afb8sCjUigq0GuMwYXrFVee74bQgLHWGJwPmvmLHC69EH6kWr22ijx4OKXlSIx2xT1AsSHee70w5iDBiK4aph27yH3TxkXy9V89TDdexAcKk/cVHYNnDBapcavl7y0RiQ4biu8ymM8Ga/nmzhRKya6G0cGw8CAQOjgfwwgfkwHQYDVR0OBBYEFI0cxb6VTEM8YYY6FbBMvAPyT+CyMIHJBgNVHSMEgcEwgb6AFI0cxb6VTEM8YYY6FbBMvAPyT+CyoYGapIGXMIGUMQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEQMA4GA1UEChMHQW5kcm9pZDEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDEiMCAGCSqGSIb3DQEJARYTYW5kcm9pZEBhbmRyb2lkLmNvbYIJANWFuGx90071MAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEEBQADggEBABnTDPEF+3iSP0wNfdIjIz1AlnrPzgAIHVvXxunW7SBrDhEglQZBbKJEk5kT0mtKoOD1JMrSu1xuTKEBahWRbqHsXclaXjoBADb0kkjVEJu/Lh5hgYZnOjvlba8Ld7HCKePCVePoTJBdI4fvugnL8TsgK05aIskyY0hKI9L8KfqfGTl1lzOv2KoWD0KWwtAWPoGChZxmQ+nBli+gwYMzM1vAkP+aayLe0a1EQimlOalO762r0GXO0ks+UeXde2Z4e+8S/pf7pITEI/tP+MxJTALw9QUWEv9lKTk+jkbqxbsh8nfBUapfKqYn0eidpwq2AzVp3juYl7//fKnaPhJD9gs=
</item>
</string-array>
<string-array name="com_google_android_gms_fonts_certs_prod">
<item>
MIIEQzCCAyugAwIBAgIJAMLgh0ZkSjCNMA0GCSqGSIb3DQEBBAUAMHQxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpDYWxpZm9ybmlhMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtHb29nbGUgSW5jLjEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDAeFw0wODA4MjEyMzEzMzRaFw0zNjAxMDcyMzEzMzRaMHQxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpDYWxpZm9ybmlhMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtHb29nbGUgSW5jLjEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDCCASAwDQYJKoZIhvcNAQEBBQADggENADCCAQgCggEBAKtWLgDYO6IIrgqWbxJOKdoR8qtW0I9Y4sypEwPpt1TTcvZApxsdyxMJZ2JORland2qSGT2y5b+3JKkedxiLDmpHpDsz2WCbdxgxRczfey5YZnTJ4VZbH0xqWVW/8lGmPav5xVwnIiJS6HXk+BVKZF+JcWjAsb/GEuq/eFdpuzSqeYTcfi6idkyugwfYwXFU1+5fZKUaRKYCwkkFQVfcAs1fXA5V+++FGfvjJ/CxURaSxaBvGdGDhfXE28LWuT9ozCl5xw4Yq5OGazvV24mZVSoOO0yZ31j7kYvtwYK6NeADwbSxDdJEqO4k//0zOHKrUiGYXtqw/A0LFFtqoZKFjnkCAQOjgdkwgdYwHQYDVR0OBBYEFMd9jMIhF1Ylmn/Tgt9r45jk14alMIGmBgNVHSMEgZ4wgZuAFMd9jMIhF1Ylmn/Tgt9r45jk14aloXikdjB0MQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEUMBIGA1UEChMLR29vZ2xlIEluYy4xEDAOBgNVBAsTB0FuZHJvaWQxEDAOBgNVBAMTB0FuZHJvaWSCCQDC4IdGZEowjTAMBgNVHRMEBTADAQH/MA0GCSqGSIb3DQEBBAUAA4IBAQBt0lLO74UwLDYKqs6Tm8/yzKkEu116FmH4rkaymUIE0P9KaMftGlMexFlaYjzmB2OxZyl6euNXEsQH8gjwyxCUKRJNexBiGcCEyj6z+a1fuHHvkiaai+KL8W1EyNmgjmyy8AW7P+LLlkR+ho5zEHatRbM/YAnqGcFh5iZBqpknHf1SKMXFh4dd239FJ1jWYfbMDMy3NS5CTMQ2XFI1MvcyUTdZPErjQfTbQe3aDQsQcafEQPD+nqActifKZ0Np0IS9L9kR/wbNvyz6ENwPiTrjV2KRkEjH78ZMcUQXg0L3BYHJ3lc69Vs5Ddf9uUGGMYldX3WfMBEmh/9iFBDAaTCK
</item>
</string-array>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<array name="preloaded_fonts" translatable="false">
<item>@font/allerta</item>
<item>@font/wendy_one</item>
</array>
</resources>
<resources>
<string name="app_name">MDD Isiin Aja</string>
<string name="card_number">Card Number</string>
<string name="old_balance">Previous Balance</string>
<string name="new_balance">New Balance</string>
<string name="amount">Amount</string>
<string name="balance">Balance</string>
<string name="check_balance">Check Balance</string>
<string name="update_balance">Update Balance</string>
<string name="update_success">Update Success</string>
<string name="tap_card">Tap Card</string>
<string name="card_info">Card Info</string>
<string name="keep_tap">Please wait, card must always be tapped</string>
<string name="nfc_not_found">NFC reader not found or disable</string>
<string name="no_pending_balance">No Pending Balance</string>
<string name="card_detect_error">No Card Detected</string>
<string name="update_balance_failed">Update Balance Failed, please re-tap</string>
<string name="update_balance_data_missmatch">Sorry, Cannot update balance right now, please update balance at Mandiri ATM machine</string>
<string name="reversal_failed">Update Balance Failed, please re-tap.</string>
<string name="reversal_success">Update Balance Failed, Please re-tap.</string>
<string name="write_card_failed">Update Balance Failed, Please re-tap. [%s]</string>
<string name="tap_for_reversal">Tap For Reversal</string>
<string name="loading">Please Wait.</string>
<string name="loading_reversal">Please Wait..</string>
<string name="copied">Copy Card Number</string>
<string name="error_not_setup">Not Setup yet</string>
<string name="connection_error">Connection Error</string>
<string name="TapMore" translatable="false">Tempelkan sekali lagi untuk memperbarui Saldo</string>
<string name="SuccessGetCard" translatable="false">Sukses mendapatkan info kartu</string>
<string name="title_activity_manual_library">ManualLibraryActivity</string>
<string name="last_balance">Last Balance</string>
</resources>
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.MaterialComponents.Light.DarkActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>
<style name="AppTheme.NoActionBar">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
</style>
<style name="AppTheme.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
<style name="AppTheme.PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
</resources>
<?xml version="1.0" encoding="utf-8"?>
<network-security-config>
<base-config cleartextTrafficPermitted="true"/>
</network-security-config>
\ No newline at end of file
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<tech-list>
<tech>android.nfc.tech.MifareClassic</tech>
</tech-list>
</resources>
\ No newline at end of file
package id.mcash.emoney;
import org.junit.Test;
import static org.junit.Assert.*;
/**
* Example local unit test, which will execute on the development machine (host).
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
public class ExampleUnitTest {
@Test
public void addition_isCorrect() {
assertEquals(4, 2 + 2);
}
}
\ No newline at end of file
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.0.1'
classpath "org.jfrog.buildinfo:build-info-extractor-gradle:4.7.5"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
google()
jcenter()
maven {
url "http://mobile-repo.mdd.co.id:8081/artifactory/android-library/"
credentials {
username = artifactory_username
password = artifactory_password
}
}
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx1536m
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
artifactory_username=partner
artifactory_password=Partner*123#
android.useAndroidX=true
android.enableJetifier=true
\ No newline at end of file
#Tue Sep 22 13:52:02 WIB 2020
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.1.1-all.zip
#!/usr/bin/env sh
##############################################################################
##
## Gradle start up script for UN*X
##
##############################################################################
# Attempt to set APP_HOME
# Resolve links: $0 may be a link
PRG="$0"
# Need this for relative symlinks.
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`"/$link"
fi
done
SAVED="`pwd`"
cd "`dirname \"$PRG\"`/" >/dev/null
APP_HOME="`pwd -P`"
cd "$SAVED" >/dev/null
APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
warn () {
echo "$*"
}
die () {
echo
echo "$*"
echo
exit 1
}
# OS specific support (must be 'true' or 'false').
cygwin=false
msys=false
darwin=false
nonstop=false
case "`uname`" in
CYGWIN* )
cygwin=true
;;
Darwin* )
darwin=true
;;
MINGW* )
msys=true
;;
NONSTOP* )
nonstop=true
;;
esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
# IBM's JDK on AIX uses strange locations for the executables
JAVACMD="$JAVA_HOME/jre/sh/java"
else
JAVACMD="$JAVA_HOME/bin/java"
fi
if [ ! -x "$JAVACMD" ] ; then
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
else
JAVACMD="java"
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
# Increase the maximum file descriptors if we can.
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
MAX_FD_LIMIT=`ulimit -H -n`
if [ $? -eq 0 ] ; then
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
MAX_FD="$MAX_FD_LIMIT"
fi
ulimit -n $MAX_FD
if [ $? -ne 0 ] ; then
warn "Could not set maximum file descriptor limit: $MAX_FD"
fi
else
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
fi
fi
# For Darwin, add options to specify how the application appears in the dock
if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi
# For Cygwin, switch paths to Windows format before running java
if $cygwin ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
JAVACMD=`cygpath --unix "$JAVACMD"`
# We build the pattern for arguments to be converted via cygpath
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
SEP=""
for dir in $ROOTDIRSRAW ; do
ROOTDIRS="$ROOTDIRS$SEP$dir"
SEP="|"
done
OURCYGPATTERN="(^($ROOTDIRS))"
# Add a user-defined pattern to the cygpath arguments
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
fi
# Now convert the arguments - kludge to limit ourselves to /bin/sh
i=0
for arg in "$@" ; do
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
else
eval `echo args$i`="\"$arg\""
fi
i=$((i+1))
done
case $i in
(0) set -- ;;
(1) set -- "$args0" ;;
(2) set -- "$args0" "$args1" ;;
(3) set -- "$args0" "$args1" "$args2" ;;
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
# Escape application args
save () {
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
echo " "
}
APP_ARGS=$(save "$@")
# Collect all arguments for the java command, following the shell quoting and substitution rules
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
cd "$(dirname "$0")"
fi
exec "$JAVACMD" "$@"
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@rem Gradle startup script for Windows
@rem
@rem ##########################################################################
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto init
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:init
@rem Get command-line arguments, handling Windows variants
if not "%OS%" == "Windows_NT" goto win9xME_args
:win9xME_args
@rem Slurp the command line arguments.
set CMD_LINE_ARGS=
set _SKIP=2
:win9xME_args_slurp
if "x%~1" == "x" goto execute
set CMD_LINE_ARGS=%*
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
:end
@rem End local scope for the variables with windows NT shell
if "%ERRORLEVEL%"=="0" goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
exit /b 1
:mainEnd
if "%OS%"=="Windows_NT" endlocal
:omega
configurations.maybeCreate("default")
artifacts.add("default", file('mdd-service-release.aar'))
\ No newline at end of file
configurations.maybeCreate("default")
artifacts.add("default", file('mybanklibrary-release-3.3.2.aar'))
\ No newline at end of file
configurations.maybeCreate("default")
artifacts.add("default", file('partner-connect-2.2.1.aar'))
\ No newline at end of file
include ':unik-update-balance-lib-release'
include ':unik-update-balance-lib-release'
include ':unik-update-balance-lib-release'
include ':unik-update-balance-lib-debug'
include ':app', ':mdd-service-release'
configurations.maybeCreate("default")
artifacts.add("default", file('unik-update-balance-lib-release.aar'))
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment