io.cloudevents.core.builder.cloudEventsExtensions.kt Maven / Gradle / Ivy
package io.cloudevents.core.builder
import org.http4k.core.ContentType
import org.http4k.core.Uri
import java.net.URI
@Suppress("UNCHECKED_CAST")
fun T.withDataContentType(contentType: ContentType): T = withDataContentType(contentType.value) as T
@Suppress("UNCHECKED_CAST")
fun T.withSource(uri: Uri): T = withSource(URI.create(uri.toString())) as T
@Suppress("UNCHECKED_CAST")
fun T.withDataSchema(uri: Uri): T = withDataSchema(URI.create(uri.toString())) as T
© 2015 - 2025 Weber Informatics LLC | Privacy Policy