v1

package
v0.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 15, 2023 License: MPL-2.0 Imports: 14 Imported by: 1

Documentation

Index

Constants

View Source
const (
	// VDCBillingModelPayAsYouGo - Pay as you go
	VDCBillingModelPayAsYouGo VDCBillingModel = "PAYG"
	// VDCBillingModelReserved - Reserved
	VDCBillingModelReserved VDCBillingModel = "RESERVED"
	// VDCBillingModelDraas - DRaaS
	VDCBillingModelDraas VDCBillingModel = "DRAAS"

	// VDCServiceClassStandard - Standard
	VDCServiceClassStandard VDCServiceClass = "STD"
	// VDCServiceClassEco - Eco
	VDCServiceClassEco VDCServiceClass = "ECO"
	// VDCServiceClassHP - HP
	VDCServiceClassHP VDCServiceClass = "HP"
	// VDCServiceClassVoIP - VoIP
	VDCServiceClassVoIP VDCServiceClass = "VOIP"

	// VDCDisponibilityClassOneRoom - One Room
	VDCDisponibilityClassOneRoom VDCDisponibilityClass = "ONE-ROOM"
	// VDCDisponibilityClassDualRoom - Dual Room
	VDCDisponibilityClassDualRoom VDCDisponibilityClass = "DUAL-ROOM"
	// VDCDisponibilityClassHADualRoom - HA Dual Room
	VDCDisponibilityClassHADualRoom VDCDisponibilityClass = "HA-DUAL-ROOM"

	// VDCStorageBillingModelPayAsYouGo - Pay as you go
	VDCStorageBillingModelPayAsYouGo VDCStorageBillingModel = "PAYG"
	// VDCStorageBillingModelReserved - Reserved
	VDCStorageBillingModelReserved VDCStorageBillingModel = "RESERVED"

	// VDCStrorageProfileClassSilver - Silver
	VDCStrorageProfileClassSilver VDCStrorageProfileClass = "silver"
	// VDCStrorageProfileClassSilverR1 - Silver R1
	VDCStrorageProfileClassSilverR1 VDCStrorageProfileClass = "silver_r1"
	// VDCStrorageProfileClassSilverR2 - Silver R2
	VDCStrorageProfileClassSilverR2 VDCStrorageProfileClass = "silver_r2"
	// VDCStrorageProfileClassGold - Gold
	VDCStrorageProfileClassGold VDCStrorageProfileClass = "gold"
	// VDCStrorageProfileClassGoldR1 - Gold R1
	VDCStrorageProfileClassGoldR1 VDCStrorageProfileClass = "gold_r1"
	// VDCStrorageProfileClassGoldR2 - Gold R2
	VDCStrorageProfileClassGoldR2 VDCStrorageProfileClass = "gold_r2"
	// VDCStrorageProfileClassGoldHm - Gold HM
	VDCStrorageProfileClassGoldHm VDCStrorageProfileClass = "gold_hm"
	// VDCStrorageProfileClassPlatinum3k - Platinum 3k
	VDCStrorageProfileClassPlatinum3k VDCStrorageProfileClass = "platinum3k"
	// VDCStrorageProfileClassPlatinum3kR1 - Platinum 3k R1
	VDCStrorageProfileClassPlatinum3kR1 VDCStrorageProfileClass = "platinum3k_r1"
	// VDCStrorageProfileClassPlatinum3kR2 - Platinum 3k R2
	VDCStrorageProfileClassPlatinum3kR2 VDCStrorageProfileClass = "platinum3k_r2"
	// VDCStrorageProfileClassPlatinum3kHm - Platinum 3k HM
	VDCStrorageProfileClassPlatinum3kHm VDCStrorageProfileClass = "platinum3k_hm"
	// VDCStrorageProfileClassPlatinum7k - Platinum 7k
	VDCStrorageProfileClassPlatinum7k VDCStrorageProfileClass = "platinum7k"
	// VDCStrorageProfileClassPlatinum7kR1 - Platinum 7k R1
	VDCStrorageProfileClassPlatinum7kR1 VDCStrorageProfileClass = "platinum7k_r1"
	// VDCStrorageProfileClassPlatinum7kR2 - Platinum 7k R2
	VDCStrorageProfileClassPlatinum7kR2 VDCStrorageProfileClass = "platinum7k_r2"
	// VDCStrorageProfileClassPlatinum7kHm - Platinum 7k HM
	VDCStrorageProfileClassPlatinum7kHm VDCStrorageProfileClass = "platinum7k_hm"
)

Variables

View Source
var (
	ErrVDCServiceClass         = fmt.Errorf("invalid service class value (Allowed values: %s, %s, %s, %s)", VDCServiceClassStandard, VDCServiceClassEco, VDCServiceClassHP, VDCServiceClassVoIP)
	ErrVDCBillingModel         = fmt.Errorf("invalid billing model value (Allowed values: %s, %s, %s)", VDCBillingModelPayAsYouGo, VDCBillingModelReserved, VDCBillingModelDraas)
	ErrVDCDisponibilityClass   = fmt.Errorf("invalid disponibility class value (Allowed values: %s, %s, %s)", VDCDisponibilityClassOneRoom, VDCDisponibilityClassDualRoom, VDCDisponibilityClassHADualRoom)
	ErrVDCStorageBillingModel  = fmt.Errorf("invalid storage billing model value (Allowed values: %s, %s)", VDCStorageBillingModelPayAsYouGo, VDCStorageBillingModelReserved)
	ErrVDCStrorageProfileClass = fmt.Errorf("invalid storage profile class value (Allowed values: %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)", VDCStrorageProfileClassSilver, VDCStrorageProfileClassSilverR1, VDCStrorageProfileClassSilverR2, VDCStrorageProfileClassGold, VDCStrorageProfileClassGoldR1, VDCStrorageProfileClassGoldR2, VDCStrorageProfileClassGoldHm, VDCStrorageProfileClassPlatinum3k, VDCStrorageProfileClassPlatinum3kR1, VDCStrorageProfileClassPlatinum3kR2, VDCStrorageProfileClassPlatinum3kHm, VDCStrorageProfileClassPlatinum7k, VDCStrorageProfileClassPlatinum7kR1, VDCStrorageProfileClassPlatinum7kR2, VDCStrorageProfileClassPlatinum7kHm)
)

Functions

func New

func New(edgeGatewayName string) (job *commoncloudavenue.JobStatus, err error)

New - Returns a new PublicIP

Types

type Bandwidth

type Bandwidth int

type CAVVDC

type CAVVDC struct{}

func (*CAVVDC) Get

func (v *CAVVDC) Get(vdcName string) (*CAVVirtualDataCenter, error)

Get VDC - Return the VDC Object

func (*CAVVDC) List

func (v *CAVVDC) List() (*CAVVDCs, error)

List - Return the list of VDCs

func (*CAVVDC) New

func (v *CAVVDC) New(value *CAVVirtualDataCenter) (vdc *CAVVirtualDataCenter, err error)

New - Create a new VDC

type CAVVDCs

type CAVVDCs []CAVVirtualDataCenter

type CAVVirtualDataCenter

type CAVVirtualDataCenter struct {
	VdcGroup string                  `json:"vdcGroup,omitempty"`
	Vdc      CAVVirtualDataCenterVDC `json:"vdc"`
}

func (*CAVVirtualDataCenter) AddStorageProfile

func (v *CAVVirtualDataCenter) AddStorageProfile(storageProfile VDCStrorageProfile)

