/
vapp_types.go
29 lines (24 loc) · 1.08 KB
/
vapp_types.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
package vapp
import (
supertypes "github.com/FrangipaneTeam/terraform-plugin-framework-supertypes"
"github.com/orange-cloudavenue/terraform-provider-cloudavenue/pkg/utils"
)
type (
vappResourceModel struct {
VAppName supertypes.StringValue `tfsdk:"name"`
VAppID supertypes.StringValue `tfsdk:"id"`
VDC supertypes.StringValue `tfsdk:"vdc"`
Description supertypes.StringValue `tfsdk:"description"`
GuestProperties supertypes.MapValue `tfsdk:"guest_properties"`
Lease supertypes.SingleNestedObjectValueOf[vappResourceModelLease] `tfsdk:"lease"`
}
vappResourceModelLease struct {
RuntimeLeaseInSec supertypes.Int64Value `tfsdk:"runtime_lease_in_sec"`
StorageLeaseInSec supertypes.Int64Value `tfsdk:"storage_lease_in_sec"`
}
)
func (rm *vappResourceModel) Copy() *vappResourceModel {
x := &vappResourceModel{}
utils.ModelCopy(rm, x)
return x
}