Skip to content

Commit

Permalink
Generated updated documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
chRyNaN committed Sep 12, 2022
1 parent 8cb6cc6 commit 57c755d
Show file tree
Hide file tree
Showing 71 changed files with 531 additions and 167 deletions.
1 change: 1 addition & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
|---|
| [logger-android-timber](logger-android-timber/index.md) | |
| [logger-core](logger-core/index.md) | |
| [logger-ktor-client](logger-ktor-client/index.md) | |
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@
[androidJvm]\
abstract class [TimberLogger](index.md) : [LogInitializer](../../../../logger-core/logger-core/com.chrynan.logger/-log-initializer/index.md), [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md)

## Constructors

| | |
|---|---|
| [TimberLogger](-timber-logger.md) | [androidJvm]<br>fun [TimberLogger](-timber-logger.md)() |

## Functions

| Name | Summary |
|---|---|
| [debug](index.md#528699424%2FFunctions%2F1672300378) | [androidJvm]<br>open fun [debug](index.md#528699424%2FFunctions%2F1672300378)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [error](index.md#-1522606379%2FFunctions%2F1672300378) | [androidJvm]<br>open fun [error](index.md#-1522606379%2FFunctions%2F1672300378)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [info](index.md#1308495187%2FFunctions%2F1672300378) | [androidJvm]<br>open fun [info](index.md#1308495187%2FFunctions%2F1672300378)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [init](index.md#1639196271%2FFunctions%2F1672300378) | [androidJvm]<br>abstract fun [init](index.md#1639196271%2FFunctions%2F1672300378)() |
| [log](log.md) | [androidJvm]<br>open override fun [log](log.md)(logType: [LogType](../../../../logger-core/logger-core/com.chrynan.logger/-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [verbose](index.md#-736659633%2FFunctions%2F1672300378) | [androidJvm]<br>open fun [verbose](index.md#-736659633%2FFunctions%2F1672300378)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [warning](index.md#1679762281%2FFunctions%2F1672300378) | [androidJvm]<br>open fun [warning](index.md#1679762281%2FFunctions%2F1672300378)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [wtf](index.md#-1842084362%2FFunctions%2F1672300378) | [androidJvm]<br>open fun [wtf](index.md#-1842084362%2FFunctions%2F1672300378)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |

## Properties

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
//[logger-core](../../../index.md)/[com.chrynan.logger](../index.md)/[AsyncLogger](index.md)/[AsyncLogger](-async-logger.md)

# AsyncLogger

[common]\
fun [AsyncLogger](-async-logger.md)()
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
//[logger-core](../../../index.md)/[com.chrynan.logger](../index.md)/[AsyncLogger](index.md)

# AsyncLogger

[common]\
abstract class [AsyncLogger](index.md) : [Logger](../-logger/index.md)

An abstract class implementation of the [Logger](../-logger/index.md) interface allowing for use of kotlin coroutines and suspend functions. This effectively allows for asynchronous logging of messages.

Example usage:

```kotlin
class MyAsyncLogger(
override val coroutineScope: CoroutineScope,
private val api: Api
) : AsyncLogger() {

override suspend fun logAsync(logType: LogType, tag: String, message: String?, throwable: Throwable?) {
api.logMessage(message).await()
}
}
```

## Constructors

| | |
|---|---|
| [AsyncLogger](-async-logger.md) | [common]<br>fun [AsyncLogger](-async-logger.md)() |

## Functions

| Name | Summary |
|---|---|
| [log](log.md) | [common]<br>override fun [log](log.md)(logType: [LogType](../-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?)<br>Performs the action to log the provided details. |

## Properties

| Name | Summary |
|---|---|
| [isEnabled](is-enabled.md) | [common]<br>open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = false<br>Determines whether this [Logger](../-logger/index.md) instance should be used to output logs. The default value is up to the implementation and platform, but generally should be `false` to prevent accidental logging in a production environment. Explicitly set the value to be certain whether logging is enabled or not. |
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
//[logger-core](../../../index.md)/[com.chrynan.logger](../index.md)/[AsyncLogger](index.md)/[isEnabled](is-enabled.md)

# isEnabled

[common]\
open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = false

Determines whether this [Logger](../-logger/index.md) instance should be used to output logs. The default value is up to the implementation and platform, but generally should be `false` to prevent accidental logging in a production environment. Explicitly set the value to be certain whether logging is enabled or not.

**Note:** that it is up to the [Logger](../-logger/index.md) implementation to prevent logging if this value returns `false`.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
//[logger-core](../../../index.md)/[com.chrynan.logger](../index.md)/[AsyncLogger](index.md)/[log](log.md)

# log

[common]\
override fun [log](log.md)(logType: [LogType](../-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?)

Performs the action to log the provided details.
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,21 @@
[js]\
open class [ConsoleLogger](index.md) : [LogInitializer](../../../../logger-core/logger-core/com.chrynan.logger/-log-initializer/index.md), [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md)

## Constructors

| | |
|---|---|
| [ConsoleLogger](-console-logger.md) | [js]<br>fun [ConsoleLogger](-console-logger.md)() |

## Functions

| Name | Summary |
|---|---|
| [debug](index.md#528699424%2FFunctions%2F332244294) | [js]<br>open fun [debug](index.md#528699424%2FFunctions%2F332244294)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [error](index.md#-1522606379%2FFunctions%2F332244294) | [js]<br>open fun [error](index.md#-1522606379%2FFunctions%2F332244294)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [info](index.md#1308495187%2FFunctions%2F332244294) | [js]<br>open fun [info](index.md#1308495187%2FFunctions%2F332244294)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [init](init.md) | [js]<br>open override fun [init](init.md)() |
| [log](log.md) | [js]<br>open override fun [log](log.md)(logType: [LogType](../../../../logger-core/logger-core/com.chrynan.logger/-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [verbose](index.md#-736659633%2FFunctions%2F332244294) | [js]<br>open fun [verbose](index.md#-736659633%2FFunctions%2F332244294)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [warning](index.md#1679762281%2FFunctions%2F332244294) | [js]<br>open fun [warning](index.md#1679762281%2FFunctions%2F332244294)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [wtf](index.md#-1842084362%2FFunctions%2F332244294) | [js]<br>open fun [wtf](index.md#-1842084362%2FFunctions%2F332244294)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [log](log.md) | [js]<br>open override fun [log](log.md)(logType: [LogType](../../../../logger-core/logger-core/com.chrynan.logger/-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?)<br>Performs the action to log the provided details. |

## Properties

| Name | Summary |
|---|---|
| [isEnabled](is-enabled.md) | [js]<br>open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = true<br>Determines whether this [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md) instance should be used to output logs. This value should default to true. |
| [isEnabled](is-enabled.md) | [js]<br>open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = false<br>Determines whether this [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md) instance should be used to output logs. The default value is up to the implementation and platform, but generally should be `false` to prevent accidental logging in a production environment. Explicitly set the value to be certain whether logging is enabled or not. |
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
# isEnabled

[js]\
open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = true
open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = false

Determines whether this [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md) instance should be used to output logs. This value should default to true.
Determines whether this [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md) instance should be used to output logs. The default value is up to the implementation and platform, but generally should be `false` to prevent accidental logging in a production environment. Explicitly set the value to be certain whether logging is enabled or not.

**Note:** that it is up to the call-site to prevent logging if this value returns false.
**Note:** that it is up to the [Logger](../../../../logger-core/logger-core/com.chrynan.logger/-logger/index.md) implementation to prevent logging if this value returns `false`.
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@

[js]\
open override fun [log](log.md)(logType: [LogType](../../../../logger-core/logger-core/com.chrynan.logger/-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?)

Performs the action to log the provided details.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
//[logger-core](../../../index.md)/[com.chrynan.logger](../index.md)/[DelegatingLogger](index.md)/[equals](equals.md)

# equals

[common]\
open operator override fun [equals](equals.md)(other: [Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)?): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
//[logger-core](../../../index.md)/[com.chrynan.logger](../index.md)/[DelegatingLogger](index.md)/[hashCode](hash-code.md)

# hashCode

[common]\
open override fun [hashCode](hash-code.md)(): [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# DelegatingLogger

[common]\
class [DelegatingLogger](index.md)(loggers: [Set](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html)&lt;[Logger](../-logger/index.md)&gt;, delegateIsEnabledChanges: [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)) : [Logger](../-logger/index.md), [LogInitializer](../-log-initializer/index.md)
class [DelegatingLogger](index.md)(loggers: [Set](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html)&lt;[Logger](../-logger/index.md)&gt;, delegateIsEnabledChanges: [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = false) : [Logger](../-logger/index.md), [LogInitializer](../-log-initializer/index.md)

A [Logger](../-logger/index.md) implementation that delegates to the provided [loggers](../../../../logger-core/com.chrynan.logger/-delegating-logger/loggers.md). This allows for using multiple [Logger](../-logger/index.md)s.

Expand All @@ -17,17 +17,14 @@ A [Logger](../-logger/index.md) implementation that delegates to the provided [l

| Name | Summary |
|---|---|
| [debug](../-logger/debug.md) | [common]<br>open fun [debug](../-logger/debug.md)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [error](../-logger/error.md) | [common]<br>open fun [error](../-logger/error.md)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [info](../-logger/info.md) | [common]<br>open fun [info](../-logger/info.md)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [equals](equals.md) | [common]<br>open operator override fun [equals](equals.md)(other: [Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)?): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) |
| [hashCode](hash-code.md) | [common]<br>open override fun [hashCode](hash-code.md)(): [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) |
| [init](init.md) | [common]<br>open override fun [init](init.md)() |
| [log](log.md) | [common]<br>open override fun [log](log.md)(logType: [LogType](../-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?) |
| [verbose](../-logger/verbose.md) | [common]<br>open fun [verbose](../-logger/verbose.md)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [warning](../-logger/warning.md) | [common]<br>open fun [warning](../-logger/warning.md)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [wtf](../-logger/wtf.md) | [common]<br>open fun [wtf](../-logger/wtf.md)(message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)? = null, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)? = null) |
| [log](log.md) | [common]<br>open override fun [log](log.md)(logType: [LogType](../-log-type/index.md), tag: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html), message: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?, throwable: [Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)?)<br>Performs the action to log the provided details. |
| [toString](to-string.md) | [common]<br>open override fun [toString](to-string.md)(): [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |

## Properties

| Name | Summary |
|---|---|
| [isEnabled](is-enabled.md) | [common]<br>open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = true<br>Determines whether this [Logger](../-logger/index.md) instance should be used to output logs. This value should default to true. |
| [isEnabled](is-enabled.md) | [common]<br>open override var [isEnabled](is-enabled.md): [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) = false<br>Determines whether this [Logger](../-logger/index.md) instance should be used to output logs. The default value is up to the implementation and platform, but generally should be `false` to prevent accidental logging in a production environment. Explicitly set the value to be certain whether logging is enabled or not. |
Loading

0 comments on commit 57c755d

Please sign in to comment.