LocalFileContent

fun LocalFileContent(baseDir: File, relativePath: String, contentType: ContentType = ContentType.defaultForFilePath(relativePath)): LocalFileContent

Creates an instance of LocalFileContent for a file designated by relativePath in a baseDir


fun LocalFileContent(baseDir: Path, relativePath: Path, contentType: ContentType = ContentType.defaultForPath(relativePath)): LocalPathContent

Deprecated

Use LocalPathContent instead

Replace with

import io.ktor.server.http.content.LocalPathContent
LocalPathContent(baseDir, relativePath, contentType)

Creates an instance of LocalPathContent for a path designated by relativePath in a baseDir