Versions in this module Expand all Collapse all v0 v0.8.0 Jun 5, 2018 Changes in this version + type QueryParams struct v0.7.1 May 31, 2018 v0.7.0 May 31, 2018 Changes in this version type HostRecord + Ipv4Addr string v0.6.0 Apr 26, 2018 Changes in this version + type HostRecord struct + Ea EA + EnableDns *bool + Ipv4Addrs []HostRecordIpv4Addr + Name string + NetworkView string + Ref string + View string + Zone string + func NewHostRecord(rh HostRecord) *HostRecord + type HostRecordIpv4Addr struct + Cidr string + Ipv4Addr string + Mac string + Ref string + View string + func NewHostRecordIpv4Addr(hostAddr HostRecordIpv4Addr) *HostRecordIpv4Addr type ObjectManager + func (objMgr *ObjectManager) CreateHostRecordWithoutDNS(recordName string, netview string, cidr string, ipAddr string, ...) (*HostRecord, error) + func (objMgr *ObjectManager) DeleteHostRecord(ref string) (string, error) + func (objMgr *ObjectManager) GetHostRecord(ref string) (*HostRecord, error) + func (objMgr *ObjectManager) GetHostRecordWithoutDNS(recordName string, netview string, cidr string, ipAddr string) (*HostRecord, error) + func (objMgr *ObjectManager) GetIpAddressFromHostRecord(host HostRecord) (string, error) + func (objMgr *ObjectManager) GetNetworkwithref(ref string) (*Network, error) + func (objMgr *ObjectManager) UpdateHostRecordWithoutDNS(hostRref string, ipAddr string, macAddress string, vmID string) (string, error) v0.5.0 Apr 13, 2018 Changes in this version type FixedAddress + Name string v0.4.0 Mar 26, 2018 v0.3.0 Feb 28, 2018 Changes in this version type Connector + func (c *Connector) Logout() (err error) v0.2.0 Feb 20, 2018 Changes in this version + var ValidateConnector = validateConnector + type CapacityReport struct + HardwareType string + MaxCapacity int + Name string + ObjectCount []map[string]interface{} + PercentUsed int + Ref string + Role string + TotalObjects int + func NewCapcityReport(capReport CapacityReport) *CapacityReport type Connector + HostConfig HostConfig + RequestBuilder HttpRequestBuilder + Requestor HttpRequestor + TransportConfig TransportConfig + func (c *Connector) UpdateObject(obj IBObject, ref string) (refRes string, err error) + type EASearch map[string]interface + func (eas EASearch) MarshalJSON() ([]byte, error) + type Grid struct + NTPSetting *NTPSetting + Name string + Ref string + func NewGrid(grid Grid) *Grid + type HostConfig struct + Host string + Password string + Port string + Username string + Version string + type HttpRequestBuilder interface + BuildBody func(r RequestType, obj IBObject) (jsonStr []byte) + BuildRequest func(r RequestType, obj IBObject, ref string) (req *http.Request, err error) + BuildUrl func(r RequestType, objType string, ref string, returnFields []string) (urlStr string) + Init func(HostConfig) + type HttpRequestor interface + Init func(TransportConfig) + SendRequest func(*http.Request) ([]byte, error) + type IBConnector interface + CreateObject func(obj IBObject) (ref string, err error) + DeleteObject func(ref string) (refRes string, err error) + GetObject func(obj IBObject, ref string, res interface{}) error + UpdateObject func(obj IBObject, ref string) (refRes string, err error) + type IBObjectManager interface + AllocateIP func(netview string, cidr string, ipAddr string, macAddress string, vmID string) (*FixedAddress, error) + AllocateNetwork func(netview string, cidr string, prefixLen uint, name string) (network *Network, err error) + CreateDefaultNetviews func(globalNetview string, localNetview string) (globalNetviewRef string, localNetviewRef string, err error) + CreateEADefinition func(eadef EADefinition) (*EADefinition, error) + CreateNetwork func(netview string, cidr string, name string) (*Network, error) + CreateNetworkContainer func(netview string, cidr string) (*NetworkContainer, error) + CreateNetworkView func(name string) (*NetworkView, error) + DeleteNetwork func(ref string, netview string) (string, error) + GetEADefinition func(name string) (*EADefinition, error) + GetFixedAddress func(netview string, cidr string, ipAddr string, macAddr string) (*FixedAddress, error) + GetNetwork func(netview string, cidr string, ea EA) (*Network, error) + GetNetworkContainer func(netview string, cidr string) (*NetworkContainer, error) + GetNetworkView func(name string) (*NetworkView, error) + ReleaseIP func(netview string, cidr string, ipAddr string, macAddr string) (string, error) + UpdateFixedAddress func(fixedAddrRef string, macAddress string, vmID string) (*FixedAddress, error) + UpdateNetworkViewEA func(ref string, addEA EA, removeEA EA) error + type Ipv6Setting struct + AutoRouterConfigEnabled bool + CidrPrefix uint + Dscp uint + Enabled bool + Gateway string + Primary string + UseDscp bool + VirtualIp string + VlanId uint + type LanHaPortSetting struct + HAIpAddress string + HaPortSetting PhysicalPortSetting + LanPortSetting PhysicalPortSetting + MgmtIpv6addr string + MgmtLan string + type License struct + ExpirationStatus string + ExpiryDate int + HwID string + Key string + Kind string + Licensetype string + Limit string + LimitContext string + Ref string + func NewGridLicense(license License) *License + func NewLicense(license License) *License + type Lock interface + Lock func() error + UnLock func(force bool) error + type Member struct + ConfigAddrType string + HostName string + Nodeinfo []NodeInfo + PLATFORM string + Ref string + ServiceTypeConfiguration string + TimeZone string + func NewMember(member Member) *Member + type MultiRequest struct + Body []*RequestBody + func NewMultiRequest(body []*RequestBody) *MultiRequest + func (r *MultiRequest) MarshalJSON() ([]byte, error) + type NTPSetting struct + EnableNTP bool + NTPAcl map[string]interface{} + NTPKeys []string + NTPKod bool + NTPServers []NTPserver + type NTPserver struct + Address string + Burst bool + EnableAuthentication bool + IBurst bool + NTPKeyNumber uint + Preffered bool + type NetworkSetting struct + Address string + Dscp uint + Gateway string + Primary bool + SubnetMask string + UseDscp bool + VlanId uint + type NetworkViewLock struct + LockEA string + LockTimeoutEA string + Name string + ObjMgr *ObjectManager + func (l *NetworkViewLock) Lock() error + func (l *NetworkViewLock) UnLock(force bool) error + type NodeInfo struct + HaStatus string + HwId string + HwModel string + HwPlatform string + HwType string + Lan2PhysicalSetting PhysicalPortSetting + LanHaPortSetting LanHaPortSetting + MgmtNetworkSetting NetworkSetting + MgmtPhysicalSetting PhysicalPortSetting + PaidNios bool + PhysicalOid string + ServiceStatus []ServiceStatus + V6MgmtNetworkSetting Ipv6Setting type ObjectManager + func (objMgr *ObjectManager) CreateMultiObject(req *MultiRequest) ([]map[string]interface{}, error) + func (objMgr *ObjectManager) GetAllMembers() ([]Member, error) + func (objMgr *ObjectManager) GetCapacityReport(name string) ([]CapacityReport, error) + func (objMgr *ObjectManager) GetGridInfo() ([]Grid, error) + func (objMgr *ObjectManager) GetGridLicense() ([]License, error) + func (objMgr *ObjectManager) GetLicense() ([]License, error) + func (objMgr *ObjectManager) GetUpgradeStatus(statusType string) ([]UpgradeStatus, error) + func (objMgr *ObjectManager) UpdateFixedAddress(fixedAddrRef string, macAddress string, vmID string) (*FixedAddress, error) + func (objMgr *ObjectManager) UpdateNetworkViewEA(ref string, addEA EA, removeEA EA) error + type PhysicalPortSetting struct + AutoPortSettingEnabled bool + Duplex string + Speed string + type RecordA struct + Ea EA + Ipv4Addr string + Name string + Ref string + View string + Zone string + func NewRecordA(ra RecordA) *RecordA + type RecordCNAME struct + Canonical string + Ea EA + Name string + Ref string + View string + Zone string + func NewRecordCNAME(rc RecordCNAME) *RecordCNAME + type RecordHost struct + Ea EA + Ipv4Addr string + Ipv4Addrs []RecordHostIpv4Addr + Name string + Ref string + View string + Zone string + func NewRecordHost(rh RecordHost) *RecordHost + type RecordHostIpv4Addr struct + Ipv4Addr string + type RecordTXT struct + Ea EA + Name string + Ref string + Text string + View string + Zone string + func NewRecordTXT(rt RecordTXT) *RecordTXT + type RequestBody struct + Args map[string]string + AssignState map[string]string + Data map[string]interface{} + Discard bool + EnableSubstitution bool + Method string + Object string + type ServiceStatus struct + Desciption string + Service string + Status string + type SingleRequest struct + Body *RequestBody + func NewRequest(body *RequestBody) *SingleRequest + type SubElementsStatus struct + CurrentVersion string + ElementStatus string + Ipv4Address string + Ipv6Address string + Member string + NodeType string + Ref string + StatusValue string + StepsCompleted int + StepsTotal int + type TransportConfig struct + HttpPoolConnections int + HttpRequestTimeout int + SslVerify bool + func NewTransportConfig(sslVerify string, httpRequestTimeout int, httpPoolConnections int) (cfg TransportConfig) + type UpgradeStatus struct + Ref string + SubElementStatus []SubElementsStatus + Type string + UpgradeGroup string + func NewUpgradeStatus(upgradeStatus UpgradeStatus) *UpgradeStatus + type UserProfile struct + Name string + Ref string + func NewUserProfile(userprofile UserProfile) *UserProfile + type WapiHttpRequestor struct + func (whr *WapiHttpRequestor) Init(cfg TransportConfig) + func (whr *WapiHttpRequestor) SendRequest(req *http.Request) (res []byte, err error) + type WapiRequestBuilder struct + HostConfig HostConfig + func (wrb *WapiRequestBuilder) BuildBody(t RequestType, obj IBObject) []byte + func (wrb *WapiRequestBuilder) BuildRequest(t RequestType, obj IBObject, ref string) (req *http.Request, err error) + func (wrb *WapiRequestBuilder) BuildUrl(t RequestType, objType string, ref string, returnFields []string) (urlStr string) + func (wrb *WapiRequestBuilder) Init(cfg HostConfig) + type ZoneAuth struct + Ea EA + Fqdn string + Ref string + View string + func NewZoneAuth(za ZoneAuth) *ZoneAuth v0.1.0 Jul 13, 2016 Changes in this version + const MACADDR_ZERO + func GetIPAddressFromRef(ref string) string + type Bool bool + func (b Bool) MarshalJSON() ([]byte, error) + type Connector struct + Host string + HttpPoolConnections int + HttpRequestTimeout int + Password string + SslVerify bool + Username string + WapiPort string + WapiVersion string + func NewConnector(host string, wapiVersion string, wapiPort string, username string, ...) (res *Connector, err error) + func (c *Connector) CreateObject(obj IBObject) (ref string, err error) + func (c *Connector) DeleteObject(ref string) (refRes string, err error) + func (c *Connector) GetObject(obj IBObject, ref string, res interface{}) (err error) + type EA map[string]interface + func (ea *EA) UnmarshalJSON(b []byte) (err error) + func (ea EA) MarshalJSON() ([]byte, error) + type EADefListValue string + func (v *EADefListValue) UnmarshalJSON(b []byte) (err error) + func (val EADefListValue) MarshalJSON() ([]byte, error) + type EADefinition struct + AllowedObjectTypes []string + Comment string + Flags string + ListValues []EADefListValue + Name string + Ref string + Type string + func NewEADefinition(eadef EADefinition) *EADefinition + type FixedAddress struct + Cidr string + Ea EA + IPAddress string + Mac string + NetviewName string + Ref string + func NewFixedAddress(fixedAddr FixedAddress) *FixedAddress + type IBBase struct + func (obj *IBBase) EaSearch() EA + func (obj *IBBase) ObjectType() string + func (obj *IBBase) ReturnFields() []string + type IBObject interface + EaSearch func() EA + ObjectType func() string + ReturnFields func() []string + type Network struct + Cidr string + Ea EA + NetviewName string + Ref string + func BuildNetworkFromRef(ref string) *Network + func NewNetwork(nw Network) *Network + type NetworkContainer struct + Cidr string + Ea EA + NetviewName string + Ref string + func NewNetworkContainer(nc NetworkContainer) *NetworkContainer + type NetworkView struct + Ea EA + Name string + Ref string + func BuildNetworkViewFromRef(ref string) *NetworkView + func NewNetworkView(nv NetworkView) *NetworkView + type ObjectManager struct + func NewObjectManager(connector *Connector, cmpType string, tenantID string) *ObjectManager + func (objMgr *ObjectManager) AllocateIP(netview string, cidr string, ipAddr string, macAddress string, vmID string) (*FixedAddress, error) + func (objMgr *ObjectManager) AllocateNetwork(netview string, cidr string, prefixLen uint, name string) (network *Network, err error) + func (objMgr *ObjectManager) CreateDefaultNetviews(globalNetview string, localNetview string) (globalNetviewRef string, localNetviewRef string, err error) + func (objMgr *ObjectManager) CreateEADefinition(eadef EADefinition) (*EADefinition, error) + func (objMgr *ObjectManager) CreateNetwork(netview string, cidr string, name string) (*Network, error) + func (objMgr *ObjectManager) CreateNetworkContainer(netview string, cidr string) (*NetworkContainer, error) + func (objMgr *ObjectManager) CreateNetworkView(name string) (*NetworkView, error) + func (objMgr *ObjectManager) DeleteNetwork(ref string, netview string) (string, error) + func (objMgr *ObjectManager) GetEADefinition(name string) (*EADefinition, error) + func (objMgr *ObjectManager) GetFixedAddress(netview string, cidr string, ipAddr string, macAddr string) (*FixedAddress, error) + func (objMgr *ObjectManager) GetNetwork(netview string, cidr string, ea EA) (*Network, error) + func (objMgr *ObjectManager) GetNetworkContainer(netview string, cidr string) (*NetworkContainer, error) + func (objMgr *ObjectManager) GetNetworkView(name string) (*NetworkView, error) + func (objMgr *ObjectManager) ReleaseIP(netview string, cidr string, ipAddr string, macAddr string) (string, error) + type RequestType int + const CREATE + const DELETE + const GET + const UPDATE