|
1 |
| -[](https://github.com/Ayvytr/AndroidEasyDeveloper/releases) |
2 |
| -[](https://jitpack.io/#Ayvytr/AndroidEasyDeveloper) |
3 |
| -<a href="http://www.methodscount.com/?lib=com.github.Ayvytr%3AAndroidEasyDeveloper%3A1.0.0"><img src="https://img.shields.io/badge/Size-20 KB-e91e63.svg"/></a> |
4 |
| -### |
5 |
| -<a href="http://www.methodscount.com/?lib=com.github.Ayvytr%3AAndroidEasyDeveloper%3A1.0.0"><img src="https://img.shields.io/badge/Methods count-core: 15 | deps: 19163-e91e63.svg"/></a> |
6 |
| -<a href="http://www.methodscount.com/?lib=com.github.Ayvytr%3AAndroidEasyDeveloper%3A1.0.0"><img src="https://img.shields.io/badge/Methods and size-core: 15 | deps: 19163 | 20 KB-e91e63.svg"/></a> |
7 |
| - |
8 |
| -#AndroidEasyDeveloper |
9 |
| -###Contains |
10 |
| -1. Resources |
11 |
| - |
12 |
| - Dp and sp from 0 to 100 |
13 |
| - |
14 |
| - Styles for some Views |
15 |
| - |
16 |
| -2. CustomView |
17 |
| - |
18 |
| - CenterGravityTextView |
19 |
| - |
20 |
| - LeftCenterGravityTextView |
21 |
| - |
22 |
| - RightCenterGravityTextView |
23 |
| - |
24 |
| -3. *Tool classes |
25 |
| - |
26 |
| - DensityTool |
27 |
| - |
28 |
| - TextTool |
29 |
| - |
30 |
| - ScreenTool |
31 |
| - |
32 |
| - ... |
33 |
| - |
34 |
| -##Use |
35 |
| - About Context: |
36 |
| - 1.Call 'Easy.getDefault().init(this);' on your Application.onCreate(); |
37 |
| - 2.Call DensityTool.dp2px(...) ... |
38 |
| - |
39 |
| - Others: |
40 |
| - 1.Use directly; |
41 |
| - |
42 |
| -##Build |
43 |
| - |
44 |
| -###Step 1. Add the JitPack repository to your build file |
45 |
| - |
46 |
| -####Add it in your root build.gradle at the end of repositories: |
47 |
| - |
48 |
| - allprojects { |
49 |
| - repositories { |
50 |
| - ... |
51 |
| - maven { url 'https://jitpack.io' } |
52 |
| - } |
53 |
| - } |
54 |
| - |
55 |
| -####Step 2. Add the dependency |
56 |
| - |
57 |
| - dependencies { |
58 |
| - compile 'com.github.Ayvytr:AndroidEasyDeveloper:1.1.0' |
59 |
| - } |
60 |
| - |
61 |
| - |
62 |
| -###Quote below,thanks for their libraries |
63 |
| -1. https://github.com/Blankj/AndroidUtilCode |
64 |
| -2. https://github.com/Trinea/android-common |
65 |
| -3. https://github.com/wyouflf/xUtils3 |
66 |
| -4. https://github.com/jingle1267/android-utils |
67 |
| - |
68 |
| -###TODO: |
69 |
| -1. Complements Convert class |
70 |
| -2. Create my PrettyVideoPlayer |
71 |
| -3. Complements my library |
72 |
| -4. Personal website |
| 1 | +[](https://github.com/Ayvytr/AndroidEasyDeveloper/releases) |
| 2 | +[](https://jitpack.io/#Ayvytr/AndroidEasyDeveloper) |
| 3 | +<a href="http://www.methodscount.com/?lib=com.github.Ayvytr%3AAndroidEasyDeveloper%3A1.0.0"><img src="https://img.shields.io/badge/Size-20 KB-e91e63.svg"/></a> |
| 4 | + |
| 5 | +<a href="http://www.methodscount.com/?lib=com.github.Ayvytr%3AAndroidEasyDeveloper%3A1.0.0"><img src="https://img.shields.io/badge/Methods count-core: 15 | deps: 19163-e91e63.svg"/></a> |
| 6 | + |
| 7 | +<a href="http://www.methodscount.com/?lib=com.github.Ayvytr%3AAndroidEasyDeveloper%3A1.0.0"><img src="https://img.shields.io/badge/Methods and size-core: 15 | deps: 19163 | 20 KB-e91e63.svg"/></a> |
| 8 | + |
| 9 | +#EasyAndroid Library |
| 10 | + |
| 11 | +#[Chinese][README_CN.md] |
| 12 | + |
| 13 | +##Use |
| 14 | + (About Context classes: You need call 'Easy.getDefault().init(this);' |
| 15 | + on your 'Application.onCreate()' first) |
| 16 | + |
| 17 | + Then, use directly; |
| 18 | + |
| 19 | +##Build |
| 20 | + |
| 21 | +###Step 1. Add the JitPack repository to your build file |
| 22 | + |
| 23 | +####Add it in your root build.gradle at the end of repositories: |
| 24 | + |
| 25 | + allprojects { |
| 26 | + repositories { |
| 27 | + ... |
| 28 | + maven { url 'https://jitpack.io' } |
| 29 | + } |
| 30 | + } |
| 31 | + |
| 32 | +####Step 2. Add the dependency |
| 33 | + |
| 34 | + dependencies { |
| 35 | + compile 'com.github.Ayvytr:AndroidEasyDeveloper:1.1.0' |
| 36 | + } |
| 37 | + |
| 38 | + |
| 39 | +##Contains |
| 40 | + |
| 41 | +###Resource |
| 42 | + Dp and sp from 0 to 100 |
| 43 | + Some styles about TextView, etc. |
| 44 | + |
| 45 | + |
| 46 | +###Custom View (About TextView aren't very useful) |
| 47 | + |
| 48 | + CenterGravityTextView |
| 49 | + LeftCenterGravityTextView |
| 50 | + RightCenterGravityTextView |
| 51 | + |
| 52 | + SeekBarPressure: double Thumb SeekBar |
| 53 | + |
| 54 | +###Tool classes with out Context |
| 55 | + Convert: Type conversion class, modeled on the C# Convert class (for this |
| 56 | + kind of love have alone bell) |
| 57 | + Provides most of the basic types to bool, int, byte conversion, and isZero method |
| 58 | + toBool |
| 59 | + izZero |
| 60 | + toInt |
| 61 | + toByte |
| 62 | + |
| 63 | + EncodeTool Encoding and decoding related operation class |
| 64 | + urlEncode |
| 65 | + urlDecode |
| 66 | + base64Encode |
| 67 | + base64Decode |
| 68 | + base64UrlSafeEncode |
| 69 | + htmlEncode |
| 70 | + htmlDecode |
| 71 | + |
| 72 | + EncryptTool Encryption and decryption related operations |
| 73 | + encryptMD2ToString |
| 74 | + encryptMD2 |
| 75 | + encryptMD5ToString |
| 76 | + encryptMD5 |
| 77 | + encryptSHA1ToString |
| 78 | + encryptSHA1 |
| 79 | + encryptSHA224ToString |
| 80 | + encryptSHA224 |
| 81 | + encryptSHA256ToString |
| 82 | + encryptSHA256 |
| 83 | + encryptSHA384ToString |
| 84 | + encryptSHA384 |
| 85 | + encryptSHA512ToString |
| 86 | + encryptSHA512 |
| 87 | + hashTemplate |
| 88 | + encryptHmacMD5ToString |
| 89 | + encryptHmacMD5 |
| 90 | + encryptHmacSHA1ToString |
| 91 | + encryptHmacSHA1 |
| 92 | + encryptHmacSHA224ToString |
| 93 | + encryptHmacSHA224 |
| 94 | + encryptHmacSHA256ToString |
| 95 | + encryptHmacSHA256 |
| 96 | + encryptHmacSHA384ToString |
| 97 | + encryptHmacSHA384 |
| 98 | + encryptHmacSHA512ToString |
| 99 | + encryptHmacSHA512 |
| 100 | + hmacTemplate |
| 101 | + encryptDES2Base64 |
| 102 | + encryptDES2HexString |
| 103 | + encryptDES |
| 104 | + decryptBase64DES |
| 105 | + decryptHexStringDES |
| 106 | + decryptDES |
| 107 | + encrypt3DES2Base64 |
| 108 | + encrypt3DES2HexString |
| 109 | + encrypt3DES |
| 110 | + decryptBase64_3DES |
| 111 | + decryptHexString3DES |
| 112 | + decrypt3DES |
| 113 | + encryptAES2Base64 |
| 114 | + encryptAES2HexString |
| 115 | + encryptAES |
| 116 | + decryptBase64AES |
| 117 | + decryptHexStringAES |
| 118 | + decryptAES |
| 119 | + desTemplate |
| 120 | + bytes2HexString |
| 121 | + hexString2Bytes |
| 122 | + hex2Dec |
| 123 | + base64Encode |
| 124 | + base64Decode |
| 125 | + |
| 126 | + FileTool File operation class, judgment is not a file / directory, is it present, |
| 127 | + rename, create file / directory, list / search file, get file name / file |
| 128 | + title (not including extension), there is no extension, |
| 129 | + read / write Documents and other methods |
| 130 | + fromName |
| 131 | + isExists |
| 132 | + rename |
| 133 | + isDir |
| 134 | + isFile |
| 135 | + createDir |
| 136 | + createFile |
| 137 | + listFilesInDir |
| 138 | + listFilesInDirWithFilter |
| 139 | + searchFileInDir |
| 140 | + writeFile |
| 141 | + write |
| 142 | + readFile |
| 143 | + read |
| 144 | + getByteArray |
| 145 | + getLastModified |
| 146 | + getName |
| 147 | + getTitle |
| 148 | + getExtension |
| 149 | + hasExtension |
| 150 | + isTyped |
| 151 | + |
| 152 | + RegexTool Regular tool classes, including verification of mobile phone number, |
| 153 | + mailbox, ID number and so on |
| 154 | + isMobileSimple |
| 155 | + isMobileExact |
| 156 | + isTel |
| 157 | + isIDCard15 |
| 158 | + isIDCard18 |
| 159 | + isEmail |
| 160 | + isURL |
| 161 | + isZh |
| 162 | + isUsername |
| 163 | + isDate |
| 164 | + isIP |
| 165 | + isMatch |
| 166 | + getMatches |
| 167 | + getSplits |
| 168 | + getReplaceFirst |
| 169 | + getReplaceAll |
| 170 | + |
| 171 | + TextTool Provides a number of string manipulation functions, including sentenced, |
| 172 | + is not a string, segmentation string (will remove the end of the regex) |
| 173 | + and other functions |
| 174 | + isEmpty |
| 175 | + isDigit |
| 176 | + isNumber |
| 177 | + reverse |
| 178 | + emptyString |
| 179 | + split |
| 180 | + isBlank |
| 181 | + |
| 182 | +###Tool classes with Context |
| 183 | + Easy The library of the single case of the import class, to use the Context |
| 184 | + classes, you need to initialize this class |
| 185 | + getContext |
| 186 | + checkInitState |
| 187 | + getDefault |
| 188 | + init |
| 189 | + release |
| 190 | + getClipboardManager |
| 191 | + getWindowManager |
| 192 | + getKeyguardManager |
| 193 | + |
| 194 | + BarTool About StatusBar, ActionBar peration tool class |
| 195 | + setColor |
| 196 | + setColorForSwipeBack |
| 197 | + setColorNoTranslucent |
| 198 | + setColorDiff |
| 199 | + setTranslucent |
| 200 | + setTranslucentForCoordinatorLayout |
| 201 | + setTransparent |
| 202 | + setTranslucentDiff |
| 203 | + setColorForDrawerLayout |
| 204 | + setColorNoTranslucentForDrawerLayout |
| 205 | + setColorForDrawerLayout |
| 206 | + setColorForDrawerLayoutDiff |
| 207 | + setTranslucentForDrawerLayout |
| 208 | + setTranslucentForDrawerLayoutDiff |
| 209 | + setTransparentForImageView |
| 210 | + setTranslucentForImageViewInFragment |
| 211 | + clearPreviousSetting |
| 212 | + addTranslucentView |
| 213 | + createStatusBarView |
| 214 | + setRootView |
| 215 | + setTransparentForWindow |
| 216 | + transparentStatusBar |
| 217 | + createTranslucentStatusBarView |
| 218 | + getStatusBarHeight |
| 219 | + calculateStatusColor |
| 220 | + setTransparentStatusBar |
| 221 | + hideStatusBar |
| 222 | + isStatusBarExists |
| 223 | + getActionBarHeight |
| 224 | + showNotificationBar |
| 225 | + hideNotificationBar |
| 226 | + invokePanels |
| 227 | + |
| 228 | + ClipboardTool Clipboard operation class |
| 229 | + setText |
| 230 | + getText |
| 231 | + getText |
| 232 | + setUri |
| 233 | + getUri |
| 234 | + setIntent |
| 235 | + getIntent |
| 236 | + |
| 237 | + DensityTool The Dp - Px transformation class provides three types of |
| 238 | + overloaded methods, int, float, and double, that minimize |
| 239 | + external casts. |
| 240 | + px2dp |
| 241 | + dp2px |
| 242 | + |
| 243 | + IntentTool Get the usual Intent. |
| 244 | + getInstallAppIntent |
| 245 | + getUninstallAppIntent |
| 246 | + getLaunchAppIntent |
| 247 | + getAppDetailsSettingsIntent |
| 248 | + getShareTextIntent |
| 249 | + getShareImageIntent |
| 250 | + getComponentIntent |
| 251 | + getShutdownIntent |
| 252 | + getDialIntent |
| 253 | + getCallIntent |
| 254 | + getSendSmsIntent |
| 255 | + getCaptureIntent |
| 256 | + |
| 257 | + ResTool Get the Drawable, String, dimension, color, Configuration in the resource. |
| 258 | + getDrawable |
| 259 | + getString |
| 260 | + getDimen |
| 261 | + getDimenFloat |
| 262 | + getDimenToDp |
| 263 | + getDimenFloatToDp |
| 264 | + getColor |
| 265 | + getConfiguration |
| 266 | + |
| 267 | + ScreenTool Provides the screen size, width, screen rotation direction, set to |
| 268 | + vertical screen, is not horizontal / vertical screen, get |
| 269 | + screenshots (include StatusBar or not), screen is locked or not. |
| 270 | + getDisplayMetrics |
| 271 | + getScreenWidth |
| 272 | + getScreenHeight |
| 273 | + setLandscape |
| 274 | + setPortrait |
| 275 | + isLandscape |
| 276 | + isPortrait |
| 277 | + getScreenRotationAngle |
| 278 | + getRotationAngle |
| 279 | + captureWithStatusBar |
| 280 | + captureWithoutStatusBar |
| 281 | + isScreenLock |
| 282 | + |
| 283 | + ToastTool The Toast tool class provides easy Toast creation and output capabilities. |
| 284 | + make |
| 285 | + makeLong |
| 286 | + show |
| 287 | + showLong |
| 288 | + |
| 289 | + |
| 290 | + |
| 291 | + |
| 292 | +###Quote below, thanks for their libraries |
| 293 | +1. https://github.com/Blankj/AndroidUtilCode |
| 294 | +2. https://github.com/Trinea/android-common |
| 295 | +3. https://github.com/wyouflf/xUtils3 |
| 296 | +4. https://github.com/jingle1267/android-utils |
| 297 | + |
| 298 | +###TODO: |
| 299 | +1. Complements Convert class |
| 300 | +2. Create my PrettyVideoPlayer |
| 301 | +3. Complements my library |
| 302 | +4. Personal website |
| 303 | +5. Separate Android and Java code |
| 304 | +6. Publish to JCenter |
0 commit comments