qisdk / com.aldebaran.qi.sdk.util / IOUtils

IOUtils

class IOUtils

Utility methods used for work raw files and assets

Functions

fromAsset

Returns a string from a asset file

static fun fromAsset(context: Context!, assetName: String!): String!

fromRaw

Returns a string from a raw file

static fun fromRaw(context: Context!, resId: Int): String!

readAllStream

Returns a string that represent the content of a stream

static fun readAllStream(is: InputStream!, charset: String!): String!

toByteArray

Returns a byte array that represent the content of the stream

static fun toByteArray(is: InputStream!): ByteArray!