AddStorageProfile - Add a storage profile

func (*CAVVirtualDataCenter) Delete

func (v *CAVVirtualDataCenter) Delete() (job *commoncloudavenue.JobStatus, err error)

Delete - Delete the VDC

func (*CAVVirtualDataCenter) GetBillingModel

func (v *CAVVirtualDataCenter) GetBillingModel() VDCBillingModel

GetBillingModel - Return the VDC billing model

func (*CAVVirtualDataCenter) GetCPUAllocated

func (v *CAVVirtualDataCenter) GetCPUAllocated() int

GetCPUAllocated - Return the VDC cpu allocated

func (*CAVVirtualDataCenter) GetDescription

func (v *CAVVirtualDataCenter) GetDescription() string

GetDescription - Return the VDC description

func (*CAVVirtualDataCenter) GetDisponibilityClass

func (v *CAVVirtualDataCenter) GetDisponibilityClass() VDCDisponibilityClass

GetDisponibilityClass - Return the VDC disponibility class

func (*CAVVirtualDataCenter) GetMemoryAllocated

func (v *CAVVirtualDataCenter) GetMemoryAllocated() int

GetMemoryAllocated - Return the VDC memory allocated

func (*CAVVirtualDataCenter) GetName

func (v *CAVVirtualDataCenter) GetName() string

GetName - Return the VDC name

func (*CAVVirtualDataCenter) GetServiceClass

func (v *CAVVirtualDataCenter) GetServiceClass() VDCServiceClass

GetServiceClass - Return the VDC service class

func (*CAVVirtualDataCenter) GetStorageBillingModel

func (v *CAVVirtualDataCenter) GetStorageBillingModel() VDCStorageBillingModel

GetStorageBillingModel - Return the VDC storage billing model

func (*CAVVirtualDataCenter) GetStorageProfiles

func (v *CAVVirtualDataCenter) GetStorageProfiles() []VDCStrorageProfile

GetStorageProfiles - Return the VDC storage profiles

func (*CAVVirtualDataCenter) GetVcpuInMhz2

func (v *CAVVirtualDataCenter) GetVcpuInMhz2() int

GetVcpuInMhz2 - Return the VDC vcpu in mhz2

func (*CAVVirtualDataCenter) GetVdcGroup

func (v *CAVVirtualDataCenter) GetVdcGroup() string

GetVdcGroup - Return the VDC vdc group

func (*CAVVirtualDataCenter) IsValid

func (v *CAVVirtualDataCenter) IsValid() (bool, error)

IsValid - Check if everythings is valid

func (*CAVVirtualDataCenter) MarshalJSON

func (v *CAVVirtualDataCenter) MarshalJSON() ([]byte, error)

MarshalJSON - Marshal the VDC

func (*CAVVirtualDataCenter) RemoveStorageProfile

func (v *CAVVirtualDataCenter) RemoveStorageProfile(storageProfile VDCStrorageProfile)

RemoveStorageProfile - Remove a storage profile

func (*CAVVirtualDataCenter) SetCPUAllocated

func (v *CAVVirtualDataCenter) SetCPUAllocated(cpuAllocated int)

SetCPUAllocated - Set the VDC cpu allocated

func (*CAVVirtualDataCenter) SetDescription

func (v *CAVVirtualDataCenter) SetDescription(description string)

SetDescription - Set the VDC description

func (*CAVVirtualDataCenter) SetMemoryAllocated

func (v *CAVVirtualDataCenter) SetMemoryAllocated(memoryAllocated int)

SetMemoryAllocated - Set the VDC memory allocated

func (*CAVVirtualDataCenter) SetName

func (v *CAVVirtualDataCenter) SetName(name string) error

SetName - Set the VDC name Name respects the following regex: ^[a-zA-Z0-9-_]{1,64}$

func (*CAVVirtualDataCenter) Update

func (v *CAVVirtualDataCenter) Update() (err error)

Update - Update the VDC

type CAVVirtualDataCenterVDC

type CAVVirtualDataCenterVDC struct {
	Name                string                 `json:"name"`
	Description         string                 `json:"description"`
	ServiceClass        VDCServiceClass        `json:"vdcServiceClass"`
	DisponibilityClass  VDCDisponibilityClass  `json:"vdcDisponibilityClass"`
	BillingModel        VDCBillingModel        `json:"vdcBillingModel"`
	VcpuInMhz2          int                    `json:"vcpuInMhz2"`
	CPUAllocated        int                    `json:"cpuAllocated"`
	MemoryAllocated     int                    `json:"memoryAllocated"`
	StorageBillingModel VDCStorageBillingModel `json:"vdcStorageBillingModel"`
	StorageProfiles     []VDCStrorageProfile   `json:"vdcStorageProfiles,omitempty"`
}

type ClassService

type ClassService string
const (
	// ClassServiceVRFStandard - VRF Standard
	ClassServiceVRFStandard ClassService = "VRF_STANDARD"
	// ClassServiceVRFPremium - VRF Premium
	ClassServiceVRFPremium ClassService = "VRF_PREMIUM"
)

func (ClassService) IsVRFPremium

func (c ClassService) IsVRFPremium() bool

IsVRFPremium - Returns true if the ClassService is VRFPremium

func (ClassService) IsVRFStandard

func (c ClassService) IsVRFStandard() bool

IsVRFStandard - Returns true if the ClassService is VRFStandard

type EdgeGateway

type EdgeGateway struct{}

func (*EdgeGateway) GetAllowedBandwidthValues

func (v *EdgeGateway) GetAllowedBandwidthValues(t0VrfName string) (allowedValues []int, err error)

GetAllowedBandwidthValues - Returns the allowed rate limit value

func (*EdgeGateway) GetByID

func (v *EdgeGateway) GetByID(edgeGatewayID string) (response *EdgeGw, err error)

GetByID - Returns the edge gateway ID ID format is UUID

func (*EdgeGateway) GetByName

func (v *EdgeGateway) GetByName(edgeGatewayName string) (response *EdgeGw, err error)

Get - Returns the edge gateway

func (*EdgeGateway) List

func (v *EdgeGateway) List() (response *EdgeGateways, err error)

List - Returns the list of edge gateways

func (*EdgeGateway) New

func (v *EdgeGateway) New(vdcName, tier0VrfName string) (job *commoncloudavenue.JobStatus, err error)

New - Creates a new edge gateway

func (*EdgeGateway) NewFromVDCGroup

func (v *EdgeGateway) NewFromVDCGroup(vdcGroupName, tier0VrfName string) (job *commoncloudavenue.JobStatus, err error)

NewFromVDCGroup - Creates a new edge gateway from a VDC Group

type EdgeGateways

type EdgeGateways []EdgeGw

func (*EdgeGateways) GetBandwidthCapacityRemaining

func (e *EdgeGateways) GetBandwidthCapacityRemaining(t0VrfName string) (response int, err error)

GetBandwidthCapacityRemaining - Returns the bandwidth capacity remaining in Mbps

type EdgeGw

type EdgeGw struct {
	Tier0VrfName string    `json:"tier0VrfId"`
	EdgeID       string    `json:"edgeId"`
	EdgeName     string    `json:"edgeName"`
	OwnerType    OwnerType `json:"ownerType"`
	OwnerName    string    `json:"ownerName"`
	Description  string    `json:"description"`
	Bandwidth    Bandwidth `json:"rateLimit"`
}

