Package aws.smithy.kotlin.runtime.content
Types
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Container for wrapping a ByteArray as a ByteStream
Link copied to clipboard
Represents an abstract read-only stream of bytes
Link copied to clipboard
Link copied to clipboard
class FileContent( val file: File, val start: Long = 0, val endInclusive: Long = file.length() - 1) : ByteStream.SourceStream
Content copied to clipboard
ByteStream backed by a local file
Link copied to clipboard
Container for wrapping a String as a ByteStream
Functions
Link copied to clipboard
Create a ByteStream from a file with the given range
Create a ByteStream from a path with the given range
fun File.asByteStream(start: Long = 0, endInclusive: Long = length() - 1): ByteStream
Content copied to clipboard
Create a ByteStream from a file
fun Path.asByteStream(start: Long = 0, endInclusive: Long = -1): ByteStream
Content copied to clipboard
Create a ByteStream from a path
Link copied to clipboard
Builds a Document with the given builder.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Create a ByteStream from a file
Link copied to clipboard
Consume the ByteStream and pull the entire contents into memory as a ByteArray. Only do this if you are sure the contents fit in-memory as this will read the entire contents of a streaming variant.
Link copied to clipboard
Write the contents of this ByteStream to file and close it
Write the contents of this ByteStream to file at the given path