This is a Chinese version of https://gist.github.com/1207002/86f48cd3b3b72c85e6293926cf7c730de03b2f08 from lucasfais
| ⌘T | 前往文件 |
| ⌘⌃P | 前往项目 |
| ⌘R | 前往 method |
| ⌘⇧P | 命令提示 |
| generate-dependency-graph: | |
| name: Generate Dependency Graph | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v2 | |
| - name: Setup Graphviz | |
| uses: ts-graphviz/setup-graphviz@v1 |
| /** | |
| * Copyright 2019 Coinbase, Inc. | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the | |
| * "License"); you may not use this file except in compliance | |
| * with the License. You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, |
| import android.os.Environment; | |
| import android.support.annotation.NonNull; | |
| import java.io.File; | |
| import java.io.FileOutputStream; | |
| import java.io.IOException; | |
| import java.io.InputStream; | |
| import java.util.concurrent.TimeUnit; |
| import android.app.Activity; | |
| import android.app.Application; | |
| import android.content.Context; | |
| import android.content.ContextWrapper; | |
| import android.os.Bundle; | |
| import android.os.Looper; | |
| import android.os.MessageQueue; | |
| import android.util.Log; | |
| import android.view.View; | |
| import android.view.ViewTreeObserver; |
| /* | |
| * Copyright 2014 Pierre Degand | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software |
| // Device memory data | |
| ActivityManager activityManager = (ActivityManager) androidContext.getApplicationContext().getSystemService(Context.ACTIVITY_SERVICE); | |
| // Runtime data memory numbers are in bytes (dalvik process?) | |
| int processors = runtime.availableProcessors(); | |
| long totalMemory = runtime.totalMemory(); | |
| long freeMemory = runtime.freeMemory(); | |
| System.out.println(String.format("Runtime: %d processors, %d totalMemory (bytes), %d freeMemory (bytes)", processors, totalMemory, freeMemory)); | |
| // Debug data (system wide) memory numbers are in bytes |
This is a Chinese version of https://gist.github.com/1207002/86f48cd3b3b72c85e6293926cf7c730de03b2f08 from lucasfais
| ⌘T | 前往文件 |
| ⌘⌃P | 前往项目 |
| ⌘R | 前往 method |
| ⌘⇧P | 命令提示 |