func (*EdgeGw) Delete

func (e *EdgeGw) Delete() (job *commoncloudavenue.JobStatus, err error)

Delete - Deletes the edge gateway

func (*EdgeGw) GetBandwidth

func (e *EdgeGw) GetBandwidth() Bandwidth

GetBandwidth - Returns the rate limit

func (*EdgeGw) GetDescription

func (e *EdgeGw) GetDescription() string

GetDescription - Returns the Description

func (*EdgeGw) GetID

func (e *EdgeGw) GetID() string

GetID - Returns the EdgeID

func (*EdgeGw) GetName

func (e *EdgeGw) GetName() string

GetName - Returns the EdgeName

func (*EdgeGw) GetOwnerName

func (e *EdgeGw) GetOwnerName() string

GetOwnerName - Returns the OwnerName

func (*EdgeGw) GetOwnerType

func (e *EdgeGw) GetOwnerType() OwnerType

GetOwnerType - Returns the OwnerType

func (*EdgeGw) GetT0

func (e *EdgeGw) GetT0() string

GetT0 - Returns the Tier0VrfID (alias)

func (*EdgeGw) GetTier0VrfID

func (e *EdgeGw) GetTier0VrfID() string

GetTier0VrfID - Returns the Tier0VrfID

func (*EdgeGw) ListNetworksType

func (e *EdgeGw) ListNetworksType() (response *NetworkTypes, err error)

ListNetworksType - Returns the list of networks by type configured on the edge gateway

func (*EdgeGw) UpdateBandwidth

func (e *EdgeGw) UpdateBandwidth(rateLimit int) (job *commoncloudavenue.JobStatus, err error)

UpdateBandwidth - Updates the bandwidth

type GetVAppMachinesResponse

type GetVAppMachinesResponse struct {
	Data []struct {
		IsVisibleToAllUsers       bool      `json:"IsVisibleToAllUsers,omitempty"`
		NetBackupClientName       string    `json:"NetBackupClientName,omitempty"`
		LastUpdatedDateTime       time.Time `json:"LastUpdatedDateTime,omitempty"`
		MachineCode               string    `json:"MachineCode,omitempty"`
		DisplayName               string    `json:"DisplayName,omitempty"`
		ProtectionTypeName        string    `json:"ProtectionTypeName,omitempty"`
		Hardware                  string    `json:"Hardware,omitempty"`
		TrafficLightStatus        string    `json:"TrafficLightStatus,omitempty"`
		IsSyncingNetBackupData    bool      `json:"IsSyncingNetBackupData,omitempty"`
		PolicyAppendix            string    `json:"PolicyAppendix,omitempty"`
		AdditionalData            string    `json:"AdditionalData,omitempty"`
		Os                        string    `json:"OS,omitempty"`
		ImportSource              string    `json:"ImportSource,omitempty"`
		CustomerCode              string    `json:"CustomerCode,omitempty"`
		ProviderAssetType         string    `json:"ProviderAssetType,omitempty"`
		IsDeletedFromImportSource bool      `json:"IsDeletedFromImportSource,omitempty"`
		VAppID                    int       `json:"VAppId,omitempty"`
		LastSuccessfulBackupDate  time.Time `json:"LastSuccessfulBackupDate,omitempty"`
		SyncLastError             string    `json:"SyncLastError,omitempty"`
		ProtectionTypeID          int       `json:"ProtectionTypeId,omitempty"`
		IsInVCloud                bool      `json:"IsInVCloud,omitempty"`
		Links                     []struct {
			Rel    string `json:"Rel,omitempty"`
			Href   string `json:"Href,omitempty"`
			Method string `json:"Method,omitempty"`
		} `json:"Links,omitempty"`
		CatalogName     string    `json:"CatalogName,omitempty"`
		ID              int       `json:"Id,omitempty"`
		VMDisplayName   string    `json:"VMDisplayName,omitempty"`
		CreatedDateTime time.Time `json:"CreatedDateTime,omitempty"`
		Location        string    `json:"Location,omitempty"`
	} `json:"Data,omitempty"`
}

GetVAppMachinesResponse - Is the response structure for the GetVAppMachines API

type IP

type IP struct {
	UplinkIP        string `json:"uplinkIp"`
	TranslatedIP    string `json:"translatedIp"`
	EdgeGatewayName string `json:"edgeGatewayName"`
}

func (*IP) Delete

func (i *IP) Delete() (job *commoncloudavenue.JobStatus, err error)

Delete - Deletes a public IP

func (*IP) GetIP

func (i *IP) GetIP() string

GetIP - Returns the public IP

type IPs

type IPs struct {
	InternalIP    string `json:"internalIp"`
	NetworkConfig []IP   `json:"networkConfig"`
}

type InventoryClient

type InventoryClient struct{}

func (*InventoryClient) Refresh

func (i *InventoryClient) Refresh() (job *commonnetbackup.JobAPIResponse, err error)

Refresh refreshes the inventory.

type Machine

type Machine struct {
	IsVisibleToAllUsers       bool      `json:"IsVisibleToAllUsers,omitempty"`
	NetBackupClientName       string    `json:"NetBackupClientName,omitempty"`
	LastUpdatedDateTime       time.Time `json:"LastUpdatedDateTime,omitempty"`
	MachineCode               string    `json:"MachineCode,omitempty"` // Is a URN in the form of urn:vcloud:vm:xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
	DisplayName               string    `json:"DisplayName,omitempty"`
	ProtectionTypeName        string    `json:"ProtectionTypeName,omitempty"`
	Hardware                  string    `json:"Hardware,omitempty"`
	TrafficLightStatus        string    `json:"TrafficLightStatus,omitempty"`
	IsSyncingNetBackupData    bool      `json:"IsSyncingNetBackupData,omitempty"`
	PolicyAppendix            string    `json:"PolicyAppendix,omitempty"`
	AdditionalData            string    `json:"AdditionalData,omitempty"`
	Os                        string    `json:"OS,omitempty"`
	ImportSource              string    `json:"ImportSource,omitempty"`
	CustomerCode              string    `json:"CustomerCode,omitempty"` // Is a Org Name
	ProviderAssetType         string    `json:"ProviderAssetType,omitempty"`
	IsDeletedFromImportSource bool      `json:"IsDeletedFromImportSource,omitempty"`
	VAppID                    int       `json:"VAppId,omitempty"`
	LastSuccessfulBackupDate  time.Time `json:"LastSuccessfulBackupDate,omitempty"`
	SyncLastError             string    `json:"SyncLastError,omitempty"`
	ProtectionTypeID          int       `json:"ProtectionTypeId,omitempty"`
	IsInVCloud                bool      `json:"IsInVCloud,omitempty"`
	CatalogName               string    `json:"CatalogName,omitempty"`
	ID                        int       `json:"Id,omitempty"`
	VMDisplayName             string    `json:"VMDisplayName,omitempty"` // Is a VM Name with suffix "-Random4Letters/Numbers" (e.g. "demo-4f5a")
	CreatedDateTime           time.Time `json:"CreatedDateTime,omitempty"`
	Location                  string    `json:"Location,omitempty"`
}

Machine - Is the response structure for the Machines APIs

func (*Machine) GetAdditionalData

func (m *Machine) GetAdditionalData() string

GetAdditionalData returns the AdditionalData field of Machine

func (*Machine) GetCatalogName

func (m *Machine) GetCatalogName() string

GetCatalogName returns the CatalogName field of Machine

