control

package
v0.0.0-...-904a803 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2018 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Logger *log.Logger

Functions

This section is empty.

Types

type Action

type Action interface {
	// send action request, and provide return value in 'ret'
	Invoke(ret interface{}) error
}

func NewAction

func NewAction(dd *description.DeviceDescription, svc, action string, wait time.Duration) (Action, error)

type Body

type Body struct {
	XMLName xml.Name `xml:"s:Body"`
	Action
}

type Envelope

type Envelope struct {
	XMLName xml.Name `xml:"s:Envelope"`
	XMLNS   string   `xml:"xmlns:s,attr"`
	Body    Body
}

Hack to deal with XML namespace prefixes https://github.com/golang/go/issues/9519

func NewEnvelope

func NewEnvelope() Envelope

type Fault

type Fault struct {
	XMLName          xml.Name `xml:"Fault"`
	FaultCode        string   `xml:"faultcode"`
	FaultString      string   `xml:"faultstring"`
	ErrorCode        string   `xml:"detail>UPnPError>errorCode"`
	ErrorDescription string   `xml:"detail>UPnPError>errorDescription"`
}

func (Fault) Error

func (f Fault) Error() string

type SimpleAction

type SimpleAction struct {
	XMLName xml.Name
	// contains filtered or unexported fields
}

func (*SimpleAction) Invoke

func (a *SimpleAction) Invoke(ret interface{}) error

Jump to

Keyboard shortcuts

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