Resource
representation of a resource, which can be loaded asynchronously or synchronously.
For the definition of a resource, see getResourceStream.
Since
1.1.6
See also
Inheritors
Constructors
Functions
Link copied to clipboard
load the given resource synchronously into a new byte array. you may then perform any operations on the result.
inline fun <T> load(errorHandler: (Throwable) -> T & Any = { throw it }, mapper: (ByteArray) -> T & Any): T
load the given resource synchronously, mapping to definitely non-nullable type T. you may then perform any operations on the result.
Link copied to clipboard
return the stream of this resource. it is the caller's responsibility to close the stream.