func (*Machine) GetCreatedDateTime

func (m *Machine) GetCreatedDateTime() time.Time

GetCreatedDateTime returns the CreatedDateTime field of Machine

func (*Machine) GetCustomerCode

func (m *Machine) GetCustomerCode() string

GetCustomerCode returns the CustomerCode field of Machine

func (*Machine) GetDisplayName

func (m *Machine) GetDisplayName() string

GetDisplayName returns the DisplayName field of Machine

func (*Machine) GetHardware

func (m *Machine) GetHardware() string

GetHardware returns the Hardware field of Machine

func (*Machine) GetID

func (m *Machine) GetID() int

GetID returns the ID field of Machine

func (*Machine) GetIDPtr

func (m *Machine) GetIDPtr() *int

GetIDPtr returns a pointer to the ID field of Machine

func (*Machine) GetImportSource

func (m *Machine) GetImportSource() string

GetImportSource returns the ImportSource field of Machine

func (*Machine) GetIsDeletedFromImportSource

func (m *Machine) GetIsDeletedFromImportSource() bool

GetIsDeletedFromImportSource returns the IsDeletedFromImportSource field of Machine

func (*Machine) GetIsInVCloud

func (m *Machine) GetIsInVCloud() bool

GetIsInVCloud returns the IsInVCloud field of Machine

func (*Machine) GetIsSyncingNetBackupData

func (m *Machine) GetIsSyncingNetBackupData() bool

GetIsSyncingNetBackupData returns the IsSyncingNetBackupData field of Machine

func (*Machine) GetIsVisibleToAllUsers

func (m *Machine) GetIsVisibleToAllUsers() bool

GetIsVisibleToAllUsers returns the IsVisibleToAllUsers field of Machine

func (*Machine) GetLastSuccessfulBackupDate

func (m *Machine) GetLastSuccessfulBackupDate() time.Time

GetLastSuccessfulBackupDate returns the LastSuccessfulBackupDate field of Machine

func (*Machine) GetLastUpdatedDateTime

func (m *Machine) GetLastUpdatedDateTime() time.Time

GetLastUpdatedDateTime returns the LastUpdatedDateTime field of Machine

func (*Machine) GetLocation

func (m *Machine) GetLocation() string

GetLocation returns the Location field of Machine

func (*Machine) GetMachineCode

func (m *Machine) GetMachineCode() string

GetMachineCode returns the MachineCode field of Machine

func (*Machine) GetName

func (m *Machine) GetName() string

GetName returns the DisplayName field of Machine

func (*Machine) GetNetBackupClientName

func (m *Machine) GetNetBackupClientName() string

GetNetBackupClientName returns the NetBackupClientName field of Machine

func (*Machine) GetOs

func (m *Machine) GetOs() string

GetOs returns the Os field of Machine

func (*Machine) GetPolicyAppendix

func (m *Machine) GetPolicyAppendix() string

GetPolicyAppendix returns the PolicyAppendix field of Machine

func (*Machine) GetProtectionLevelAvailableByID

func (m *Machine) GetProtectionLevelAvailableByID(id int) (resp *ProtectionLevel, err error)

GetProtectionLevelAvailableByID - Get a protection level available for a Machine by ID

func (*Machine) GetProtectionLevelAvailableByName

func (m *Machine) GetProtectionLevelAvailableByName(name string) (resp *ProtectionLevel, err error)

GetProtectionLevelAvailableByName - Get a protection level available for a Machine by Name

func (*Machine) GetProtectionTypeID

func (m *Machine) GetProtectionTypeID() int

GetProtectionTypeID returns the ProtectionTypeID field of Machine

func (*Machine) GetProtectionTypeName

func (m *Machine) GetProtectionTypeName() string

GetProtectionTypeName returns the ProtectionTypeName field of Machine

func (*Machine) GetProviderAssetType

func (m *Machine) GetProviderAssetType() string

GetProviderAssetType returns the ProviderAssetType field of Machine

func (*Machine) GetSyncLastError

func (m *Machine) GetSyncLastError() string

GetSyncLastError returns the SyncLastError field of Machine

func (*Machine) GetTrafficLightStatus

func (m *Machine) GetTrafficLightStatus() string

GetTrafficLightStatus returns the TrafficLightStatus field of Machine

func (*Machine) GetVAppID

func (m *Machine) GetVAppID() int

GetVAppID returns the VAppID field of Machine

func (*Machine) GetVMDisplayName

func (m *Machine) GetVMDisplayName() string

GetVMDisplayName returns the VMDisplayName field of Machine

func (*Machine) ListProtectionLevels

func (m *Machine) ListProtectionLevels() (resp *ProtectionLevels, err error)

ListProtectionLevels - List the protection levels applied to a Machine

func (*Machine) ListProtectionLevelsAvailable

func (m *Machine) ListProtectionLevelsAvailable() (resp *ProtectionLevels, err error)

ListProtectionLevelsAvailable - List the protection levels available for a Machine

func (*Machine) Protect

Protect - Protect a Machine

func (*Machine) Unprotect

func (m *Machine) Unprotect(req ProtectUnprotectRequest) (job *commonnetbackup.JobAPIResponse, err error)

Unprotect - Unprotect a Machine

type MachineClient

type MachineClient struct{}

func (*MachineClient) GetMachineByID

func (m *MachineClient) GetMachineByID(id int) (resp *Machine, err error)

GetMachineByID - Get a NetBackup Machine by ID

func (*MachineClient) GetMachineByIdentifier

func (m *MachineClient) GetMachineByIdentifier(identifier string) (resp *Machine, err error)

GetMachineByIdentifier - Get a NetBackup Machine by Identifier

func (*MachineClient) GetMachineByName

func (m *MachineClient) GetMachineByName(name string) (resp *Machine, err error)

GetMachineByName - Get a NetBackup Machine by Name

func (*MachineClient) GetMachineByNameOrIdentifier

func (m *MachineClient) GetMachineByNameOrIdentifier(nameOrIdentifier string) (resp *Machine, err error)

GetMachineByNameOrIdentifier - Get a NetBackup Machine by Name or Identifier

func (*MachineClient) GetMachines

func (m *MachineClient) GetMachines() (resp *Machines, err error)

GetMachines - Get a list of NetBackup Machines

type Machines

type Machines []Machine

* Machines Machines - Is the response structure for the GetMachines API

type Netbackup

type Netbackup struct {
	VCloud          VCloudClient
	ProtectionLevel ProtectionLevelClient
	Machines        MachineClient
	Inventory       InventoryClient
}

type NetworkType

type NetworkType struct {
	Type         TypeOfNetwork `json:"networkType"`
	PrefixLength int           `json:"prefixLength"`
	StartAddress string        `json:"startAddress"`
}

func (NetworkType) GetEndAddress

func (n NetworkType) GetEndAddress() string

GetEndAddress - Returns the EndAddress

func (NetworkType) GetPrefixLength

func (n NetworkType) GetPrefixLength() int

GetPrefixLength - Returns the PrefixLength

func (NetworkType) GetStartAddress

func (n NetworkType) GetStartAddress() string

GetStartAddress - Returns the StartAddress

func (NetworkType) IsServiceZone

func (n NetworkType) IsServiceZone() bool

IsServiceZone - Returns true if the network type is ServiceZone

type NetworkTypes

type NetworkTypes []NetworkType

type OSEError added in v0.5.1

