This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
classpath 'com.huawei.agconnect:agcp-harmony:1.1.0.200' | |
maven { | |
url 'https://developer.huawei.com/repo/' | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?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" | |
tools:context=".MainActivity"> | |
<androidx.appcompat.widget.AppCompatButton | |
android:id="@+id/calculatePIValueBTn" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.multithreaddemo | |
import android.annotation.SuppressLint | |
import android.os.Bundle | |
import android.util.Log | |
import androidx.appcompat.app.AppCompatActivity | |
import kotlinx.android.synthetic.main.activity_main.* | |
class MainActivity : AppCompatActivity() { | |
private var pi = 0.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<uses-permission android:name="android.permission.INTERNET" /> | |
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
implementation 'com.huawei.hms:stats:4.0.3.302' | |
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" | |
implementation 'androidx.appcompat:appcompat:1.1.0' | |
implementation 'androidx.core:core-ktx:1.2.0' | |
implementation 'androidx.constraintlayout:constraintlayout:1.1.3' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
keytool -list -v -keystore D:\studio\projects_name\file_name.keystore -alias alias_name |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For more information about using CMake with Android Studio, read the | |
# documentation: https://d.android.com/studio/projects/add-native-code.html | |
# Sets the minimum version of CMake required to build the native library. | |
cmake_minimum_required(VERSION 3.4.1) | |
# Creates and names a library, sets it as either STATIC | |
# or SHARED, and provides the relative paths to its source code. | |
# You can define multiple libraries, and CMake builds them for you. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<DirectionalLayout | |
xmlns:ohos="http://schemas.huawei.com/res/ohos" | |
ohos:height="match_parent" | |
ohos:width="match_parent" | |
ohos:alignment="center" | |
ohos:orientation="vertical"> | |
<Text | |
ohos:id="$+id:userAddress" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.hms.locationservice; | |
import ohos.aafwk.ability.Ability; | |
import ohos.aafwk.content.Intent; | |
import ohos.agp.components.Button; | |
import ohos.agp.components.Text; | |
import ohos.bundle.IBundleManager; | |
import ohos.hiviewdfx.HiLog; | |
import ohos.hiviewdfx.HiLogLabel; | |
import ohos.location.*; |