mirror of
https://github.com/HighCapable/YukiReflection.git
synced 2025-09-06 02:35:40 +08:00
docs: update api-example
This commit is contained in:
@@ -42,10 +42,12 @@ Logs inside the API will be printed using this tag.
|
||||
```kotlin
|
||||
// Via the configs method
|
||||
YukiReflection.configs {
|
||||
debugTag = "YourCustomTag"
|
||||
debugLog {
|
||||
tag = "YourCustomTag"
|
||||
}
|
||||
}
|
||||
// Set directly
|
||||
YukiReflection.Configs.debugTag = "YourCustomTag"
|
||||
YLog.Configs.tag = "YourCustomTag"
|
||||
```
|
||||
|
||||
### Enable or Disable Debug Mode
|
||||
@@ -76,10 +78,12 @@ This function is enabled by default, and disable will stop `YukiReflection` outp
|
||||
```kotlin
|
||||
// Via the configs method
|
||||
YukiReflection.configs {
|
||||
isEnableLogs = true
|
||||
debugLog {
|
||||
isEnable = true
|
||||
}
|
||||
}
|
||||
// Set directly
|
||||
YukiReflection.Configs.isEnableLogs = true
|
||||
YLog.Configs.isEnable = true
|
||||
```
|
||||
|
||||
### Use the configs Method to Configure
|
||||
@@ -90,9 +94,11 @@ In order to configure multiple features at once, you can directly use the `YukiR
|
||||
|
||||
```kotlin
|
||||
YukiReflection.configs {
|
||||
debugTag = "YourCustomTag"
|
||||
debugLog {
|
||||
tag = "YourCustomTag"
|
||||
isEnable = true
|
||||
}
|
||||
isDebug = true
|
||||
isEnableLogs = true
|
||||
}
|
||||
```
|
||||
|
||||
|
@@ -42,10 +42,12 @@ API 内部的日志将会使用此标签进行打印。
|
||||
```kotlin
|
||||
// 通过 configs 方法
|
||||
YukiReflection.configs {
|
||||
debugTag = "YourCustomTag"
|
||||
debugLog {
|
||||
tag = "YourCustomTag"
|
||||
}
|
||||
}
|
||||
// 直接设置
|
||||
YukiReflection.Configs.debugTag = "YourCustomTag"
|
||||
YLog.Configs.tag = "YourCustomTag"
|
||||
```
|
||||
|
||||
### 启用或禁用 Debug 模式
|
||||
@@ -76,10 +78,12 @@ YukiReflection.Configs.isDebug = true
|
||||
```kotlin
|
||||
// 通过 configs 方法
|
||||
YukiReflection.configs {
|
||||
isEnableLogs = true
|
||||
debugLog {
|
||||
isEnable = true
|
||||
}
|
||||
}
|
||||
// 直接设置
|
||||
YukiReflection.Configs.isEnableLogs = true
|
||||
YLog.Configs.isEnable = true
|
||||
```
|
||||
|
||||
### 使用 configs 方法配置
|
||||
@@ -90,9 +94,11 @@ YukiReflection.Configs.isEnableLogs = true
|
||||
|
||||
```kotlin
|
||||
YukiReflection.configs {
|
||||
debugTag = "YourCustomTag"
|
||||
debugLog {
|
||||
tag = "YourCustomTag"
|
||||
isEnable = true
|
||||
}
|
||||
isDebug = true
|
||||
isEnableLogs = true
|
||||
}
|
||||
```
|
||||
|
||||
|
Reference in New Issue
Block a user