type OSEError struct {
	Status  OSEErrorStatus `json:"status"`
	Code    string         `json:"code"`
	Message string         `json:"message"`
}

func (*OSEError) Error added in v0.5.1

func (e *OSEError) Error() string

func (*OSEError) GetCode added in v0.5.1

func (e *OSEError) GetCode() string

func (*OSEError) GetMessage added in v0.5.1

func (e *OSEError) GetMessage() string

func (*OSEError) GetStatus added in v0.5.1

func (e *OSEError) GetStatus() OSEErrorStatus

func (*OSEError) IsNotFountError added in v0.5.1

func (e *OSEError) IsNotFountError() bool

IsNotFountError returns true if the error is a 404 error

type OSEErrorStatus added in v0.5.1

type OSEErrorStatus int

type Org

type Org struct {
	ID           int    `json:"Id"`
	Name         string `json:"Name"`
	DisplayName  string `json:"DisplayName"`
	CustomerCode string `json:"CustomerCode"`
	ImportSource string `json:"ImportSource"`
	Location     string `json:"Location"`
}

func (*Org) GetCustomerCode

func (r *Org) GetCustomerCode() string

GetCustomerCode returns the CustomerCode field of Org

func (*Org) GetDisplayName

func (r *Org) GetDisplayName() string

GetDisplayName returns the DisplayName field of Org

func (*Org) GetID

func (r *Org) GetID() int

GetID returns the ID field of Org

func (*Org) GetIDPtr

func (r *Org) GetIDPtr() *int

GetIDPtr returns a pointer to the ID field of Org

func (*Org) GetImportSource

func (r *Org) GetImportSource() string

GetImportSource returns the ImportSource field of Org

func (*Org) GetLocation

func (r *Org) GetLocation() string

GetLocation returns the Location field of Org

func (*Org) GetName

func (r *Org) GetName() string

GetName returns the Name field of Org

type Orgs

type Orgs []Org

* Orgs Orgs - Is the response structure for the GetOrgs API

type OwnerType

type OwnerType string
const (
	OwnerVDC OwnerType = "vdc"
)

func (OwnerType) IsVDC

func (o OwnerType) IsVDC() bool

IsOwnerVDC - Returns true if the owner type is VDC

func (OwnerType) IsVDCGROUP

func (o OwnerType) IsVDCGROUP() bool

IsVDCGROUP - Returns true if the owner type is VDCGROUP

type ProtectUnprotectRequest

type ProtectUnprotectRequest struct {
	// One of the following protection level settings must be specified
	// The ID of the protection level in the netbackup system
	ProtectionLevelID *int // Optional if ProtectionLevelName is specified
	// The name of the protection level in the netbackup system
	ProtectionLevelName string // Optional if ProtectionLevelID is specified
}

ProtectUnprotectRequest - Is the request structure for the Protects and Unprotects APIs

type ProtectionLevel

type ProtectionLevel struct {
	ID                            int    `json:"Id,omitempty"`
	ProtectionTypeID              int    `json:"ProtectionTypeId,omitempty"`
	Name                          string `json:"Name,omitempty"`
	Code                          string `json:"Code,omitempty"`
	Description                   string `json:"Description,omitempty"`
	Sequence                      int    `json:"Sequence,omitempty"`
	Color                         string `json:"Color,omitempty"`
	RequestTypeCode               string `json:"RequestTypeCode,omitempty"`
	IsVisible                     bool   `json:"IsVisible,omitempty"`
	IsBackupNow                   bool   `json:"IsBackupNow,omitempty"`
	IsManaged                     bool   `json:"IsManaged,omitempty"`
	SupportsFileProtect           bool   `json:"SupportsFileProtect,omitempty"`
	SupportsSingleClientBackupNow bool   `json:"SupportsSingleClientBackupNow,omitempty"`
}

func (*ProtectionLevel) GetCode

func (r *ProtectionLevel) GetCode() string

GetCode returns the Code field of ProtectionLevel

func (*ProtectionLevel) GetColor

func (r *ProtectionLevel) GetColor() string

GetColor returns the Color field of ProtectionLevel

func (*ProtectionLevel) GetDescription

func (r *ProtectionLevel) GetDescription() string

GetDescription returns the Description field of ProtectionLevel

func (*ProtectionLevel) GetID

func (r *ProtectionLevel) GetID() int

GetID returns the ID field of GetProtectionLevelResponse

func (*ProtectionLevel) GetIsBackupNow

func (r *ProtectionLevel) GetIsBackupNow() bool

GetIsBackupNow returns the IsBackupNow field of ProtectionLevel

func (*ProtectionLevel) GetIsManaged

func (r *ProtectionLevel) GetIsManaged() bool

GetIsManaged returns the IsManaged field of ProtectionLevel

func (*ProtectionLevel) GetIsVisible

func (r *ProtectionLevel) GetIsVisible() bool

GetIsVisible returns the IsVisible field of ProtectionLevel

func (*ProtectionLevel) GetName

func (r *ProtectionLevel) GetName() string

GetName returns the Name field of ProtectionLevel

func (*ProtectionLevel) GetProtectionTypeID

func (r *ProtectionLevel) GetProtectionTypeID() int

GetProtectionTypeID returns the ProtectionTypeID field of ProtectionLevel

func (*ProtectionLevel) GetRequestTypeCode

func (r *ProtectionLevel) GetRequestTypeCode() string

GetRequestTypeCode returns the RequestTypeCode field of ProtectionLevel

func (*ProtectionLevel) GetSequence

func (r *ProtectionLevel) GetSequence() int

GetSequence returns the Sequence field of ProtectionLevel

func (*ProtectionLevel) GetSupportsFileProtect

func (r *ProtectionLevel) GetSupportsFileProtect() bool

GetSupportsFileProtect returns the SupportsFileProtect field of ProtectionLevel

func (*ProtectionLevel) GetSupportsSingleClientBackupNow

func (r *ProtectionLevel) GetSupportsSingleClientBackupNow() bool

GetSupportsSingleClientBackupNow returns the SupportsSingleClientBackupNow field of ProtectionLevel

type ProtectionLevelClient

type ProtectionLevelClient struct{}

func (*ProtectionLevelClient) ListProtectionLevels

func (p *ProtectionLevelClient) ListProtectionLevels(req listProtectionLevelsRequest) (resp *ProtectionLevels, err error)

ListProtectionLevels - Get a list of protection levels Use listProtectionLevelsRequest to specify the VAppID, VDCID or MachineID

type ProtectionLevels

type ProtectionLevels []ProtectionLevel

type PublicIP

type PublicIP struct{}

func (*PublicIP) GetIP

func (v *PublicIP) GetIP(publicIP string) (response *IP, err error)

GetIP - Returns the public IP by edge gateway

func (*PublicIP) GetIPs

func (v *PublicIP) GetIPs() (response *IPs, err error)

GetIPs - Returns the list of public IPs

func (*PublicIP) GetIPsByEdgeGateway

func (v *PublicIP) GetIPsByEdgeGateway(edgeGatewayName string) (response *IPs, err error)

GetIPsByEdgeGateway - Returns the list of public IPs by edge gateway

type S3Client added in v0.4.0

type S3Client struct {
	*s3.S3
}

func (S3Client) GetUser added in v0.4.0

func (s S3Client) GetUser(username string) (resp *S3User, err *OSEError)

GetUser - Get a S3 user by username

func (S3Client) GetUsers added in v0.4.0

func (s S3Client) GetUsers() (resp *S3Users, err error)

