sifi

package
v0.21.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package sifi implements the go language bindings for the HyperCloud SIFI API. The bindings will support exactly one version of the API at a time, even though the data types for all currently supported versions can be found in the v* directories.

The generated directory contains the generated code from the legacy XMLRPC API. Once all of these types have been forked and moved into the models directory, this directory can be removed. This should be a prerequisite for moving this code to public github.

Index

Constants

View Source
const (
	PortNumber  = 7434    // PortNumber is the default port for `sifid` (sifi on a keypad).
	ServiceName = "sifid" // ServiceName is the public name of the SIFI service.
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ACLService

type ACLService struct {
	*client.Client
}

ACLService owns the /acl methods.

func (ACLService) ACLs

ACLs returns a slice containing all of the Access Control Lists.

func (ACLService) CreateACL

CreateACL creates a new Access Control List and returns its id.

func (ACLService) DeleteACL

func (s ACLService) DeleteACL(ctx context.Context, id int) error

DeleteACL deletes the Access Control List specified by the id.

type ClusterService

type ClusterService struct {
	*client.Client
}

ClusterService owns the /cluster methods.

func (ClusterService) AddClusterDatastore

func (s ClusterService) AddClusterDatastore(ctx context.Context, id, datastore int) (*hc.AddClusterDatastoreResponse, error)

AddClusterDatastore adds the datastore to the cluster.

func (ClusterService) AddClusterHost

func (s ClusterService) AddClusterHost(ctx context.Context, id, host int) (*hc.AddClusterHostResponse, error)

AddClusterHost adds the host to the cluster.

func (ClusterService) AddClusterNetwork

func (s ClusterService) AddClusterNetwork(ctx context.Context, id, network int) (*hc.AddClusterNetworkResponse, error)

AddClusterNetwork adds the network to the cluster.

func (ClusterService) Cluster

func (s ClusterService) Cluster(ctx context.Context, id int) (*hc.ListClusterResponse, error)

Cluster returns information about a cluster.

func (ClusterService) Clusters

Clusters returns information about all clusters.

func (ClusterService) CreateCluster

CreateCluster creates a cluster.

func (ClusterService) DeleteCluster

func (s ClusterService) DeleteCluster(ctx context.Context, id int) error

DeleteCluster deletes the cluster with the given ID.

func (ClusterService) DeleteClusterDatastore

func (s ClusterService) DeleteClusterDatastore(ctx context.Context, id, datastore int) error

DeleteClusterDatastore deletes the datastore from the cluster.

func (ClusterService) DeleteClusterHost

func (s ClusterService) DeleteClusterHost(ctx context.Context, id, host int) error

DeleteClusterHost deletes the host from the cluster.

func (ClusterService) DeleteClusterNetwork

func (s ClusterService) DeleteClusterNetwork(ctx context.Context, id, network int) error

DeleteClusterNetwork deletes the network from the cluster.

func (ClusterService) RenameCluster

RenameCluster updates the name of the cluster.

func (ClusterService) UpdateCluster

UpdateCluster updates the cluster.

type DatastoreService

type DatastoreService struct {
	*client.Client
}

DatastoreService owns the /datastore methods.

func (DatastoreService) ChangeDatastoreOwnership

ChangeDatastoreOwnership changes the datastore ownership with the given ID.

func (DatastoreService) ChangeDatastorePermissions

ChangeDatastorePermissions changes the datastore permissions with the given ID.

func (DatastoreService) CreateDatastore

CreateDatastore creates a new datastore.

func (DatastoreService) Datastore

Datastore returns information about a datastore.

func (DatastoreService) Datastores

Datastores returns information about all datastores.

func (DatastoreService) DeleteDatastore

func (s DatastoreService) DeleteDatastore(ctx context.Context, id string) error

DeleteDatastore deletes the datastore with the given ID.

func (DatastoreService) EnableDatastore

EnableDatastore enables the datastore with the given ID.

func (DatastoreService) RenameDatastore

RenameDatastore renames the datastore with the given ID.

func (DatastoreService) UpdateDatastore

UpdateDatastore updates the datastore with the given ID.

type DocumentService

type DocumentService struct {
	*client.Client
}

DocumentService owns the /document methods.

func (DocumentService) AllocateDocument

AllocateDocument allocates a document.

func (DocumentService) ChangeDocumentOwnership

ChangeDocumentOwnership changes the ownership of the document with the given ID.

func (DocumentService) ChangeDocumentPermissions

ChangeDocumentPermissions changes the permissions of the document with the given ID.

func (DocumentService) CloneDocument

CloneDocument clones the document with the given ID.

func (DocumentService) DeleteDocument

func (s DocumentService) DeleteDocument(ctx context.Context, id int) error

DeleteDocument deletes a document with the given ID.

func (DocumentService) Document

Document returns information about the document with the given ID.

func (DocumentService) Documents

Documents returns information about all documents.

func (DocumentService) LockDocument

LockDocument locks the document with the given ID.

func (DocumentService) RenameDocument

RenameDocument renames the document with the given ID.

func (DocumentService) UnlockDocument

func (s DocumentService) UnlockDocument(ctx context.Context, id int) (*hc.UnlockDocumentResponse, error)

UnlockDocument unlocks the document with the given ID.

func (DocumentService) UpdateDocument

UpdateDocument updates the document with the given ID.

type GroupService

type GroupService struct {
	*client.Client
}

GroupService owns the /group methods.

func (GroupService) AddGroupAdmin

AddGroupAdmin adds a group admin to the group with the given ID.

func (GroupService) CreateGroup

CreateGroup creates a new group.

func (GroupService) DeleteGroup

func (s GroupService) DeleteGroup(ctx context.Context, id int) error

DeleteGroup deletes the group with the given ID.

func (GroupService) DeleteGroupAdmin

func (s GroupService) DeleteGroupAdmin(ctx context.Context, id, user int) error

DeleteGroupAdmin deletes the group admin from the group with the given ID.

func (GroupService) Group

func (s GroupService) Group(ctx context.Context, id int) (*hc.ListGroupResponse, error)

Group returns information about a group.

func (GroupService) GroupQuota

GroupQuota returns the default group quota.

func (GroupService) Groups

Groups returns information about all groups.

func (GroupService) SetGroupQuota

SetGroupQuota sets the quota for the group with the given ID.

func (GroupService) UpdateGroup

UpdateGroup updates the group with the given ID.

func (GroupService) UpdateGroupQuota

UpdateGroupQuota updates the default group quota.

type HookService

type HookService struct {
	*client.Client
}

HookService own the /hook methods.

func (HookService) CreateHook

CreateHook creates a new hook.

func (HookService) DeleteHook

func (s HookService) DeleteHook(ctx context.Context, id int) error

DeleteHook deletes the hook with the given id.

func (HookService) Hook

func (s HookService) Hook(ctx context.Context, id int) (*hc.ListHookResponse, error)

Hook returns information about a hook.

func (HookService) HookLog

func (s HookService) HookLog(ctx context.Context, id int, start, end string) (*hc.ListHookLogResponse, error)

HookLog returns the logs for a hook.

func (HookService) Hooks

Hooks returns information about all hooks.

func (HookService) LockHook

func (s HookService) LockHook(ctx context.Context, id int, req hc.LockHookRequest) (*hc.LockHookResponse, error)

LockHook locks the hook with the given id.

func (HookService) RenameHook

func (s HookService) RenameHook(ctx context.Context, id int, req hc.RenameHookRequest) (*hc.RenameHookResponse, error)

RenameHook renames the hook with the given id.

func (HookService) RetryHook

func (s HookService) RetryHook(ctx context.Context, id int, req hc.RetryHookRequest) (*hc.RetryHookResponse, error)

RetryHook retries the hook with the given id.

func (HookService) UnlockHook

func (s HookService) UnlockHook(ctx context.Context, id int, req hc.UnlockHookRequest) (*hc.UnlockHookResponse, error)

UnlockHook unlocks the hook with the given id.

func (HookService) UpdateHook

func (s HookService) UpdateHook(ctx context.Context, id int, req hc.UpdateHookRequest) (*hc.UpdateHookResponse, error)

UpdateHook updates the hook with the given id.

type HostService

type HostService struct {
	*client.Client
}

HostService owns the /host methods.

func (HostService) CreateHost

CreateHost creates a new host.

func (HostService) DeleteHost

func (s HostService) DeleteHost(ctx context.Context, id int) error

DeleteHost deletes the host with the given ID.

func (HostService) Host

func (s HostService) Host(ctx context.Context, id int) (*hc.ListHostResponse, error)

Host returns information about a host.

func (HostService) HostMonitoring

func (s HostService) HostMonitoring(ctx context.Context, id int) (*hc.ListHostMonitoringResponse, error)

HostMonitoring returns monitoring data for a host.

func (HostService) Hosts

Hosts returns information about all hosts.

func (HostService) HostsMonitoring

func (s HostService) HostsMonitoring(ctx context.Context, interval time.Duration) (*hc.ListHostsMonitoringResponse, error)

HostsMonitoring returns monitoring data for all hosts.

func (HostService) RenameHost

func (s HostService) RenameHost(ctx context.Context, id int, req hc.RenameHostRequest) (*hc.RenameHostResponse, error)

RenameHost renames the host with the given ID.

func (HostService) SetHostStatus

SetHostStatus sets the status of the host with the given ID.

func (HostService) UpdateHost

func (s HostService) UpdateHost(ctx context.Context, id int, req hc.UpdateHostRequest) (*hc.UpdateHostResponse, error)

UpdateHost updates the host with the given ID.

type ImageService

type ImageService struct {
	*client.Client
}

ImageService owns the /image methods.

func (ImageService) ChangeImageOwnership

ChangeImageOwnership changes the ownership of the image with the given ID.

func (ImageService) ChangeImagePermissions

ChangeImagePermissions changes the permissions of the image with the given ID.

func (ImageService) ChangeImageType

ChangeImageType changes the type of the image with the given ID.

func (ImageService) CloneImage

CloneImage clones the image with the given ID.

func (ImageService) CreateImage

CreateImage creates a new image.

func (ImageService) DeleteImage

func (s ImageService) DeleteImage(ctx context.Context, id int) error

DeleteImage deletes the image with the given ID.

func (ImageService) DeleteImageSnapshot

func (s ImageService) DeleteImageSnapshot(ctx context.Context, id, snapshot int) error

DeleteImageSnapshot deletes a snapshot for the image with the given ID.

func (ImageService) EnableImage

EnableImage enables the image with the given ID.

func (ImageService) FlattenImageSnapshot

func (s ImageService) FlattenImageSnapshot(ctx context.Context, id, snapshot int) (*hc.FlattenImageSnapshotResponse, error)

FlattenImageSnapshot flattens the snapshot of the image with the given ID.

func (ImageService) Image

func (s ImageService) Image(ctx context.Context, id int) (*hc.ListImageResponse, error)

Image returns information about a image.

func (ImageService) Images

Images returns information about all images.

func (ImageService) LockImage

LockImage locks the image with the given ID.

func (ImageService) RenameImage

RenameImage renames the image with the given ID.

func (ImageService) RevertImageSnapshot

func (s ImageService) RevertImageSnapshot(ctx context.Context, id, snapshot int) (*hc.RevertImageSnapshotResponse, error)

RevertImageSnapshot reverts the snapshot of the image with the given ID.

func (ImageService) SetImagePersistent

SetImagePersistent sets the image with the given ID to be persistent.

func (ImageService) UnlockImage

func (s ImageService) UnlockImage(ctx context.Context, id int) (*hc.UnlockImageResponse, error)

UnlockImage unlocks the image with the given ID.

func (ImageService) UpdateImage

UpdateImage updates the image with the given ID.

type InstanceService

type InstanceService struct {
	*client.Client
}

InstanceService owns the /instance and /instance-group methods.

func (InstanceService) AddInstanceSchedule

AddInstanceSchedule adds a schedule to the instance with the given id.

func (InstanceService) AddInstanceSecurityGroup

func (s InstanceService) AddInstanceSecurityGroup(ctx context.Context, id, nic, sg int) (*hc.AddInstanceSecurityGroupResponse, error)

AddInstanceSecurityGroup adds a security group to the instance with the given id.

func (InstanceService) CalculateInstancesShowback

func (s InstanceService) CalculateInstancesShowback(ctx context.Context, req hc.CalculateInstancesShowbackRequest) error

CalculateInstancesShowback calculates the showback for all the instances.

func (InstanceService) ChangeInstanceGroupOwnership

ChangeInstanceGroupOwnership changes the ownership of the instance group with the given ID.

func (InstanceService) ChangeInstanceGroupPermissions

ChangeInstanceGroupPermissions changes the permissions of the instance group with the given ID.

func (InstanceService) ChangeInstanceOwnership

ChangeInstanceOwnership changes the ownership of the instance with the given id.

func (InstanceService) ChangeInstancePermissions

ChangeInstancePermissions changes the permissions of the instance with the given id.

func (InstanceService) CreateInstance

CreateInstance creates a new instance.

func (InstanceService) CreateInstanceDisk

CreateInstanceDisk creates a new disk for the instance with the given id.

func (InstanceService) CreateInstanceDiskImage

CreateInstanceDiskImage creates a new disk image for the instance with the given id.

func (InstanceService) CreateInstanceDiskSnapshot

CreateInstanceDiskSnapshot creates a new disk snapshot for the instance with the given id.

func (InstanceService) CreateInstanceNIC

CreateInstanceNIC creates a new NIC for the instance with the given id.

func (InstanceService) CreateInstanceSnapshot

CreateInstanceSnapshot creates a new snapshot for the instance with the given id.

func (InstanceService) DeleteInstanceDisk

func (s InstanceService) DeleteInstanceDisk(ctx context.Context, id, disk int) error

DeleteInstanceDisk deletes a disk from the instance with the given id.

func (InstanceService) DeleteInstanceDiskSnapshot

func (s InstanceService) DeleteInstanceDiskSnapshot(ctx context.Context, id, disk, snapshot int) error

DeleteInstanceDiskSnapshot deletes a snapshot from the instance with the given id.

func (InstanceService) DeleteInstanceGroup

func (s InstanceService) DeleteInstanceGroup(ctx context.Context, id int) error

DeleteInstanceGroup deletes the instance group with the given ID.

func (InstanceService) DeleteInstanceNIC

func (s InstanceService) DeleteInstanceNIC(ctx context.Context, id, nic int) error

DeleteInstanceNIC deletes a NIC from the instance with the given id.

func (InstanceService) DeleteInstanceSchedule

func (s InstanceService) DeleteInstanceSchedule(ctx context.Context, id, schedule int) error

DeleteInstanceSchedule deletes a schedule from the instance with the given id.

func (InstanceService) DeleteInstanceSecurityGroup

func (s InstanceService) DeleteInstanceSecurityGroup(ctx context.Context, id, nic int) error

DeleteInstanceSecurityGroup deletes a security group from the instance with the given id.

func (InstanceService) DeleteInstanceSnapshot

func (s InstanceService) DeleteInstanceSnapshot(ctx context.Context, id, snapshot int) error

DeleteInstanceSnapshot deletes a snapshot from the instance with the given id.

func (InstanceService) DeployInstance

DeployInstance deploys the instance with the given id.

func (InstanceService) Instance

Instance returns the Instance for the given id.

func (InstanceService) InstanceGroup

func (s InstanceService) InstanceGroup(ctx context.Context, id int) (*hc.ListInstanceGroupResponse, error)

InstanceGroup returns information about an instance group.

func (InstanceService) InstanceGroups

InstanceGroups returns information about all instance groups.

func (InstanceService) InstanceMonitoringData

func (s InstanceService) InstanceMonitoringData(ctx context.Context, id int) (*hc.ListInstanceMonitoringResponse, error)

InstanceMonitoringData returns monitoring data for id.

func (InstanceService) InstanceShowback

func (s InstanceService) InstanceShowback(ctx context.Context, filter hc.Filter, monthStart, monthEnd time.Month, yearStart, yearEnd int) (*hc.ListInstancesShowbackResponse, error)

InstanceShowback returns showback data for a set of instances.

func (InstanceService) Instances

func (s InstanceService) Instances(ctx context.Context, state hc.InstanceState, extended bool) (*hc.ListInstancesResponse, error)

Instances returns a slice of all the Instances in the given state.

func (InstanceService) InstancesAccountingData

func (s InstanceService) InstancesAccountingData(ctx context.Context, filter hc.Filter, start, end time.Time) (*hc.ListInstancesAccountingResponse, error)

InstancesAccountingData returns accounting data for a set of instances.

func (InstanceService) InstancesMonitoringData

func (s InstanceService) InstancesMonitoringData(ctx context.Context, filter hc.Filter, seconds int) (*hc.ListInstancesMonitoringResponse, error)

InstancesMonitoringData returns monitoring data for a set of instances.

func (InstanceService) InstancesSet

func (s InstanceService) InstancesSet(ctx context.Context, ids ...int) (*hc.ListInstancesResponse, error)

InstancesSet returns a slice of Instances.

func (InstanceService) LockInstance

LockInstance locks the instance with the given id.

func (InstanceService) LockInstanceGroup

LockInstanceGroup locks the instance group with the given ID.

func (InstanceService) MoveInstance

MoveInstance moves the instance with the given id.

func (InstanceService) RecoverInstance

RecoverInstance recovers the instance with the given id.

func (InstanceService) RenameInstance

RenameInstance renames the instance with the given id.

func (InstanceService) RenameInstanceDiskSnapshot

func (s InstanceService) RenameInstanceDiskSnapshot(ctx context.Context, id, disk, snapshot int, req hc.RenameInstanceDiskSnapshotRequest) (*hc.RenameInstanceDiskSnapshotResponse, error)

RenameInstanceDiskSnapshot renames the disk snapshot for the instance with the given id.

func (InstanceService) RenameInstanceGroup

RenameInstanceGroup renames the instance group with the given ID.

func (InstanceService) ResizeInstance

ResizeInstance resizes the instance with the given id.

func (InstanceService) ResizeInstanceDisk

func (s InstanceService) ResizeInstanceDisk(ctx context.Context, id, disk int, req hc.ResizeInstanceDiskRequest) (*hc.ResizeInstanceDiskResponse, error)

ResizeInstanceDisk resizes the disk for the instance with the given id.

func (InstanceService) RevertInstanceDiskSnapshot

func (s InstanceService) RevertInstanceDiskSnapshot(ctx context.Context, id, disk, snapshot int) (*hc.RevertInstanceDiskSnapshotResponse, error)

RevertInstanceDiskSnapshot reverts the disk snapshot for the instance with the given id.

func (InstanceService) RevertInstanceSnapshot

func (s InstanceService) RevertInstanceSnapshot(ctx context.Context, id, snapshot int) (*hc.RevertInstanceSnapshotResponse, error)

RevertInstanceSnapshot reverts the snapshot for the instance with the given id.

func (InstanceService) SetInstanceAction

SetInstanceAction sets the action for the instance with the given id.

func (InstanceService) UnlockInstance

func (s InstanceService) UnlockInstance(ctx context.Context, id int) (*hc.UnlockInstanceResponse, error)

UnlockInstance unlocks the instance with the given id.

func (InstanceService) UnlockInstanceGroup

func (s InstanceService) UnlockInstanceGroup(ctx context.Context, id int) (*hc.UnlockInstanceGroupResponse, error)

UnlockInstanceGroup unlocks the instance group with the given ID.

func (InstanceService) UpdateInstanceConfig

UpdateInstanceConfig updates the config for the instance with the given id.

func (InstanceService) UpdateInstanceGroup

UpdateInstanceGroup updates the instance group with the given ID.

func (InstanceService) UpdateInstanceSchedule

UpdateInstanceSchedule updates the schedule for the instance with the given id.

func (InstanceService) UpdateInstanceTemplate

UpdateInstanceTemplate updates the template for the instance with the given id.

type MarketService

type MarketService struct {
	*client.Client
}

MarketService owns the /market methods.

func (MarketService) ChangeMarketAppOwnership

ChangeMarketAppOwnership changes the ownership of the marketplace application with the given ID.

func (MarketService) ChangeMarketAppPermissions

ChangeMarketAppPermissions changes the permissions of the marketplace application with the given ID.

func (MarketService) ChangeMarketOwnership

ChangeMarketOwnership changes the ownership of the marketplace with the given ID.

func (MarketService) ChangeMarketPermissions

ChangeMarketPermissions changes the permissions of the marketplace with the given ID.

func (MarketService) CreateMarket

CreateMarket creates a new marketplace.

func (MarketService) CreateMarketApp

CreateMarketApp creates a new marketplace application.

func (MarketService) DeleteMarket

func (s MarketService) DeleteMarket(ctx context.Context, id int) error

DeleteMarket deletes the market with the given ID.

func (MarketService) DeleteMarketApp

func (s MarketService) DeleteMarketApp(ctx context.Context, id, app int) error

DeleteMarketApp deletes the marketplace application with the given ID.

func (MarketService) EnableMarket

EnableMarket enables the marketplace with the given ID.

func (MarketService) EnableMarketApp

func (s MarketService) EnableMarketApp(ctx context.Context, id, app int, req hc.EnableMarketAppRequest) (*hc.EnableMarketAppResponse, error)

EnableMarketApp enables the marketplace application with the given ID.

func (MarketService) LockMarketApp

func (s MarketService) LockMarketApp(ctx context.Context, id, app int, req hc.LockMarketAppRequest) (*hc.LockMarketAppResponse, error)

LockMarketApp locks the marketplace application with the given ID.

func (MarketService) Market

func (s MarketService) Market(ctx context.Context, id int) (*hc.ListMarketResponse, error)

Market returns information about a marketplace.

func (MarketService) MarketApp

func (s MarketService) MarketApp(ctx context.Context, id int) (*hc.ListMarketAppResponse, error)

MarketApp returns information about a marketplace application.

func (MarketService) MarketApps

MarketApps returns information about all marketplace applications.

func (MarketService) Markets

Markets returns information about all marketplaces.

func (MarketService) RenameMarket

RenameMarket renames the marketplace with the given ID.

func (MarketService) RenameMarketApp

func (s MarketService) RenameMarketApp(ctx context.Context, id, app int, req hc.RenameMarketAppRequest) (*hc.RenameMarketAppResponse, error)

RenameMarketApp renames the marketplace application with the given ID.

func (MarketService) UnlockMarketApp

func (s MarketService) UnlockMarketApp(ctx context.Context, id, app int) (*hc.UnlockMarketAppResponse, error)

UnlockMarketApp unlocks the marketplace application with the given ID.

func (MarketService) UpdateMarket

UpdateMarket updates the marketplace with the given ID.

func (MarketService) UpdateMarketApp

func (s MarketService) UpdateMarketApp(ctx context.Context, id, app int, req hc.UpdateMarketAppRequest) (*hc.UpdateMarketAppResponse, error)

UpdateMarketApp updates the marketplace application with the given ID.

type SecurityGroupService

type SecurityGroupService struct {
	*client.Client
}

SecurityGroupService owns the /security-group methods.

func (SecurityGroupService) ChangeSecurityGroupOwnership

ChangeSecurityGroupOwnership changes the ownership of the security group with the given ID.

func (SecurityGroupService) ChangeSecurityGroupPermissions

ChangeSecurityGroupPermissions changes the permissions of the security group with the given ID.

func (SecurityGroupService) CloneSecurityGroup

CloneSecurityGroup clones the security group with the given ID.

func (SecurityGroupService) CommitSecurityGroup

CommitSecurityGroup commits the security group with the given ID.

func (SecurityGroupService) CreateSecurityGroup

CreateSecurityGroup creates a new security group.

func (SecurityGroupService) DeleteSecurityGroup

func (s SecurityGroupService) DeleteSecurityGroup(ctx context.Context, id int) error

DeleteSecurityGroup deletes the security group with the given ID.

func (SecurityGroupService) RenameSecurityGroup

RenameSecurityGroup renames the security group with the given ID.

func (SecurityGroupService) SecurityGroup

SecurityGroup returns information about a image.

func (SecurityGroupService) SecurityGroups

SecurityGroups returns information about all images.

func (SecurityGroupService) UpdateSecurityGroup

UpdateSecurityGroup updates the security group with the given ID.

type SystemService

type SystemService struct {
	*client.Client
}

SystemService owns the /system methods.

func (SystemService) SystemConfig

SystemConfig returns HC config.

func (SystemService) SystemVersion

SystemVersion returns the version of HC.

type TemplateService

type TemplateService struct {
	*client.Client
}

TemplateService own the /template methods.

func (TemplateService) ChangeTemplateOwnership

ChangeTemplateOwnership changes the ownership of the template with the given ID.

func (TemplateService) ChangeTemplatePermissions

ChangeTemplatePermissions changes the permissions of the template with the given ID.

func (TemplateService) CloneTemplate

CloneTemplate clones the template with the given ID.

func (TemplateService) CreateTemplate

CreateTemplate creates a new template.

func (TemplateService) DeleteTemplate

func (s TemplateService) DeleteTemplate(ctx context.Context, id int) error

DeleteTemplate deletes the template with the given ID.

func (TemplateService) InstantiateTemplate

InstantiateTemplate instantiates the template with the given ID.

func (TemplateService) LockTemplate

LockTemplate locks the template with the given ID.

func (TemplateService) RenameTemplate

RenameTemplate renames the template with the given ID.

func (TemplateService) Template

Template returns information about a template.

func (TemplateService) Templates

Templates returns information about all templates.

func (TemplateService) UnlockTemplate

func (s TemplateService) UnlockTemplate(ctx context.Context, id int) (*hc.UnlockTemplateResponse, error)

UnlockTemplate unlocks the template with the given ID.

func (TemplateService) UpdateTemplate

UpdateTemplate updates the template with the given ID.

type UserService

type UserService struct {
	*client.Client
}

UserService owns the /user methods.

func (UserService) AddUserGroup

func (s UserService) AddUserGroup(ctx context.Context, id, group int) (*hc.AddUserGroupResponse, error)

AddUserGroup adds the user to the group with the given ID.

func (UserService) ChangeUserAuth

ChangeUserAuth changes the user's authentication method.

func (UserService) ChangeUserGroup

func (s UserService) ChangeUserGroup(ctx context.Context, id, group int) (*hc.ChangeUserGroupResponse, error)

ChangeUserGroup changes the user's group.

func (UserService) ChangeUserPassword

ChangeUserPassword changes the user's password.

func (UserService) CreateUser

CreateUser creates a new user.

func (UserService) DeleteUser

func (s UserService) DeleteUser(ctx context.Context, id int) error

DeleteUser deletes the user with the given ID.

func (UserService) DeleteUserGroup

func (s UserService) DeleteUserGroup(ctx context.Context, id, group int) error

DeleteUserGroup deletes the user from the group with the given ID.

func (UserService) EnableUser

func (s UserService) EnableUser(ctx context.Context, id int, req hc.EnableUserRequest) (*hc.EnableUserResponse, error)

EnableUser enables the user with the given ID.

func (UserService) SetUserQuota

SetUserQuota sets the user's quota.

func (UserService) UpdateDefaultUserQuota

UpdateDefaultUserQuota updates the default user quota.

func (UserService) UpdateUser

func (s UserService) UpdateUser(ctx context.Context, id int, req hc.UpdateUserRequest) (*hc.UpdateUserResponse, error)

UpdateUser updates the user with the given ID.

func (UserService) User

func (s UserService) User(ctx context.Context, id int) (*hc.ListUserResponse, error)

User returns information about a user.

func (UserService) UserQuota

UserQuota returns the default user quota.

func (UserService) Users

Users returns information about all users.

type VNetService

type VNetService struct {
	*client.Client
}

VNetService owns the /vnet methods.

func (VNetService) AddVNetAddressRange

AddVNetAddressRange adds an address range to the virtual network with the given ID.

func (VNetService) ChangeVNetOwnership

ChangeVNetOwnership changes the ownership of the virtual network with the given ID.

func (VNetService) ChangeVNetPermissions

ChangeVNetPermissions changes the permissions of the virtual network with the given ID.

func (VNetService) ChangeVNetTemplateOwnership

ChangeVNetTemplateOwnership changes the ownership of the virtual network template with the given ID.

func (VNetService) ChangeVNetTemplatePermissions

ChangeVNetTemplatePermissions changes the permissions of the virtual network template with the given ID.

func (VNetService) CloneVNetTemplate

CloneVNetTemplate clones the virtual network template with the given ID.

func (VNetService) CreateVNet

CreateVNet creates a new virtual network.

func (VNetService) CreateVNetTemplate

CreateVNetTemplate creates a new virtual network template.

func (VNetService) DeleteVNet

func (s VNetService) DeleteVNet(ctx context.Context, id int) error

DeleteVNet deletes the virtual network with the given ID.

func (VNetService) DeleteVNetAddressRange

func (s VNetService) DeleteVNetAddressRange(ctx context.Context, id, ar int) error

DeleteVNetAddressRange deletes an address range from the virtual network with the given ID.

func (VNetService) DeleteVNetTemplate

func (s VNetService) DeleteVNetTemplate(ctx context.Context, id int) error

DeleteVNetTemplate deletes the virtual network template with the given ID.

func (VNetService) FreeVNetAddressRange

func (s VNetService) FreeVNetAddressRange(ctx context.Context, id, ar int) error

FreeVNetAddressRange free an address range from the virtual network with the given ID.

func (VNetService) HoldVNet

func (s VNetService) HoldVNet(ctx context.Context, id int, req hc.HoldVNetRequest) (*hc.HoldVNetResponse, error)

HoldVNet holds the virtual network with the given ID.

func (VNetService) InstantiateVNetTemplate

InstantiateVNetTemplate instantiates the virtual network template with the given ID.

func (VNetService) LockVNet

func (s VNetService) LockVNet(ctx context.Context, id int, req hc.LockVNetRequest) (*hc.LockVNetResponse, error)

LockVNet locks the virtual network with the given ID.

func (VNetService) LockVNetTemplate

LockVNetTemplate locks the virtual network template with the given ID.

func (VNetService) RecoverVNets

func (s VNetService) RecoverVNets(ctx context.Context, id int, req hc.RecoverVNetRequest) (*hc.RecoverVNetResponse, error)

RecoverVNets recovers the virtual network with the given ID.

func (VNetService) ReleaseVNet

ReleaseVNet releases the virtual network with the given ID.

func (VNetService) RenameVNet

func (s VNetService) RenameVNet(ctx context.Context, id int, req hc.RenameVNetRequest) (*hc.RenameVNetResponse, error)

RenameVNet renames the virtual network with the given ID.

func (VNetService) RenameVNetTemplate

RenameVNetTemplate renames the virtual network template with the given ID.

func (VNetService) ReserveVNet

ReserveVNet reserves the virtual network with the given ID.

func (VNetService) UnlockVNet

func (s VNetService) UnlockVNet(ctx context.Context, id int) (*hc.UnlockVNetResponse, error)

UnlockVNet unlocks the virtual network with the given ID.

func (VNetService) UnlockVNetTemplate

func (s VNetService) UnlockVNetTemplate(ctx context.Context, id int) (*hc.UnlockVNetTemplateResponse, error)

UnlockVNetTemplate unlocks the virtual network template with the given ID.

func (VNetService) UpdateVNet

func (s VNetService) UpdateVNet(ctx context.Context, id int, req hc.UpdateVNetRequest) (*hc.UpdateVNetResponse, error)

UpdateVNet updates the virtual network with the given ID.

func (VNetService) UpdateVNetAddressRange

UpdateVNetAddressRange updates an address range from the virtual network with the given ID.

func (VNetService) UpdateVNetTemplate

UpdateVNetTemplate updates the virtual network template with the given ID.

func (VNetService) VNet

func (s VNetService) VNet(ctx context.Context, id int) (*hc.ListVNetResponse, error)

VNet returns information about a virtual network.

func (VNetService) VNetTemplate

func (s VNetService) VNetTemplate(ctx context.Context, id int) (*hc.ListVNetTemplateResponse, error)

VNetTemplate returns information about a virtual networks.

func (VNetService) VNetTemplates

func (s VNetService) VNetTemplates(ctx context.Context) (*hc.ListVNetTemplatesResponse, error)

VNetTemplates returns information about all virtual networkss.

func (VNetService) VNets

VNets returns information about all virtual networks.

type VRouterService

type VRouterService struct {
	*client.Client
}

VRouterService own the /vrouter methods.

func (VRouterService) ChangeVRouterOwnership

ChangeVRouterOwnership changes the ownership of a Virtual Router with the given ID.

func (VRouterService) ChangeVRouterPermissions

ChangeVRouterPermissions changes the permissions of a Virtual Router with the given ID.

func (VRouterService) CreateVRouter

CreateVRouter creates a new Virtual Router.

func (VRouterService) CreateVRouterNIC

CreateVRouterNIC creates a new NIC for the Virtual Router with the given ID.

func (VRouterService) DeleteVRouter

func (s VRouterService) DeleteVRouter(ctx context.Context, id int) error

DeleteVRouter deletes a Virtual Router with the given ID.

func (VRouterService) DeleteVRouterNIC

func (s VRouterService) DeleteVRouterNIC(ctx context.Context, id int) error

DeleteVRouterNIC deletes a NIC from the Virtual Router with the given ID.

func (VRouterService) InstantiateVRouter

InstantiateVRouter instantiates a Virtual Router with the given ID.

func (VRouterService) LockVRouter

LockVRouter locks a Virtual Router with the given ID.

func (VRouterService) RenameVRouter

RenameVRouter renames a Virtual Router with the given ID.

func (VRouterService) UnlockVRouter

func (s VRouterService) UnlockVRouter(ctx context.Context, id int) (*hc.UnlockVRouterResponse, error)

UnlockVRouter unlocks a Virtual Router with the given ID.

func (VRouterService) UpdateVRouter

UpdateVRouter updates a Virtual Router with the given ID.

func (VRouterService) VRouter

func (s VRouterService) VRouter(ctx context.Context, id int) (*hc.ListVRouterResponse, error)

VRouter returns information about a vrouter.

func (VRouterService) VRouters

VRouters returns information about all vrouters.

type VirtualDataCenterService

type VirtualDataCenterService struct {
	*client.Client
}

VirtualDataCenterService owns the /vdc methods.

func (VirtualDataCenterService) AddVirtualDataCenterCluster

func (s VirtualDataCenterService) AddVirtualDataCenterCluster(ctx context.Context, id, zone, cluster int) (*hc.AddVDCClusterResponse, error)

AddVirtualDataCenterCluster adds a cluster to the VDC with the given ID.

func (VirtualDataCenterService) AddVirtualDataCenterDatastore

func (s VirtualDataCenterService) AddVirtualDataCenterDatastore(ctx context.Context, id, zone, datastore int) (*hc.AddVDCDatastoreResponse, error)

AddVirtualDataCenterDatastore adds a datastore to the VDC with the given ID.

func (VirtualDataCenterService) AddVirtualDataCenterGroup

func (s VirtualDataCenterService) AddVirtualDataCenterGroup(ctx context.Context, id int) (*hc.AddVDCGroupResponse, error)

AddVirtualDataCenterGroup adds a group to the VDC with the given ID.

func (VirtualDataCenterService) AddVirtualDataCenterHost

func (s VirtualDataCenterService) AddVirtualDataCenterHost(ctx context.Context, id, zone, host int) (*hc.AddVDCHostResponse, error)

AddVirtualDataCenterHost adds a host to the VDC with the given ID.

func (VirtualDataCenterService) AddVirtualDataCenterNetwork

func (s VirtualDataCenterService) AddVirtualDataCenterNetwork(ctx context.Context, id, zone, network int) (*hc.AddVDCNetworkResponse, error)

AddVirtualDataCenterNetwork adds a network to the VDC with the given ID.

func (VirtualDataCenterService) CreateVirtualDataCenter

func (s VirtualDataCenterService) CreateVirtualDataCenter(ctx context.Context, req hc.CreateVDCRequest) (*hc.CreateVDCResponse, error)

CreateVirtualDataCenter creates a new VDC.

func (VirtualDataCenterService) DeleteVirtualDataCenter

func (s VirtualDataCenterService) DeleteVirtualDataCenter(ctx context.Context, id int) error

DeleteVirtualDataCenter deletes the VDC with the given ID.

func (VirtualDataCenterService) RemoveVDCCluster

func (s VirtualDataCenterService) RemoveVDCCluster(ctx context.Context, id, zone, cluster int) error

RemoveVDCCluster removes a cluster from the VDC with the given ID.

func (VirtualDataCenterService) RemoveVDCDatastore

func (s VirtualDataCenterService) RemoveVDCDatastore(ctx context.Context, id, zone, datastore int) error

RemoveVDCDatastore removes a datastore from the VDC with the given ID.

func (VirtualDataCenterService) RemoveVDCGroup

func (s VirtualDataCenterService) RemoveVDCGroup(ctx context.Context, id, group int) error

RemoveVDCGroup removes a group from the VDC with the given ID.

func (VirtualDataCenterService) RemoveVDCHost

func (s VirtualDataCenterService) RemoveVDCHost(ctx context.Context, id, zone, host int) error

RemoveVDCHost removes a host from the VDC with the given ID.

func (VirtualDataCenterService) RemoveVDCNetwork

func (s VirtualDataCenterService) RemoveVDCNetwork(ctx context.Context, id, zone, network int) error

RemoveVDCNetwork removes a network from the VDC with the given ID.

func (VirtualDataCenterService) RenameVirtualDataCenter

func (s VirtualDataCenterService) RenameVirtualDataCenter(ctx context.Context, id int, req hc.RenameVDCRequest) (*hc.RenameVDCResponse, error)

RenameVirtualDataCenter renames the VDC with the given ID.

func (VirtualDataCenterService) UpdateVirtualDataCenter

func (s VirtualDataCenterService) UpdateVirtualDataCenter(ctx context.Context, id int, req hc.UpdateVDCRequest) (*hc.UpdateVDCResponse, error)

UpdateVirtualDataCenter updates the VDC with the given ID.

func (VirtualDataCenterService) VirtualDataCenter

func (s VirtualDataCenterService) VirtualDataCenter(ctx context.Context, id int) (*hc.ListVDCResponse, error)

VirtualDataCenter returns information about a vdc.

func (VirtualDataCenterService) VirtualDataCenters

func (s VirtualDataCenterService) VirtualDataCenters(ctx context.Context) (*hc.ListVDCsResponse, error)

VirtualDataCenters returns information about all vdcs.

type ZoneService

type ZoneService struct {
	*client.Client
}

ZoneService owns the /zone methods.

func (ZoneService) CreateZone

CreateZone creates a new zone.

func (ZoneService) DeleteZone

func (s ZoneService) DeleteZone(ctx context.Context, id int) error

DeleteZone deletes the zone with the given ID.

func (ZoneService) EnableZone

func (s ZoneService) EnableZone(ctx context.Context, id int, req hc.EnableZoneRequest) (*hc.EnableZoneResponse, error)

EnableZone enables the zone with the given ID.

func (ZoneService) RenameZone

func (s ZoneService) RenameZone(ctx context.Context, id int, req hc.RenameZoneRequest) (*hc.RenameZoneResponse, error)

RenameZone renames the zone with the given ID.

func (ZoneService) UpdateZone

func (s ZoneService) UpdateZone(ctx context.Context, id int, req hc.UpdateZoneRequest) (*hc.UpdateZoneResponse, error)

UpdateZone updates the zone with the given ID.

func (ZoneService) Zone

func (s ZoneService) Zone(ctx context.Context, id int) (*hc.ListZoneResponse, error)

Zone returns information about a zone.

func (ZoneService) Zones

Zones returns information about all zones.

func (ZoneService) ZonesRaftStatus

func (s ZoneService) ZonesRaftStatus(ctx context.Context) (*hc.ListZonesRaftStatusResponse, error)

ZonesRaftStatus returns the raft status for all zones.

Jump to

Keyboard shortcuts

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