Slide 14
Slide 14 text
data class Coffee(
/**
* ex) espresso
*/
@field:WireField(tag = 1, adapter = "com.squareup.wire.ProtoAdapter#STRING")
val name: String? = null,
/**
* ex) 340
*/
@field:WireField(tag = 2, adapter = "com.squareup.wire.ProtoAdapter#DOUBLE")
val price: Double? = null,
/**
* ex) small / medium / large
*/
@field:WireField(tag = 3, adapter = "com.takusemba.proto.Size#ADAPTER")
val size: Size? = null,
/**
* ex) true / false
*/
@field:WireField(tag = 4, adapter = "com.squareup.wire.ProtoAdapter#BOOL")
val isAvailable: Boolean? = null,
val unknownFields: ByteString = ByteString.EMPTY
) : Message(ADAPTER, unknownFields) {
…
}
val name: String? = null,
val price: Double? = null,
val size: Size? = null,
val isAvailable: Boolean? = null,