GetUsers - Get all S3 users

func (S3Client) SyncBucket added in v0.4.1

func (s S3Client) SyncBucket(bucketName string) (err error)

SyncBucket - Syncs a bucket

type S3Credential added in v0.4.0

type S3Credential struct {
	TenantID        string    `json:"tenantId"`
	StorageTenantID string    `json:"storageTenantId"`
	Owner           string    `json:"owner"`
	OwnerID         string    `json:"ownerId"`
	StorageUserID   string    `json:"storageUserId"`
	Type            string    `json:"type"`
	Immutable       bool      `json:"immutable"`
	AccessKey       string    `json:"accessKey"`
	SecretKey       string    `json:"secretKey"`
	Active          bool      `json:"active"`
	CreatedDate     time.Time `json:"createdDate"`
	LastAccessDate  time.Time `json:"lastAccessDate"`
	AppName         string    `json:"appName"`
	AllowedBuckets  []string  `json:"allowedBuckets"`
	UsedK8SClusters []string  `json:"usedK8sClusters"`
	ProviderOwner   bool      `json:"providerOwner"`
}

func (*S3Credential) Delete added in v0.4.0

func (c *S3Credential) Delete() (err error)

DeleteCredential - Delete a credential

func (*S3Credential) GetAccessKey added in v0.4.0

func (c *S3Credential) GetAccessKey() string

func (*S3Credential) GetAllowedBuckets added in v0.4.0

func (c *S3Credential) GetAllowedBuckets() []string

func (*S3Credential) GetAppName added in v0.4.0

func (c *S3Credential) GetAppName() string

func (*S3Credential) GetCreatedDate added in v0.4.0

func (c *S3Credential) GetCreatedDate() time.Time

func (*S3Credential) GetLastAccessDate added in v0.4.0

func (c *S3Credential) GetLastAccessDate() time.Time

func (*S3Credential) GetOwner added in v0.4.0

func (c *S3Credential) GetOwner() string

func (*S3Credential) GetOwnerID added in v0.4.0

func (c *S3Credential) GetOwnerID() string

func (*S3Credential) GetSecretKey added in v0.4.0

func (c *S3Credential) GetSecretKey() string

func (*S3Credential) GetStorageTenantID added in v0.4.0

func (c *S3Credential) GetStorageTenantID() string

func (*S3Credential) GetStorageUserID added in v0.4.0

func (c *S3Credential) GetStorageUserID() string

func (*S3Credential) GetTenantID added in v0.4.0

func (c *S3Credential) GetTenantID() string

func (*S3Credential) GetType added in v0.4.0

func (c *S3Credential) GetType() string

func (*S3Credential) GetUsedK8SClusters added in v0.4.0

func (c *S3Credential) GetUsedK8SClusters() []string

func (*S3Credential) IsActive added in v0.4.0

func (c *S3Credential) IsActive() bool

func (*S3Credential) IsImmutable added in v0.4.0

func (c *S3Credential) IsImmutable() bool

func (*S3Credential) IsProviderOwner added in v0.4.0

func (c *S3Credential) IsProviderOwner() bool

type S3Credentials added in v0.4.0

type S3Credentials []S3Credential

type S3User added in v0.4.0

type S3User struct {
	Name             string   `json:"name"`
	ID               string   `json:"id"`
	FullName         string   `json:"fullName"`
	Role             string   `json:"role"`
	SubordinateRoles []string `json:"subordinateRoles"`
	Active           bool     `json:"active"`
	CurrentRegion    string   `json:"currentRegion"`
	Site             struct {
		ID           string `json:"id"`
		Name         string `json:"name"`
		RestEndpoint string `json:"restEndpoint"`
	} `json:"site"`
	Usage struct {
		Scope          string `json:"scope"`
		TotalBytes     int    `json:"totalBytes"`
		UsedBytes      int    `json:"usedBytes"`
		AvailableBytes int    `json:"availableBytes"`
		ObjectCount    int    `json:"objectCount"`
		BucketCount    int    `json:"bucketCount"`
	} `json:"usage"`
	ExistedOnStorage bool     `json:"existedOnStorage"`
	CanoncialID      string   `json:"storageCanonicalId"`
	PolicyArns       []string `json:"policyArns"`
	Remote           bool     `json:"remote"`
	PoseAsUser       bool     `json:"poseAsUser"`
	SourceTenant     string   `json:"sourceTenant"`
}

func (*S3User) GetAvailableBytes added in v0.4.0

func (s *S3User) GetAvailableBytes() int

func (*S3User) GetBucketCount added in v0.4.0

func (s *S3User) GetBucketCount() int

func (*S3User) GetCanonicalID added in v0.4.0

func (s *S3User) GetCanonicalID() (resp string, err error)

GetCanonicalID - Get a S3 user canonical ID by username

func (*S3User) GetCredential added in v0.4.0

func (s *S3User) GetCredential(accessKey string) (resp *S3Credential, err error)

GetCredential - Get a credential by access key

func (*S3User) GetCredentials added in v0.4.0

func (s *S3User) GetCredentials() (resp *S3Credentials, err error)

GetCredentials - Get a list of credentials

func (*S3User) GetCurrentRegion added in v0.4.0

func (s *S3User) GetCurrentRegion() string

func (*S3User) GetExistedOnStorage added in v0.4.0

func (s *S3User) GetExistedOnStorage() bool

func (*S3User) GetFullName added in v0.4.0

func (s *S3User) GetFullName() string

func (*S3User) GetID added in v0.4.0

func (s *S3User) GetID() string

func (*S3User) GetName added in v0.4.0

func (s *S3User) GetName() string

func (*S3User) GetObjectCount added in v0.4.0

func (s *S3User) GetObjectCount() int

func (*S3User) GetPolicyArns added in v0.4.0

func (s *S3User) GetPolicyArns() []string

func (*S3User) GetRole added in v0.4.0

func (s *S3User) GetRole() string

func (*S3User) GetSiteID added in v0.4.0

func (s *S3User) GetSiteID() string

func (*S3User) GetSiteName added in v0.4.0

func (s *S3User) GetSiteName() string

func (*S3User) GetSiteRestEndpoint added in v0.4.0

func (s *S3User) GetSiteRestEndpoint() string

func (*S3User) GetSourceTenant added in v0.4.0

func (s *S3User) GetSourceTenant() string

func (*S3User) GetSubordinateRoles added in v0.4.0

func (s *S3User) GetSubordinateRoles() []string

func (*S3User) GetTotalBytes added in v0.4.0

func (s *S3User) GetTotalBytes() int

func (*S3User) GetUsageScope added in v0.4.0

func (s *S3User) GetUsageScope() string

func (*S3User) GetUsedBytes added in v0.4.0

func (s *S3User) GetUsedBytes() int

func (*S3User) IsActive added in v0.4.0

func (s *S3User) IsActive() bool

func (*S3User) IsPoseAsUser added in v0.4.0

func (s *S3User) IsPoseAsUser() bool

func (*S3User) IsRemote added in v0.4.0

func (s *S3User) IsRemote() bool

func (*S3User) NewCredential added in v0.4.0

func (s *S3User) NewCredential() (resp *S3Credential, err error)

NewCredential - Create a new credential

type S3Users added in v0.4.0

type S3Users []S3User

func (*S3Users) UserExists added in v0.4.0

func (s *S3Users) UserExists(username string) (exist bool, user *S3User)

UserExists - Check if a user exists

