Package loggersoft.kotlin.utils

Types

AbstractBuffer
Link copied to clipboard
abstract class AbstractBuffer
Represents abstract buffer for I/O operations.
BitEnumSet
Link copied to clipboard
data class BitEnumSet<T : Enum<T>>(map: Map<T, Int>, value: Int) : MutableSet<T>
Represents the mutable set of enumeration items mapped into a bit mask.
Cache
Link copied to clipboard
class Cache<K : Any, V> : Obtainable<K, V>
Represents cache with specific capacity and counter of access for each item.
CachedProperty
Link copied to clipboard
class CachedProperty<out T : Any, out E : Any>(instance: E, hint: CachedProperty.CacheHint, maker: E.() -> T)
Implementation of cached read-only property which based on another object.
IndexList
Link copied to clipboard
interface IndexList<out T> : Iterable<T>
Represents iterable read-only list with size and access by index.
IndexListIterator
Link copied to clipboard
class IndexListIterator<out T>(list: IndexList<T>) : Iterator<T>
Implementation of Iterator for IndexList.
IntegerFormatter
Link copied to clipboard
class IntegerFormatter(format: String)
Backend for formatting integers by string pattern.
Obtainable
Link copied to clipboard
interface Obtainable<in K : Any, out V>
Represents the ability of an object to returns value by key.
PropertyRange
Link copied to clipboard
class PropertyRange<T : Comparable<T>>(initValue: T, min: T?, max: T?, violation: (T, T) -> T)
Represents range validator for properties with comparable type (e.g.
StateTrackable
Link copied to clipboard
interface StateTrackable<out T : Any>
Represents interface to track an object state by revision.

Functions

bitEnumSetOf
Link copied to clipboard
inline fun <T : Enum<T>> bitEnumSetOf(vararg values: T): BitEnumSet<T>
Creates bit set for particular enum class with optional initial values.
defaultViolation
Link copied to clipboard
inline fun <T : Comparable<T>> defaultViolation(newValue: T, bound: T): T
Default violation handler.
enumSetEmpty
Link copied to clipboard
inline fun <T : Enum<T>> enumSetEmpty(): EnumSet<T>
Returns empty set of enumeration with the type specified by the template.
enumSetOf
Link copied to clipboard
inline fun <T : Enum<T>> enumSetOf(vararg values: T): EnumSet<T>
Creates an immutable set of values belong to enumeration with the type specified by the template.
exceptionViolation
Link copied to clipboard
inline fun <T : Comparable<T>> exceptionViolation(newValue: T, bound: T): T
Violation handler which throws an exception IllegalArgumentException.
get
Link copied to clipboard
inline operator fun BigInteger.get(format: String): String
Returns string representation of BigInteger according to format.
inline operator fun Int.get(format: String): String
Returns string representation of Int according to format.
inline operator fun Long.get(format: String): String
Returns string representation of Long according to format.
inline operator fun UInt.get(format: String): String
Returns string representation of UInt according to format.
inline operator fun ULong.get(format: String): String
Returns string representation of ULong according to format.
repeat
Link copied to clipboard
inline fun Int.repeat(body: (index: Int) -> Unit)
Repeats body code block this times.

Properties

Empty
Link copied to clipboard
val String.Companion.Empty: String
Static empty string constant in String.
EMPTY_STRING
Link copied to clipboard
const val EMPTY_STRING: String
Empty string constant.