Documentation ¶
Index ¶
- Variables
- func DecodeIO(io io.Reader, model interface{}) (err error)
- func FromFile(path string) (r []byte, err error)
- func FromJSONFile(path string, ob interface{}) (err error)
- func GetMD5Hash(text string) string
- func MapInterface(i interface{}) (r map[string]interface{}, err error)
- func MarshalInterface(in interface{}, out interface{}) (err error)
- func OrderUnique(in []string) ([]string, error)
- func ToJSON(p interface{}) string
- func ToPrettyJSON(p interface{}) []byte
- type Client
- func (c *Client) Delete(uri string, response interface{}) error
- func (c *Client) Get(uri string, response interface{}) error
- func (c *Client) LogOut() (err error)
- func (c *Client) Post(uri string, payload interface{}, response interface{}) error
- func (c *Client) Put(uri string, payload interface{}, response interface{}) error
- type Host
- type Login
- type Network
- func (o Network) Fetch() (r model.NetworkResponseWrapper, err error)
- func (o Network) FetchByNetwork(network string) (r model.NetworkResponseWrapper, err error)
- func (o Network) FetchByRef(ref string) (r model.NetworkResponse, err error)
- func (o Network) FetchNextAvailableIP(ref string, count int) (r model.NextAvailable, err error)
- type Range
- func (o Range) Fetch() (r model.RangeResponseWrapper, err error)
- func (o Range) FetchByRange(start string) (r model.RangeResponseWrapper, err error)
- func (o Range) FetchByRef(ref string) (r model.RangeResponse, err error)
- func (o Range) FetchNextAvailableIP(ref string, count int) (r model.NextAvailable, err error)
- type RecordA
- func (o RecordA) Create(req model.RecordACreateRequest) (r string, err error)
- func (o RecordA) Delete(ref string) (r string, err error)
- func (o RecordA) Fetch() (r model.RecordAResponseWrapper, err error)
- func (o RecordA) FetchByIP(ip string) (r model.RecordAResponseWrapper, err error)
- func (o RecordA) FetchByName(name string) (r model.RecordAResponseWrapper, err error)
- func (o RecordA) FetchByRef(ref string) (r model.RecordAResponse, err error)
- func (o RecordA) Modify(ref string, req model.RecordAUpdateRequest) (r string, err error)
- type RecordCname
- func (o RecordCname) Create(req model.RecordCnameCreateRequest) (r string, err error)
- func (o RecordCname) Delete(ref string) (r string, err error)
- func (o RecordCname) Fetch() (r model.RecordCnameResponseWrapper, err error)
- func (o RecordCname) FetchByCanonical(canonical string) (r model.RecordCnameResponseWrapper, err error)
- func (o RecordCname) FetchByName(name string) (r model.RecordCnameResponseWrapper, err error)
- func (o RecordCname) FetchByRef(ref string) (r model.RecordCnameResponse, err error)
- func (o RecordCname) Modify(ref string, req model.RecordCnameUpdateRequest) (r string, err error)
- type RecordHost
- func (o RecordHost) Create(req model.RecordHostCreateRequest) (r string, err error)
- func (o RecordHost) Delete(ref string) (r string, err error)
- func (o RecordHost) Fetch() (r model.RecordHostResponseWrapper, err error)
- func (o RecordHost) FetchByIPAddress(ip string) (r model.RecordHostResponseWrapper, err error)
- func (o RecordHost) FetchByName(name string) (r model.RecordHostResponseWrapper, err error)
- func (o RecordHost) FetchByRef(ref string) (r model.RecordHostResponse, err error)
- func (o RecordHost) Modify(ref string, req model.RecordHostUpdateRequest) (r string, err error)
- type RecordPTR
- func (o RecordPTR) Create(req model.RecordPTRCreateRequest) (r string, err error)
- func (o RecordPTR) Delete(ref string) (r string, err error)
- func (o RecordPTR) Fetch() (r model.RecordPTRResponseWrapper, err error)
- func (o RecordPTR) FetchByIP(ip string) (r model.RecordPTRResponseWrapper, err error)
- func (o RecordPTR) FetchByName(name string) (r model.RecordPTRResponseWrapper, err error)
- func (o RecordPTR) FetchByRef(ref string) (r model.RecordPTRResponse, err error)
- func (o RecordPTR) Modify(ref string, req model.RecordPTRUpdateRequest) (r string, err error)
Constants ¶
This section is empty.
Variables ¶
var ( // WapiVersion is the running WAPI version on infoblox. WapiVersion = "2.7.3" // BaseURI is the base uri for the WAPI. BaseURI = "/wapi/v" + WapiVersion + "/" )
Functions ¶
func FromJSONFile ¶
FromJSONFile converts a file object to a pointer.
func MapInterface ¶
MapInterface creates a map of an interface's top level keys. Values are represented as type interface and can be converted. to string using fmt.Sprint.
func MarshalInterface ¶
func MarshalInterface(in interface{}, out interface{}) (err error)
MarshalInterface converts a generic interface to a pointer.
func OrderUnique ¶
OrderUnique sorts unique keys within a string array.
func ToPrettyJSON ¶
func ToPrettyJSON(p interface{}) []byte
ToPrettyJSON converts interface to bytes.
Types ¶
type Client ¶
Client struct.
type Network ¶
Network stores all methods and objects related to network.
func (Network) Fetch ¶
func (o Network) Fetch() (r model.NetworkResponseWrapper, err error)
Fetch returns all A records.
func (Network) FetchByNetwork ¶
func (o Network) FetchByNetwork(network string) (r model.NetworkResponseWrapper, err error)
FetchByNetwork returns a network based on network.
func (Network) FetchByRef ¶
func (o Network) FetchByRef(ref string) (r model.NetworkResponse, err error)
FetchByRef returns a network based on reference.
func (Network) FetchNextAvailableIP ¶
FetchNextAvailableIP returns next available ips.
type Range ¶
Range stores all methods and objects related to range.
func (Range) Fetch ¶
func (o Range) Fetch() (r model.RangeResponseWrapper, err error)
Fetch returns all A records.
func (Range) FetchByRange ¶
func (o Range) FetchByRange(start string) (r model.RangeResponseWrapper, err error)
FetchByRange returns a range based on range.
func (Range) FetchByRef ¶
func (o Range) FetchByRef(ref string) (r model.RangeResponse, err error)
FetchByRef returns a range based on reference.
func (Range) FetchNextAvailableIP ¶
FetchNextAvailableIP returns next available ips.
type RecordA ¶
RecordA stores all methods and objects related to record:a.
func (RecordA) Create ¶
func (o RecordA) Create(req model.RecordACreateRequest) (r string, err error)
Create creates a record:a resource in infoblox and returns its reference.
func (RecordA) Delete ¶
Delete will delete a record:a resource in infoblox and return its previous reference. WARNING! This will delete the resource without warning.
func (RecordA) Fetch ¶
func (o RecordA) Fetch() (r model.RecordAResponseWrapper, err error)
Fetch returns all A records.
func (RecordA) FetchByIP ¶
func (o RecordA) FetchByIP(ip string) (r model.RecordAResponseWrapper, err error)
FetchByIP returns a record:a based on ip address.
func (RecordA) FetchByName ¶
func (o RecordA) FetchByName(name string) (r model.RecordAResponseWrapper, err error)
FetchByName returns a record:a based on name.
func (RecordA) FetchByRef ¶
func (o RecordA) FetchByRef(ref string) (r model.RecordAResponse, err error)
FetchByRef returns a record:a based on reference.
type RecordCname ¶
RecordCname stores all methods and objects related to record:cname.
func (RecordCname) Create ¶
func (o RecordCname) Create(req model.RecordCnameCreateRequest) (r string, err error)
Create creates a record:cname resource in infoblox and returns its reference.
func (RecordCname) Delete ¶
func (o RecordCname) Delete(ref string) (r string, err error)
Delete will delete a record:cname resource in infoblox and return its previous reference.
func (RecordCname) Fetch ¶
func (o RecordCname) Fetch() (r model.RecordCnameResponseWrapper, err error)
func (RecordCname) FetchByCanonical ¶
func (o RecordCname) FetchByCanonical(canonical string) (r model.RecordCnameResponseWrapper, err error)
FetchByCanonical returns a record:cname based on canonical.
func (RecordCname) FetchByName ¶
func (o RecordCname) FetchByName(name string) (r model.RecordCnameResponseWrapper, err error)
FetchByName returns a record:cname based on name.
func (RecordCname) FetchByRef ¶
func (o RecordCname) FetchByRef(ref string) (r model.RecordCnameResponse, err error)
FetchByRef returns a record:cname based on reference.
func (RecordCname) Modify ¶
func (o RecordCname) Modify(ref string, req model.RecordCnameUpdateRequest) (r string, err error)
Modify updates a record:cname resource in infoblox and returns its reference. This action can potentially change the object reference.
type RecordHost ¶
RecordHost stores all methods and objects related to record:host.
func (RecordHost) Create ¶
func (o RecordHost) Create(req model.RecordHostCreateRequest) (r string, err error)
Create creates a record:host resource in infoblox and returns its reference.
func (RecordHost) Delete ¶
func (o RecordHost) Delete(ref string) (r string, err error)
Delete will delete a record:host resource in infoblox and return its previous reference.
func (RecordHost) Fetch ¶
func (o RecordHost) Fetch() (r model.RecordHostResponseWrapper, err error)
Fetch returns all host records.
func (RecordHost) FetchByIPAddress ¶
func (o RecordHost) FetchByIPAddress(ip string) (r model.RecordHostResponseWrapper, err error)
FetchByIPAddress returns a record:a based on ip address.
func (RecordHost) FetchByName ¶
func (o RecordHost) FetchByName(name string) (r model.RecordHostResponseWrapper, err error)
FetchByName returns a record:host based on name.
func (RecordHost) FetchByRef ¶
func (o RecordHost) FetchByRef(ref string) (r model.RecordHostResponse, err error)
FetchByRef returns a record:host based on reference.
func (RecordHost) Modify ¶
func (o RecordHost) Modify(ref string, req model.RecordHostUpdateRequest) (r string, err error)
Modify updates a record:host resource in infoblox and returns its reference. This action can potentially change the object reference.
type RecordPTR ¶
RecordPTR stores all methods and objects related to record:ptr.
func (RecordPTR) Create ¶
func (o RecordPTR) Create(req model.RecordPTRCreateRequest) (r string, err error)
Create creates a record:ptr resource in infoblox and returns its reference.
func (RecordPTR) Delete ¶
Delete will delete a record:ptr resource in infoblox and return its previous reference. WARNING! This will delete the resource without warning.
func (RecordPTR) Fetch ¶
func (o RecordPTR) Fetch() (r model.RecordPTRResponseWrapper, err error)
Fetch returns all PTR records.
func (RecordPTR) FetchByIP ¶
func (o RecordPTR) FetchByIP(ip string) (r model.RecordPTRResponseWrapper, err error)
FetchByIP returns a record:ptr based on ip address.
func (RecordPTR) FetchByName ¶
func (o RecordPTR) FetchByName(name string) (r model.RecordPTRResponseWrapper, err error)
FetchByName returns a record:ptr based on name.
func (RecordPTR) FetchByRef ¶
func (o RecordPTR) FetchByRef(ref string) (r model.RecordPTRResponse, err error)
FetchByRef returns a record:ptr based on reference.