type SyncBucketResponse added in v0.4.1

type SyncBucketResponse struct {
	ID               string    `json:"id"`
	VcdID            string    `json:"vcdId"`
	VcdAssociationID string    `json:"vcdAssociationId"`
	Description      string    `json:"description"`
	Status           string    `json:"status"`
	ResourceType     string    `json:"resourceType"`
	ResourceKey      string    `json:"resourceKey"`
	Progress         int       `json:"progress"`
	Tenant           string    `json:"tenant"`
	Owner            string    `json:"owner"`
	StartDate        time.Time `json:"startDate"`
	EndDate          time.Time `json:"endDate"`
	Reason           string    `json:"reason"`
	Metadata         struct {
		AdditionalProp1 string `json:"additionalProp1"`
		AdditionalProp2 string `json:"additionalProp2"`
		AdditionalProp3 string `json:"additionalProp3"`
	} `json:"metadata"`
}

type T0

type T0 struct {
	Tier0Vrf          string       `json:"tier0_vrf"`
	Tier0Provider     string       `json:"tier0_provider"`
	Tier0ClassService string       `json:"tier0_class_service"`
	ClassService      ClassService `json:"class_service"`
	Services          T0Services   `json:"services"`
}

func (*T0) GetBandwidthCapacity

func (t *T0) GetBandwidthCapacity() (bandwidthCapacity int, err error)

GetBandwidthCapacity - Returns the Bandwidth Capacity of the T0 in Mbps

func (*T0) GetClassService

func (t *T0) GetClassService() ClassService

GetClassService - Returns the ClassService

func (*T0) GetName

func (t *T0) GetName() string

GetName - Returns the Tier0Vrf

func (*T0) GetServices

func (t *T0) GetServices() T0Services

GetServices - Returns the Services

func (*T0) GetTier0ClassService

func (t *T0) GetTier0ClassService() string

GetTier0ClassService - Returns the Tier0ClassService

func (*T0) GetTier0Provider

func (t *T0) GetTier0Provider() string

GetTier0Provider - Returns the Tier0Provider

func (*T0) GetTier0Vrf

func (t *T0) GetTier0Vrf() string

GetTier0Vrf - Returns the Tier0Vrf

type T0Service

type T0Service struct {
	Service string `json:"service"`
	VlanID  any    `json:"vlanId"`
}

func (*T0Service) GetService

func (t *T0Service) GetService() string

GetService - Returns the Service

func (*T0Service) GetVlanID

func (t *T0Service) GetVlanID() any

GetVlanID - Returns the VlanID

type T0Services

type T0Services []T0Service

type T0s

type T0s []T0

type Tier0

type Tier0 struct{}

func (*Tier0) GetT0

func (t *Tier0) GetT0(t0 string) (response *T0, err error)

GetT0 - Returns the T0

func (*Tier0) GetT0s

func (t *Tier0) GetT0s() (listOfT0s *T0s, err error)

GetT0s - Returns the list of T0s

type TypeOfNetwork

type TypeOfNetwork string
const (
	NetworkTypeServiceZone TypeOfNetwork = "sv"
)

type V1

type V1 struct {
	Netbackup   Netbackup
	PublicIP    PublicIP
	EdgeGateway EdgeGateway
	T0          Tier0
	VDC         CAVVDC
	VCDA        VCDA
}

func (*V1) S3 added in v0.3.0

func (v *V1) S3() S3Client

type VApp

type VApp struct {
	ID               int    `json:"Id,omitempty"`
	Identifier       string `json:"Identifier,omitempty"`
	ProtectionTypeID int    `json:"ProtectionTypeId,omitempty"`
	VDCID            int    `json:"VdcId,omitempty"`
	Name             string `json:"Name,omitempty"`
}

VApp - Is the response structure for the GetVApp API

func (*VApp) GetID

func (vApp *VApp) GetID() int

GetID returns the ID field of VApp

func (*VApp) GetIDPtr

func (vApp *VApp) GetIDPtr() *int

GetIDPtr returns a pointer to the ID field of VApp

func (*VApp) GetIdentifier

func (vApp *VApp) GetIdentifier() string

GetIdentifier returns the Identifier field of VApp

func (*VApp) GetName

func (vApp *VApp) GetName() string

GetName returns the Name field of VApp

func (*VApp) GetProtectionLevelAvailableByID

func (vApp *VApp) GetProtectionLevelAvailableByID(id int) (resp *ProtectionLevel, err error)

GetProtectionLevelAvailableByID - Get a protection level by ID for a vCloud Director Virtual Application

func (*VApp) GetProtectionLevelAvailableByName

func (vApp *VApp) GetProtectionLevelAvailableByName(name string) (resp *ProtectionLevel, err error)

GetProtectionLevelAvailableByName - Get a protection level by name for a vCloud Director Virtual Application

func (*VApp) GetProtectionTypeID

func (vApp *VApp) GetProtectionTypeID() int

GetProtectionTypeID returns the ProtectionTypeID field of VApp

func (*VApp) ListProtectionLevels

func (vApp *VApp) ListProtectionLevels() (resp *ProtectionLevels, err error)

ListProtectionLevels - List the protection levels applied to a vCloud Director Virtual Application

func (*VApp) ListProtectionLevelsAvailable

func (vApp *VApp) ListProtectionLevelsAvailable() (resp *ProtectionLevels, err error)

ListProtectionLevelsAvailable - List the protection levels available for a vCloud Director Virtual Application

func (*VApp) Protect

func (vApp *VApp) Protect(req ProtectUnprotectRequest) (job *commonnetbackup.JobAPIResponse, err error)

ProtectVApp - Protect a vCloud Director Virtual Application

func (*VApp) Unprotect

func (vApp *VApp) Unprotect(req ProtectUnprotectRequest) (job *commonnetbackup.JobAPIResponse, err error)

UnprotectVApp - Unprotect a vCloud Director Virtual Application

type VApps

type VApps []VApp

* VApps VApps - Is the response structure for the GetVApps API

type VCDA

type VCDA struct{}

func (*VCDA) List

func (v *VCDA) List() (VDCAIps, error)

List of on premise IP addresses allowed for this organization's draas offer

func (*VCDA) RegisterIP added in v0.5.0

func (v *VCDA) RegisterIP(ip string) error

RegisterIP - Registers a new IP to the list

type VCloudClient

type VCloudClient struct{}

func (*VCloudClient) GetOrg

func (v *VCloudClient) GetOrg(id int) (resp *Org, err error)

GetOrg - Get a vCloud Director Organization

func (*VCloudClient) GetOrgByName

func (v *VCloudClient) GetOrgByName(name string) (resp *Org, err error)

GetOrgByName - Get a vCloud Director Organization by name

func (*VCloudClient) GetOrgs

func (v *VCloudClient) GetOrgs() (resp *Orgs, err error)

GetOrgs - Get a list of vCloud Director Organizations

func (*VCloudClient) GetVAppByID

func (v *VCloudClient) GetVAppByID(id int) (resp *VApp, err error)

GetVAppByID - Get a vCloud Director Virtual Application by ID id - The ID of the vapp in the netbackup system

func (*VCloudClient) GetVAppByIdentifier

func (v *VCloudClient) GetVAppByIdentifier(identifier string) (resp *VApp, err error)

GetVAppByIdentifier - Get a vCloud Director Virtual Application by Identifier identifier - The Identifier of the vapp in the vmware system (URN)

func (*VCloudClient) GetVAppByName

func (v *VCloudClient) GetVAppByName(name string) (resp *VApp, err error)

GetVAppByName - Get a vCloud Director Virtual Application by Name name - The name of the vapp in the netbackup system

func (*VCloudClient) GetVAppByNameOrIdentifier

func (v *VCloudClient) GetVAppByNameOrIdentifier(nameOrIdentifier string) (resp *VApp, err error)

GetVdcByNameOrIdentifier - Get a vCloud Director Virtual Application by Name or Identifier nameOrIdentifier - The Name or Identifier of the vapp in the vmware system

func (*VCloudClient) GetVAppMachines

func (v *VCloudClient) GetVAppMachines(vAppID int) (resp *GetVAppMachinesResponse, err error)

GetVAppMachines - Get a list of vCloud Director Virtual Application Machines

func (*VCloudClient) GetVApps

func (v *VCloudClient) GetVApps() (resp *VApps, err error)

GetVApps - Get a list of vCloud Director Virtual Applications

func (*VCloudClient) GetVdcByID

func (v *VCloudClient) GetVdcByID(id int) (resp *VDC, err error)

GetVdcByID - Get a vCloud Director Virtual Data Center by ID id - The ID of the vdc in the netbackup system

func (*VCloudClient) GetVdcByIdentifier

func (v *VCloudClient) GetVdcByIdentifier(identifier string) (resp *VDC, err error)

GetVdcByIdentifier - Get a vCloud Director Virtual Data Center by Identifier identifier - The Identifier of the vdc in the vmware system (URN)

func (*VCloudClient) GetVdcByName

func (v *VCloudClient) GetVdcByName(name string) (resp *VDC, err error)

GetVdcByName - Get a vCloud Director Virtual Data Center by Name name - The Name of the vdc in the vmware system

func (*VCloudClient) GetVdcByNameOrIdentifier

func (v *VCloudClient) GetVdcByNameOrIdentifier(nameOrIdentifier string) (resp *VDC, err error)

GetVdcByNameOrIdentifier - Get a vCloud Director Virtual Data Center by Name or Identifier nameOrIdentifier - The Name or Identifier of the vdc in the vmware system

func (*VCloudClient) GetVdcs

func (v *VCloudClient) GetVdcs() (resp *VDCs, err error)

GetVdcs - Get a list of vCloud Director Virtual Data Centers

func (*VCloudClient) GetVdcsByOrgID

func (v *VCloudClient) GetVdcsByOrgID(orgID int) (resp *VDCs, err error)

GetVdcsByOrgID - Get a list of vCloud Director Virtual Data Centers by Org ID orgID - The ID of the org in the netbackup system

type VDC

type VDC struct {
	ID               int    `json:"Id,omitempty"`
	Name             string `json:"Name,omitempty"`
	Identifier       string `json:"Identifier,omitempty"`
	VOrgID           int    `json:"VOrgId,omitempty"`
	ProtectionTypeID int    `json:"ProtectionTypeId,omitempty"`
}

VDC - Is the response structure for the GetVdc API

func (*VDC) GetID

func (vdc *VDC) GetID() int

GetID returns the ID field of VDC

func (*VDC) GetIDPtr

func (vdc *VDC) GetIDPtr() *int

GetIDPtr returns a pointer to the ID field of VDC

func (*VDC) GetIdentifier

func (vdc *VDC) GetIdentifier() string

GetIdentifier returns the Identifier field of VDC

func (*VDC) GetName

func (vdc *VDC) GetName() string

GetName returns the Name field of VDC

func (*VDC) GetProtectionLevelAvailableByID

func (vdc *VDC) GetProtectionLevelAvailableByID(id int) (resp *ProtectionLevel, err error)

GetProtectionLevelAvailableByID - Get a protection level by ID for a vCloud Director Virtual Application

func (*VDC) GetProtectionLevelAvailableByName

func (vdc *VDC) GetProtectionLevelAvailableByName(name string) (resp *ProtectionLevel, err error)

GetProtectionLevelAvailableByName - Get a protection level by name for a vCloud Director Virtual Application

func (*VDC) GetProtectionTypeID

func (vdc *VDC) GetProtectionTypeID() int

GetProtectionTypeID returns the ProtectionTypeID field of VDC

func (*VDC) GetVOrgID

func (vdc *VDC) GetVOrgID() int

GetVOrgID returns the VOrgID field of VDC

func (*VDC) ListProtectionLevels

func (vdc *VDC) ListProtectionLevels() (resp *ProtectionLevels, err error)

ListProtectionLevels - List the protection levels applied to a vCloud Director Virtual Application

func (*VDC) ListProtectionLevelsAvailable

func (vdc *VDC) ListProtectionLevelsAvailable() (resp *ProtectionLevels, err error)

ListProtectionLevelsAvailable - List the protection levels available for a vCloud Director Virtual Application

func (*VDC) Protect

func (vdc *VDC) Protect(req ProtectUnprotectRequest) (job *commonnetbackup.JobAPIResponse, err error)

ProtectVdc - Protect a vCloud Director Virtual Data Center

func (*VDC) Unprotect

func (vdc *VDC) Unprotect(req ProtectUnprotectRequest) (job *commonnetbackup.JobAPIResponse, err error)

UnprotectVdc - Unprotect a vCloud Director Virtual Data Center

type VDCAIP

type VDCAIP string

type VDCAIps

type VDCAIps []string

func (*VDCAIps) DeleteAllIPs

func (v *VDCAIps) DeleteAllIPs() error

DeleteAllIPs - Deletes all IPs from the list

func (*VDCAIps) DeleteIP

func (v *VDCAIps) DeleteIP(ip string) error

DeleteIP - Deletes an IP from the list

func (*VDCAIps) IsIPExists

func (v *VDCAIps) IsIPExists(ip string) bool

IsIPExists - Returns true if the IP exists

type VDCBillingModel

type VDCBillingModel string

VDCBillingModel - VDC Billing Model

func (VDCBillingModel) IsValid

func (v VDCBillingModel) IsValid() bool

IsValid - Check if the billing model is valid

type VDCDisponibilityClass

type VDCDisponibilityClass string

VDCDisponibilityClass - VDC Disponibility Class

func (VDCDisponibilityClass) IsValid

func (v VDCDisponibilityClass) IsValid() bool

IsValid - Check if the disponibility class is valid

type VDCServiceClass

type VDCServiceClass string

VDCServiceClass - VDC Service Class

func (VDCServiceClass) IsValid

func (v VDCServiceClass) IsValid() bool

IsValid - Check if the service class is valid

type VDCStorageBillingModel

type VDCStorageBillingModel string

VDCStorageBillingModel - VDC Storage Billing Model

func (VDCStorageBillingModel) IsValid

func (v VDCStorageBillingModel) IsValid() bool

IsValid - Check if the storage billing model is valid

type VDCStrorageProfile

type VDCStrorageProfile struct {
	Class   VDCStrorageProfileClass `json:"class"`
	Limit   int                     `json:"limit"`
	Default bool                    `json:"default"`
}

type VDCStrorageProfileClass

type VDCStrorageProfileClass string

VDCStrorageProfileClass - VDC Storage Profile Class

func (VDCStrorageProfileClass) IsValid

func (s VDCStrorageProfileClass) IsValid() bool

IsValid - Check if the storage profile class is valid

type VDCs

type VDCs []VDC

* VDCs VDCs - Is the response structure for the GetVdcs API

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL