170 lines
4.7 KiB
Go
170 lines
4.7 KiB
Go
/*
|
|
STACKIT Key Management Service API
|
|
|
|
### DEPRECATED! This service is no longer maintained. Please use the version v1 instead. This API provides endpoints for managing keys and key rings.
|
|
|
|
API version: 1beta.0.0
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package kmsbeta
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// checks if the SignedData type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &SignedData{}
|
|
|
|
/*
|
|
types and functions for data
|
|
*/
|
|
|
|
// isByteArray
|
|
type SignedDataGetDataAttributeType = *[]byte
|
|
type SignedDataGetDataArgType = []byte
|
|
type SignedDataGetDataRetType = []byte
|
|
|
|
func getSignedDataGetDataAttributeTypeOk(arg SignedDataGetDataAttributeType) (ret SignedDataGetDataRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setSignedDataGetDataAttributeType(arg *SignedDataGetDataAttributeType, val SignedDataGetDataRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for signature
|
|
*/
|
|
|
|
// isByteArray
|
|
type SignedDataGetSignatureAttributeType = *[]byte
|
|
type SignedDataGetSignatureArgType = []byte
|
|
type SignedDataGetSignatureRetType = []byte
|
|
|
|
func getSignedDataGetSignatureAttributeTypeOk(arg SignedDataGetSignatureAttributeType) (ret SignedDataGetSignatureRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setSignedDataGetSignatureAttributeType(arg *SignedDataGetSignatureAttributeType, val SignedDataGetSignatureRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
// SignedData struct for SignedData
|
|
type SignedData struct {
|
|
// The data that was signed. Encoded in base64.
|
|
// REQUIRED
|
|
Data SignedDataGetDataAttributeType `json:"data" required:"true"`
|
|
// The signature of the data. Encoded in base64.
|
|
// REQUIRED
|
|
Signature SignedDataGetSignatureAttributeType `json:"signature" required:"true"`
|
|
}
|
|
|
|
type _SignedData SignedData
|
|
|
|
// NewSignedData instantiates a new SignedData object
|
|
// This constructor will assign default values to properties that have it defined,
|
|
// and makes sure properties required by API are set, but the set of arguments
|
|
// will change when the set of required properties is changed
|
|
func NewSignedData(data SignedDataGetDataArgType, signature SignedDataGetSignatureArgType) *SignedData {
|
|
this := SignedData{}
|
|
setSignedDataGetDataAttributeType(&this.Data, data)
|
|
setSignedDataGetSignatureAttributeType(&this.Signature, signature)
|
|
return &this
|
|
}
|
|
|
|
// NewSignedDataWithDefaults instantiates a new SignedData object
|
|
// This constructor will only assign default values to properties that have it defined,
|
|
// but it doesn't guarantee that properties required by API are set
|
|
func NewSignedDataWithDefaults() *SignedData {
|
|
this := SignedData{}
|
|
return &this
|
|
}
|
|
|
|
// GetData returns the Data field value
|
|
func (o *SignedData) GetData() (ret SignedDataGetDataRetType) {
|
|
ret, _ = o.GetDataOk()
|
|
return ret
|
|
}
|
|
|
|
// GetDataOk returns a tuple with the Data field value
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SignedData) GetDataOk() (ret SignedDataGetDataRetType, ok bool) {
|
|
return getSignedDataGetDataAttributeTypeOk(o.Data)
|
|
}
|
|
|
|
// SetData sets field value
|
|
func (o *SignedData) SetData(v SignedDataGetDataRetType) {
|
|
setSignedDataGetDataAttributeType(&o.Data, v)
|
|
}
|
|
|
|
// GetSignature returns the Signature field value
|
|
func (o *SignedData) GetSignature() (ret SignedDataGetSignatureRetType) {
|
|
ret, _ = o.GetSignatureOk()
|
|
return ret
|
|
}
|
|
|
|
// GetSignatureOk returns a tuple with the Signature field value
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SignedData) GetSignatureOk() (ret SignedDataGetSignatureRetType, ok bool) {
|
|
return getSignedDataGetSignatureAttributeTypeOk(o.Signature)
|
|
}
|
|
|
|
// SetSignature sets field value
|
|
func (o *SignedData) SetSignature(v SignedDataGetSignatureRetType) {
|
|
setSignedDataGetSignatureAttributeType(&o.Signature, v)
|
|
}
|
|
|
|
func (o SignedData) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if val, ok := getSignedDataGetDataAttributeTypeOk(o.Data); ok {
|
|
toSerialize["Data"] = val
|
|
}
|
|
if val, ok := getSignedDataGetSignatureAttributeTypeOk(o.Signature); ok {
|
|
toSerialize["Signature"] = val
|
|
}
|
|
return toSerialize, nil
|
|
}
|
|
|
|
type NullableSignedData struct {
|
|
value *SignedData
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableSignedData) Get() *SignedData {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableSignedData) Set(val *SignedData) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableSignedData) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableSignedData) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableSignedData(val *SignedData) *NullableSignedData {
|
|
return &NullableSignedData{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableSignedData) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableSignedData) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|