All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.googlenative.vmmigration.v1.kotlin.outputs.StatusResponse.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.googlenative.vmmigration.v1.kotlin.outputs

import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.collections.List
import kotlin.collections.Map

/**
 * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).
 * @property code The status code, which should be an enum value of google.rpc.Code.
 * @property details A list of messages that carry the error details. There is a common set of message types for APIs to use.
 * @property message A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
 */
public data class StatusResponse(
    public val code: Int,
    public val details: List>,
    public val message: String,
) {
    public companion object {
        public fun toKotlin(javaType: com.pulumi.googlenative.vmmigration.v1.outputs.StatusResponse): StatusResponse = StatusResponse(
            code = javaType.code(),
            details = javaType.details().map({ args0 ->
                args0.map({ args0 ->
                    args0.key.to(args0.value)
                }).toMap()
            }),
            message = javaType.message(),
        )
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy