# dev.inmo.micro_utils.ktor.server

# Package-level declarations

## Types

TemporalFilesRoutingConfigurator
Link copied to clipboard
class TemporalFilesRoutingConfigurator (subpath: String = DefaultTemporalFilesSubPath, temporalFilesUtilizer: TemporalFilesRoutingConfigurator.TemporalFilesUtilizer = TemporalFilesUtilizer, filesFlowReplay: Int = 0, filesFlowExtraBufferCapacity: Int = Int.MAX_VALUE, filesFlowOnBufferOverflow: BufferOverflow = BufferOverflow.SUSPEND) : ApplicationRoutingConfigurator.Element

## Properties

extractFromToDateTime
Link copied to clipboard
val <Error class: unknown class>. extractFromToDateTime : FromToDateTime
standardKtorSerialFormatContentType
Link copied to clipboard
val standardKtorSerialFormatContentType : <Error class: unknown class>

## Functions

createKtorServer
Link copied to clipboard
fun createKtorServer (host: String = "localhost", port: Int = Random.nextInt(1024, 65535), additionalEngineEnvironmentConfigurator: <Error class: unknown class>.() -> Unit = {}, additionalConfigurationConfigurator: <Error class: unknown class>.() -> Unit = {}, environment: <Error class: unknown class> = applicationEnvironment(), block: <Error class: unknown class>.() -> Unit ): <Error class: unknown class><<Error class: unknown class>, <Error class: unknown class>>
fun createKtorServer (host: String = "localhost", port: Int = Random.nextInt(1024, 65535), configurators: List < KtorApplicationConfigurator >, additionalEngineEnvironmentConfigurator: <Error class: unknown class>.() -> Unit = {}, additionalConfigurationConfigurator: <Error class: unknown class>.() -> Unit = {}, environment: <Error class: unknown class> = applicationEnvironment()): <Error class: unknown class><<Error class: unknown class>, <Error class: unknown class>>

Create server with CIO server engine without starting of it

fun < TEngine , TConfiguration > createKtorServer (engine: <Error class: unknown class>< TEngine , TConfiguration >, host: String = "localhost", port: Int = Random.nextInt(1024, 65535), additionalEngineEnvironmentConfigurator: <Error class: unknown class>.() -> Unit = {}, additionalConfigurationConfigurator: TConfiguration .() -> Unit = {}, environment: <Error class: unknown class> = applicationEnvironment(), block: <Error class: unknown class>.() -> Unit ): <Error class: unknown class>< TEngine , TConfiguration >
fun < TEngine , TConfiguration > createKtorServer (engine: <Error class: unknown class>< TEngine , TConfiguration >, host: String = "localhost", port: Int = Random.nextInt(1024, 65535), additionalEngineEnvironmentConfigurator: <Error class: unknown class>.() -> Unit = {}, additionalConfigurationConfigurator: TConfiguration .() -> Unit = {}, environment: <Error class: unknown class> = applicationEnvironment(), configurators: List < KtorApplicationConfigurator >): <Error class: unknown class>< TEngine , TConfiguration >
download
Link copied to clipboard
suspend fun <Error class: unknown class>. download (target: File )
fun <Error class: unknown class>. download (target: File )
fun <Error class: unknown class>. download (target: File )
downloadToTemporalFile
Link copied to clipboard
suspend fun <Error class: unknown class>. downloadToTemporalFile (): File
fun <Error class: unknown class>. downloadToTemporalFile (): File
fun <Error class: unknown class>. downloadToTemporalFile (): File
getParameterOrSendError
Link copied to clipboard
suspend fun <Error class: unknown class>. getParameterOrSendError (field: String ): <Error class: unknown class>
getParametersOrSendError
Link copied to clipboard
suspend fun <Error class: unknown class>. getParametersOrSendError (field: String ): <Error class: unknown class>
getQueryParameter
Link copied to clipboard
fun <Error class: unknown class>. getQueryParameter (field: String ): <Error class: unknown class>
getQueryParameterOrSendError
Link copied to clipboard
suspend fun <Error class: unknown class>. getQueryParameterOrSendError (field: String ): <Error class: unknown class>
getQueryParameters
Link copied to clipboard
fun <Error class: unknown class>. getQueryParameters (field: String ): <Error class: unknown class>
getQueryParametersOrSendError
Link copied to clipboard
suspend fun <Error class: unknown class>. getQueryParametersOrSendError (field: String ): <Error class: unknown class>
handleUniUpload
Link copied to clipboard
inline suspend fun <Error class: unknown class>. handleUniUpload (onFormItem: (<Error class: unknown class>) -> Unit = {}, onBinaryContent: (<Error class: unknown class>) -> Unit = {}, onBinaryChannelItem: (<Error class: unknown class>) -> Unit = {}, onFileItem: (<Error class: unknown class>) -> Unit = {})

Server-side part which receives dev.inmo.micro_utils.ktor.client.uniUpload request

includeWebsocketHandling
Link copied to clipboard
inline fun < T : Any > <Error class: unknown class>. includeWebsocketHandling (suburl: String , flow: Flow< T >, protocol: <Error class: unknown class>? = null, noinline dataMapper: suspend <Error class: unknown class>.( T ) -> T ? = { it })
respondOrNoContent
Link copied to clipboard
inline suspend fun < T : Any > <Error class: unknown class>. respondOrNoContent (data: T ?)
uniloadMultipart
Link copied to clipboard
suspend fun <Error class: unknown class>. uniloadMultipart (onFormItem: (<Error class: unknown class>) -> Unit = {}, onCustomFileItem: (<Error class: unknown class>) -> Unit = {}, onBinaryChannelItem: (<Error class: unknown class>) -> Unit = {}, onBinaryContent: (<Error class: unknown class>) -> Unit = {}): <Error class: unknown class>
uniloadMultipartFile
Link copied to clipboard
suspend fun <Error class: unknown class>. uniloadMultipartFile (onFormItem: (<Error class: unknown class>) -> Unit = {}, onCustomFileItem: (<Error class: unknown class>) -> Unit = {}, onBinaryChannelItem: (<Error class: unknown class>) -> Unit = {}, onBinaryContent: (<Error class: unknown class>) -> Unit = {}): MPPFile