com.google.protobuf.TimestampKt.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of protobuf-kotlin-lite Show documentation
Show all versions of protobuf-kotlin-lite Show documentation
Kotlin lite Protocol Buffers library. Protocol Buffers are a way of encoding structured data in an
efficient yet extensible format.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: google/protobuf/timestamp.proto
// Generated files should ignore deprecation warnings
@file:Suppress("DEPRECATION")
package com.google.protobuf;
@kotlin.jvm.JvmName("-initializetimestamp")
public inline fun timestamp(block: com.google.protobuf.TimestampKt.Dsl.() -> kotlin.Unit): com.google.protobuf.Timestamp =
com.google.protobuf.TimestampKt.Dsl._create(com.google.protobuf.Timestamp.newBuilder()).apply { block() }._build()
/**
* Protobuf type `google.protobuf.Timestamp`
*/
public object TimestampKt {
@kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
@com.google.protobuf.kotlin.ProtoDslMarker
public class Dsl private constructor(
private val _builder: com.google.protobuf.Timestamp.Builder
) {
public companion object {
@kotlin.jvm.JvmSynthetic
@kotlin.PublishedApi
internal fun _create(builder: com.google.protobuf.Timestamp.Builder): Dsl = Dsl(builder)
}
@kotlin.jvm.JvmSynthetic
@kotlin.PublishedApi
internal fun _build(): com.google.protobuf.Timestamp = _builder.build()
/**
* int64 seconds = 1 [json_name = "seconds"];
*/
public var seconds: kotlin.Long
@JvmName("getSeconds")
get() = _builder.getSeconds()
@JvmName("setSeconds")
set(value) {
_builder.setSeconds(value)
}
/**
* `int64 seconds = 1 [json_name = "seconds"];`
*/
public fun clearSeconds() {
_builder.clearSeconds()
}
/**
* int32 nanos = 2 [json_name = "nanos"];
*/
public var nanos: kotlin.Int
@JvmName("getNanos")
get() = _builder.getNanos()
@JvmName("setNanos")
set(value) {
_builder.setNanos(value)
}
/**
* `int32 nanos = 2 [json_name = "nanos"];`
*/
public fun clearNanos() {
_builder.clearNanos()
}
}
}
public inline fun com.google.protobuf.Timestamp.copy(block: `com.google.protobuf`.TimestampKt.Dsl.() -> kotlin.Unit): com.google.protobuf.Timestamp =
`com.google.protobuf`.TimestampKt.Dsl._create(this.toBuilder()).apply { block() }._build()