Documentation ¶
Overview ¶
Package dahuacgi is a client library for Dahua's CGI API.
Index ¶
- Constants
- func AudioInputChannelCount(ctx context.Context, c Conn) (int, error)
- func AudioOutputChannelCount(ctx context.Context, c Conn) (int, error)
- func OK(res *http.Response, err error) (*http.Response, error)
- type AudioStream
- type Client
- type Conn
- type Event
- type EventBoundary
- type EventManager
- type EventReader
- type HTTPError
- type HTTPType
- type Request
- type Snapshot
- type Table
- type TableData
Constants ¶
View Source
const ( HTTPTypeSinglePart = "singlepart" HTTPTypeMultiPart = "multipart" )
Variables ¶
This section is empty.
Functions ¶
func AudioOutputChannelCount ¶
Types ¶
type AudioStream ¶
type AudioStream struct { io.ReadCloser ContentType string }
func AudioStreamGet ¶
type EventBoundary ¶
type EventBoundary string
const DefaultEventBoundary EventBoundary = "myboundary"
type EventManager ¶
type EventManager struct { io.ReadCloser Boundary EventBoundary }
func EventManagerGet ¶
func (EventManager) Reader ¶
func (em EventManager) Reader() EventReader
type EventReader ¶
type EventReader struct {
// contains filtered or unexported fields
}
func NewEventReader ¶
func NewEventReader(rd io.Reader, boundary EventBoundary) EventReader
func (EventReader) Poll ¶
func (er EventReader) Poll() error
Poll waits for the next event boundary.
func (EventReader) ReadEvent ¶
func (er EventReader) ReadEvent() (Event, error)
ReadEvent reads and parses the next event. This should be called after Poll.
Click to show internal directories.
Click to hide internal directories.