virtualnetwork

package
v46.4.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Sep 25, 2020 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package virtualnetwork provides a client for Virtual Networks.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddressSpace

type AddressSpace struct {
	AddressPrefix []string
}

type DNS

type DNS struct {
	DNSServers []DNSServer `xml:"DnsServers>DnsServer,omitempty"`
}

type DNSServer

type DNSServer struct {
	XMLName   xml.Name `xml:"DnsServer"`
	Name      string   `xml:"name,attr"`
	IPAddress string   `xml:"IPAddress,attr"`
}

type DNSServerRef

type DNSServerRef struct {
	Name string `xml:"name,attr"`
}

type LocalNetworkSite

type LocalNetworkSite struct {
	Name              string `xml:"name,attr"`
	VPNGatewayAddress string
	AddressSpace      AddressSpace
}

type NetworkConfiguration

type NetworkConfiguration struct {
	XMLName         xml.Name                    `xml:"NetworkConfiguration"`
	XMLNamespaceXsd string                      `xml:"xmlns:xsd,attr"`
	XMLNamespaceXsi string                      `xml:"xmlns:xsi,attr"`
	XMLNs           string                      `xml:"xmlns,attr"`
	Configuration   VirtualNetworkConfiguration `xml:"VirtualNetworkConfiguration"`
}

NetworkConfiguration represents the network configuration for an entire Azure subscription.

type Subnet

type Subnet struct {
	Name          string `xml:"name,attr"`
	AddressPrefix string
}

type VirtualNetworkClient

type VirtualNetworkClient struct {
	// contains filtered or unexported fields
}

VirtualNetworkClient is used to perform operations on Virtual Networks.

func NewClient

func NewClient(client management.Client) VirtualNetworkClient

NewClient is used to return new VirtualNetworkClient instance

func (VirtualNetworkClient) GetVirtualNetworkConfiguration

func (c VirtualNetworkClient) GetVirtualNetworkConfiguration() (NetworkConfiguration, error)

GetVirtualNetworkConfiguration retreives the current virtual network configuration for the currently active subscription. Note that the underlying Azure API means that network related operations are not safe for running concurrently.

func (*VirtualNetworkClient) NewNetworkConfiguration

func (client *VirtualNetworkClient) NewNetworkConfiguration() NetworkConfiguration

NewNetworkConfiguration creates a new empty NetworkConfiguration structure for further configuration. The XML namespaces are already set correctly.

func (VirtualNetworkClient) SetVirtualNetworkConfiguration

func (c VirtualNetworkClient) SetVirtualNetworkConfiguration(networkConfiguration NetworkConfiguration) (management.OperationID, error)

SetVirtualNetworkConfiguration configures the virtual networks for the currently active subscription according to the NetworkConfiguration given. Note that the underlying Azure API means that network related operations are not safe for running concurrently.

type VirtualNetworkConfiguration

type VirtualNetworkConfiguration struct {
	DNS                 DNS                  `xml:"Dns,omitempty"`
	LocalNetworkSites   []LocalNetworkSite   `xml:"LocalNetworkSites>LocalNetworkSite"`
	VirtualNetworkSites []VirtualNetworkSite `xml:"VirtualNetworkSites>VirtualNetworkSite"`
}

type VirtualNetworkSite

type VirtualNetworkSite struct {
	Name          string         `xml:"name,attr"`
	Location      string         `xml:"Location,attr"`
	AddressSpace  AddressSpace   `xml:"AddressSpace"`
	Subnets       []Subnet       `xml:"Subnets>Subnet"`
	DNSServersRef []DNSServerRef `xml:"DnsServersRef>DnsServerRef,omitempty"`
}

Jump to

Keyboard shortcuts

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