Documentation
¶
Index ¶
- func ByteArrayToKnxAddress(ctxForModel context.Context, data []byte) driverModel.KnxAddress
- func ByteArrayToString(data []byte, separator string) string
- func CustomMessageHandling(localLog zerolog.Logger) _default.CustomMessageHandler
- func GroupAddressToString(groupAddress driverModel.KnxGroupAddress) (string, error)
- func KnxAddressToByteArray(knxAddress driverModel.KnxAddress) []byte
- func KnxAddressToString(knxAddress driverModel.KnxAddress) string
- func NumericGroupAddressToString(numericAddress uint16, groupAddress GroupAddressTag) (string, error)
- func Uint16ToKnxAddress(data uint16) driverModel.KnxAddress
- func Uint16ToKnxGroupAddress(ctxForModel context.Context, data uint16, numLevels uint8) driverModel.KnxGroupAddress
- type Browser
- type CommunicationObjectQuery
- type Connection
- func (m *Connection) BlockingClose()
- func (m *Connection) BrowseRequestBuilder() apiModel.PlcBrowseRequestBuilder
- func (m *Connection) Close() <-chan plc4go.PlcConnectionCloseResult
- func (m *Connection) Connect() <-chan plc4go.PlcConnectionConnectResult
- func (m *Connection) ConnectWithContext(ctx context.Context) <-chan plc4go.PlcConnectionConnectResult
- func (m *Connection) DeviceAuthenticate(ctx context.Context, targetAddress driverModel.KnxAddress, buildingKey []byte) <-chan KnxDeviceAuthenticateResult
- func (m *Connection) DeviceConnect(ctx context.Context, targetAddress driverModel.KnxAddress) <-chan KnxDeviceConnectResult
- func (m *Connection) DeviceDisconnect(ctx context.Context, targetAddress driverModel.KnxAddress) <-chan KnxDeviceDisconnectResult
- func (m *Connection) DeviceReadMemory(ctx context.Context, targetAddress driverModel.KnxAddress, address uint16, ...) <-chan KnxReadResult
- func (m *Connection) DeviceReadProperty(ctx context.Context, targetAddress driverModel.KnxAddress, objectId uint8, ...) <-chan KnxReadResult
- func (m *Connection) DeviceReadPropertyDescriptor(ctx context.Context, targetAddress driverModel.KnxAddress, objectId uint8, ...) <-chan KnxReadResult
- func (m *Connection) GetConnectionId() string
- func (m *Connection) GetMetadata() apiModel.PlcConnectionMetadata
- func (m *Connection) GetPlcTagHandler() spi.PlcTagHandler
- func (m *Connection) GetPlcValueHandler() spi.PlcValueHandler
- func (m *Connection) GetTracer() tracer.Tracer
- func (m *Connection) GetTransportInstance() transports.TransportInstance
- func (m *Connection) IsConnected() bool
- func (m *Connection) IsTraceEnabled() bool
- func (m *Connection) Ping() <-chan plc4go.PlcConnectionPingResult
- func (m *Connection) ReadGroupAddress(ctx context.Context, groupAddress []byte, ...) <-chan KnxReadResult
- func (m *Connection) ReadRequestBuilder() apiModel.PlcReadRequestBuilder
- func (m *Connection) String() string
- func (m *Connection) SubscriptionRequestBuilder() apiModel.PlcSubscriptionRequestBuilder
- func (m *Connection) UnsubscriptionRequestBuilder() apiModel.PlcUnsubscriptionRequestBuilder
- func (m *Connection) WriteRequestBuilder() apiModel.PlcWriteRequestBuilder
- type ConnectionMetadata
- func (m *ConnectionMetadata) CanBrowse() bool
- func (m *ConnectionMetadata) CanRead() bool
- func (m *ConnectionMetadata) CanSubscribe() bool
- func (m *ConnectionMetadata) CanWrite() bool
- func (m *ConnectionMetadata) GetConnectionAttributes() map[string]string
- func (d *ConnectionMetadata) Serialize() ([]byte, error)
- func (d *ConnectionMetadata) SerializeWithWriteBuffer(ctx context.Context, writeBuffer utils.WriteBuffer) error
- func (d *ConnectionMetadata) String() string
- type DeviceMemoryAddressPlcTag
- type DevicePropertyAddressPlcTag
- type DeviceQuery
- type DeviceTag
- type Discoverer
- type Driver
- func (d *Driver) CheckQuery(query string) error
- func (d *Driver) DiscoverWithContext(ctx context.Context, callback func(event apiModel.PlcDiscoveryItem), ...) error
- func (d *Driver) GetConnectionWithContext(ctx context.Context, transportUrl url.URL, ...) <-chan plc4go.PlcConnectionConnectResult
- func (d *Driver) SupportsDiscovery() bool
- type GroupAddress1LevelPlcTag
- func (k GroupAddress1LevelPlcTag) GetAddressString() string
- func (k GroupAddress1LevelPlcTag) GetArrayInfo() []apiModel.ArrayInfo
- func (k GroupAddress1LevelPlcTag) GetTagType() *driverModel.KnxDatapointType
- func (k GroupAddress1LevelPlcTag) GetValueType() values.PlcValueType
- func (k GroupAddress1LevelPlcTag) IsPatternTag() bool
- type GroupAddress2LevelPlcTag
- func (k GroupAddress2LevelPlcTag) GetAddressString() string
- func (k GroupAddress2LevelPlcTag) GetArrayInfo() []apiModel.ArrayInfo
- func (k GroupAddress2LevelPlcTag) GetTagType() *driverModel.KnxDatapointType
- func (k GroupAddress2LevelPlcTag) GetValueType() values.PlcValueType
- func (k GroupAddress2LevelPlcTag) IsPatternTag() bool
- type GroupAddress3LevelPlcTag
- func (k GroupAddress3LevelPlcTag) GetAddressString() string
- func (k GroupAddress3LevelPlcTag) GetArrayInfo() []apiModel.ArrayInfo
- func (k GroupAddress3LevelPlcTag) GetTagType() *driverModel.KnxDatapointType
- func (k GroupAddress3LevelPlcTag) GetValueType() values.PlcValueType
- func (k GroupAddress3LevelPlcTag) IsPatternTag() bool
- type GroupAddressTag
- type InternalResult
- type KnxDeviceAuthenticateResult
- type KnxDeviceConnectResult
- type KnxDeviceConnection
- type KnxDeviceDisconnectResult
- type KnxMemoryReadFragment
- type KnxReadResult
- type MessageCodec
- func (m *MessageCodec) GetCodec() spi.MessageCodec
- func (m *MessageCodec) Receive() (spi.Message, error)
- func (m *MessageCodec) Send(message spi.Message) error
- func (d *MessageCodec) Serialize() ([]byte, error)
- func (d *MessageCodec) SerializeWithWriteBuffer(ctx context.Context, writeBuffer utils.WriteBuffer) error
- func (d *MessageCodec) String() string
- type Reader
- type Subscriber
- func (s *Subscriber) Register(consumer apiModel.PlcSubscriptionEventConsumer, ...) apiModel.PlcConsumerRegistration
- func (d *Subscriber) Serialize() ([]byte, error)
- func (d *Subscriber) SerializeWithWriteBuffer(ctx context.Context, writeBuffer utils.WriteBuffer) error
- func (d *Subscriber) String() string
- func (s *Subscriber) Subscribe(ctx context.Context, subscriptionRequest apiModel.PlcSubscriptionRequest) <-chan apiModel.PlcSubscriptionRequestResult
- func (s *Subscriber) Unregister(registration apiModel.PlcConsumerRegistration)
- func (s *Subscriber) Unsubscribe(ctx context.Context, unsubscriptionRequest apiModel.PlcUnsubscriptionRequest) <-chan apiModel.PlcUnsubscriptionRequestResult
- type SubscriptionEvent
- type SubscriptionHandle
- type Tag
- type TagHandler
- type ValueDecoder
- type ValueHandler
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ByteArrayToKnxAddress ¶
func ByteArrayToKnxAddress(ctxForModel context.Context, data []byte) driverModel.KnxAddress
func ByteArrayToString ¶
func CustomMessageHandling ¶
func GroupAddressToString ¶
func GroupAddressToString(groupAddress driverModel.KnxGroupAddress) (string, error)
func KnxAddressToByteArray ¶
func KnxAddressToByteArray(knxAddress driverModel.KnxAddress) []byte
func KnxAddressToString ¶
func KnxAddressToString(knxAddress driverModel.KnxAddress) string
func NumericGroupAddressToString ¶
func NumericGroupAddressToString(numericAddress uint16, groupAddress GroupAddressTag) (string, error)
func Uint16ToKnxAddress ¶
func Uint16ToKnxAddress(data uint16) driverModel.KnxAddress
func Uint16ToKnxGroupAddress ¶
func Uint16ToKnxGroupAddress(ctxForModel context.Context, data uint16, numLevels uint8) driverModel.KnxGroupAddress
Types ¶
type Browser ¶
type Browser struct { _default.DefaultBrowser // contains filtered or unexported fields }
func NewBrowser ¶
func NewBrowser(connection *Connection, messageCodec spi.MessageCodec, _options ...options.WithOption) *Browser
func (Browser) BrowseQuery ¶
func (m Browser) BrowseQuery(ctx context.Context, interceptor func(result apiModel.PlcBrowseItem) bool, _ string, query apiModel.PlcQuery) (apiModel.PlcResponseCode, []apiModel.PlcBrowseItem)
type CommunicationObjectQuery ¶
type CommunicationObjectQuery struct { apiModel.PlcQuery MainGroup uint8 // 5 Bits: Values 0-31 MiddleGroup uint8 // 3 Bits: values 0-7 SubGroup uint8 // 8 Bits DeviceTag }
func NewCommunicationObjectQuery ¶
func NewCommunicationObjectQuery(mainGroup uint8, middleGroup uint8, subGroup uint8) CommunicationObjectQuery
func (CommunicationObjectQuery) GetAddressString ¶
func (k CommunicationObjectQuery) GetAddressString() string
func (CommunicationObjectQuery) GetArrayInfo ¶
func (k CommunicationObjectQuery) GetArrayInfo() []apiModel.ArrayInfo
func (CommunicationObjectQuery) GetQueryString ¶
func (k CommunicationObjectQuery) GetQueryString() string
func (CommunicationObjectQuery) GetValueType ¶
func (k CommunicationObjectQuery) GetValueType() values.PlcValueType
type Connection ¶
type Connection struct { GatewayKnxAddress driverModel.KnxAddress ClientKnxAddress driverModel.KnxAddress CommunicationChannelId uint8 SequenceCounter int32 TunnelingRequestExpectationId int32 DeviceConnections map[driverModel.KnxAddress]*KnxDeviceConnection sync.Mutex // contains filtered or unexported fields }
func NewConnection ¶
func NewConnection(transportInstance transports.TransportInstance, connectionOptions map[string][]string, tagHandler spi.PlcTagHandler, _options ...options.WithOption) *Connection
func (*Connection) BlockingClose ¶
func (m *Connection) BlockingClose()
func (*Connection) BrowseRequestBuilder ¶
func (m *Connection) BrowseRequestBuilder() apiModel.PlcBrowseRequestBuilder
func (*Connection) Close ¶
func (m *Connection) Close() <-chan plc4go.PlcConnectionCloseResult
func (*Connection) Connect ¶
func (m *Connection) Connect() <-chan plc4go.PlcConnectionConnectResult
func (*Connection) ConnectWithContext ¶
func (m *Connection) ConnectWithContext(ctx context.Context) <-chan plc4go.PlcConnectionConnectResult
func (*Connection) DeviceAuthenticate ¶
func (m *Connection) DeviceAuthenticate(ctx context.Context, targetAddress driverModel.KnxAddress, buildingKey []byte) <-chan KnxDeviceAuthenticateResult
func (*Connection) DeviceConnect ¶
func (m *Connection) DeviceConnect(ctx context.Context, targetAddress driverModel.KnxAddress) <-chan KnxDeviceConnectResult
func (*Connection) DeviceDisconnect ¶
func (m *Connection) DeviceDisconnect(ctx context.Context, targetAddress driverModel.KnxAddress) <-chan KnxDeviceDisconnectResult
func (*Connection) DeviceReadMemory ¶
func (m *Connection) DeviceReadMemory(ctx context.Context, targetAddress driverModel.KnxAddress, address uint16, numElements uint8, datapointType *driverModel.KnxDatapointType) <-chan KnxReadResult
func (*Connection) DeviceReadProperty ¶
func (m *Connection) DeviceReadProperty(ctx context.Context, targetAddress driverModel.KnxAddress, objectId uint8, propertyId uint8, propertyIndex uint16, numElements uint8) <-chan KnxReadResult
func (*Connection) DeviceReadPropertyDescriptor ¶
func (m *Connection) DeviceReadPropertyDescriptor(ctx context.Context, targetAddress driverModel.KnxAddress, objectId uint8, propertyId uint8) <-chan KnxReadResult
func (*Connection) GetConnectionId ¶
func (m *Connection) GetConnectionId() string
func (*Connection) GetMetadata ¶
func (m *Connection) GetMetadata() apiModel.PlcConnectionMetadata
func (*Connection) GetPlcTagHandler ¶
func (m *Connection) GetPlcTagHandler() spi.PlcTagHandler
func (*Connection) GetPlcValueHandler ¶
func (m *Connection) GetPlcValueHandler() spi.PlcValueHandler
func (*Connection) GetTracer ¶
func (m *Connection) GetTracer() tracer.Tracer
func (*Connection) GetTransportInstance ¶
func (m *Connection) GetTransportInstance() transports.TransportInstance
func (*Connection) IsConnected ¶
func (m *Connection) IsConnected() bool
func (*Connection) IsTraceEnabled ¶
func (m *Connection) IsTraceEnabled() bool
func (*Connection) Ping ¶
func (m *Connection) Ping() <-chan plc4go.PlcConnectionPingResult
func (*Connection) ReadGroupAddress ¶
func (m *Connection) ReadGroupAddress(ctx context.Context, groupAddress []byte, datapointType *driverModel.KnxDatapointType) <-chan KnxReadResult
func (*Connection) ReadRequestBuilder ¶
func (m *Connection) ReadRequestBuilder() apiModel.PlcReadRequestBuilder
func (*Connection) String ¶
func (m *Connection) String() string
func (*Connection) SubscriptionRequestBuilder ¶
func (m *Connection) SubscriptionRequestBuilder() apiModel.PlcSubscriptionRequestBuilder
func (*Connection) UnsubscriptionRequestBuilder ¶
func (m *Connection) UnsubscriptionRequestBuilder() apiModel.PlcUnsubscriptionRequestBuilder
func (*Connection) WriteRequestBuilder ¶
func (m *Connection) WriteRequestBuilder() apiModel.PlcWriteRequestBuilder
type ConnectionMetadata ¶
type ConnectionMetadata struct { KnxMedium driverModel.KnxMedium `stringer:"true"` GatewayName string GatewayKnxAddress string ClientKnxAddress string ProjectNumber uint8 InstallationNumber uint8 DeviceSerialNumber []byte DeviceMulticastAddress []byte DeviceMacAddress []byte SupportedServices []string }
func (*ConnectionMetadata) CanBrowse ¶
func (m *ConnectionMetadata) CanBrowse() bool
func (*ConnectionMetadata) CanRead ¶
func (m *ConnectionMetadata) CanRead() bool
func (*ConnectionMetadata) CanSubscribe ¶
func (m *ConnectionMetadata) CanSubscribe() bool
func (*ConnectionMetadata) CanWrite ¶
func (m *ConnectionMetadata) CanWrite() bool
func (*ConnectionMetadata) GetConnectionAttributes ¶
func (m *ConnectionMetadata) GetConnectionAttributes() map[string]string
func (*ConnectionMetadata) Serialize ¶
func (d *ConnectionMetadata) Serialize() ([]byte, error)
func (*ConnectionMetadata) SerializeWithWriteBuffer ¶
func (d *ConnectionMetadata) SerializeWithWriteBuffer(ctx context.Context, writeBuffer utils.WriteBuffer) error
func (*ConnectionMetadata) String ¶
func (d *ConnectionMetadata) String() string
type DeviceMemoryAddressPlcTag ¶
type DeviceMemoryAddressPlcTag struct { MainGroup uint8 // 5 Bits: Values 0-31 MiddleGroup uint8 // 3 Bits: values 0-7 SubGroup uint8 // 8 Bits Address uint16 NumElements uint8 TagType *driverModel.KnxDatapointType DeviceTag }
func NewDeviceMemoryAddressPlcTag ¶
func NewDeviceMemoryAddressPlcTag(mainGroup uint8, middleGroup uint8, subGroup uint8, address uint16, numElements uint8, tagType *driverModel.KnxDatapointType) DeviceMemoryAddressPlcTag
func (DeviceMemoryAddressPlcTag) GetAddressString ¶
func (k DeviceMemoryAddressPlcTag) GetAddressString() string
func (DeviceMemoryAddressPlcTag) GetArrayInfo ¶
func (k DeviceMemoryAddressPlcTag) GetArrayInfo() []apiModel.ArrayInfo
func (DeviceMemoryAddressPlcTag) GetValueType ¶
func (k DeviceMemoryAddressPlcTag) GetValueType() values.PlcValueType
type DevicePropertyAddressPlcTag ¶
type DevicePropertyAddressPlcTag struct { MainGroup uint8 // 5 Bits: Values 0-31 MiddleGroup uint8 // 3 Bits: values 0-7 SubGroup uint8 // 8 Bits ObjectId uint8 PropertyId uint8 PropertyIndex uint16 NumElements uint8 DeviceTag }
func (DevicePropertyAddressPlcTag) GetAddressString ¶
func (k DevicePropertyAddressPlcTag) GetAddressString() string
func (DevicePropertyAddressPlcTag) GetArrayInfo ¶
func (k DevicePropertyAddressPlcTag) GetArrayInfo() []apiModel.ArrayInfo
func (DevicePropertyAddressPlcTag) GetValueType ¶
func (k DevicePropertyAddressPlcTag) GetValueType() values.PlcValueType
type DeviceQuery ¶
type DeviceQuery struct { apiModel.PlcQuery MainGroup string // 5 Bits: Values 0-31 MiddleGroup string // 3 Bits: values 0-7 SubGroup string // 8 Bits }
func NewDeviceQuery ¶
func NewDeviceQuery(mainGroup string, middleGroup string, subGroup string) DeviceQuery
func (DeviceQuery) GetAddressString ¶
func (k DeviceQuery) GetAddressString() string
func (DeviceQuery) GetArrayInfo ¶
func (k DeviceQuery) GetArrayInfo() []apiModel.ArrayInfo
func (DeviceQuery) GetQueryString ¶
func (k DeviceQuery) GetQueryString() string
func (DeviceQuery) GetValueType ¶
func (k DeviceQuery) GetValueType() values.PlcValueType
func (DeviceQuery) String ¶
func (k DeviceQuery) String() string
type Discoverer ¶
type Discoverer struct {
// contains filtered or unexported fields
}
func NewDiscoverer ¶
func NewDiscoverer(_options ...options.WithOption) *Discoverer
func (*Discoverer) Discover ¶
func (d *Discoverer) Discover(ctx context.Context, callback func(event apiModel.PlcDiscoveryItem), discoveryOptions ...options.WithDiscoveryOption) error
type Driver ¶
type Driver struct { _default.DefaultDriver // contains filtered or unexported fields }
func NewDriver ¶
func NewDriver(_options ...options.WithOption) *Driver
func (*Driver) CheckQuery ¶
func (*Driver) DiscoverWithContext ¶
func (d *Driver) DiscoverWithContext(ctx context.Context, callback func(event apiModel.PlcDiscoveryItem), discoveryOptions ...options.WithDiscoveryOption) error
func (*Driver) GetConnectionWithContext ¶
func (*Driver) SupportsDiscovery ¶
type GroupAddress1LevelPlcTag ¶
type GroupAddress1LevelPlcTag struct { GroupAddressTag MainGroup string // 16 Bits TagType *driverModel.KnxDatapointType }
func NewGroupAddress1LevelPlcTag ¶
func NewGroupAddress1LevelPlcTag(mainGroup string, tagType *driverModel.KnxDatapointType) GroupAddress1LevelPlcTag
func (GroupAddress1LevelPlcTag) GetAddressString ¶
func (k GroupAddress1LevelPlcTag) GetAddressString() string
func (GroupAddress1LevelPlcTag) GetArrayInfo ¶
func (k GroupAddress1LevelPlcTag) GetArrayInfo() []apiModel.ArrayInfo
func (GroupAddress1LevelPlcTag) GetTagType ¶
func (k GroupAddress1LevelPlcTag) GetTagType() *driverModel.KnxDatapointType
func (GroupAddress1LevelPlcTag) GetValueType ¶
func (k GroupAddress1LevelPlcTag) GetValueType() values.PlcValueType
func (GroupAddress1LevelPlcTag) IsPatternTag ¶
func (k GroupAddress1LevelPlcTag) IsPatternTag() bool
type GroupAddress2LevelPlcTag ¶
type GroupAddress2LevelPlcTag struct { GroupAddressTag MainGroup string // 5 Bits: Values 0-31 SubGroup string // 11 Bits TagType *driverModel.KnxDatapointType }
func NewGroupAddress2LevelPlcTag ¶
func NewGroupAddress2LevelPlcTag(mainGroup string, subGroup string, tagType *driverModel.KnxDatapointType) GroupAddress2LevelPlcTag
func (GroupAddress2LevelPlcTag) GetAddressString ¶
func (k GroupAddress2LevelPlcTag) GetAddressString() string
func (GroupAddress2LevelPlcTag) GetArrayInfo ¶
func (k GroupAddress2LevelPlcTag) GetArrayInfo() []apiModel.ArrayInfo
func (GroupAddress2LevelPlcTag) GetTagType ¶
func (k GroupAddress2LevelPlcTag) GetTagType() *driverModel.KnxDatapointType
func (GroupAddress2LevelPlcTag) GetValueType ¶
func (k GroupAddress2LevelPlcTag) GetValueType() values.PlcValueType
func (GroupAddress2LevelPlcTag) IsPatternTag ¶
func (k GroupAddress2LevelPlcTag) IsPatternTag() bool
type GroupAddress3LevelPlcTag ¶
type GroupAddress3LevelPlcTag struct { GroupAddressTag MainGroup string // 5 Bits: Values 0-31 MiddleGroup string // 3 Bits: values 0-7 SubGroup string // 8 Bits TagType *driverModel.KnxDatapointType }
func NewGroupAddress3LevelPlcTag ¶
func NewGroupAddress3LevelPlcTag(mainGroup string, middleGroup string, subGroup string, tagType *driverModel.KnxDatapointType) GroupAddress3LevelPlcTag
func (GroupAddress3LevelPlcTag) GetAddressString ¶
func (k GroupAddress3LevelPlcTag) GetAddressString() string
func (GroupAddress3LevelPlcTag) GetArrayInfo ¶
func (k GroupAddress3LevelPlcTag) GetArrayInfo() []apiModel.ArrayInfo
func (GroupAddress3LevelPlcTag) GetTagType ¶
func (k GroupAddress3LevelPlcTag) GetTagType() *driverModel.KnxDatapointType
func (GroupAddress3LevelPlcTag) GetValueType ¶
func (k GroupAddress3LevelPlcTag) GetValueType() values.PlcValueType
func (GroupAddress3LevelPlcTag) IsPatternTag ¶
func (k GroupAddress3LevelPlcTag) IsPatternTag() bool
type GroupAddressTag ¶
type GroupAddressTag interface { Tag GetTagType() *driverModel.KnxDatapointType IsPatternTag() bool // contains filtered or unexported methods }
func CastToGroupAddressTagFromPlcTag ¶
func CastToGroupAddressTagFromPlcTag(plcTag apiModel.PlcTag) (GroupAddressTag, error)
type InternalResult ¶
type InternalResult struct {
// contains filtered or unexported fields
}
type KnxDeviceAuthenticateResult ¶
type KnxDeviceAuthenticateResult struct {
// contains filtered or unexported fields
}
type KnxDeviceConnectResult ¶
type KnxDeviceConnectResult struct {
// contains filtered or unexported fields
}
type KnxDeviceConnection ¶
type KnxDeviceConnection struct {
// contains filtered or unexported fields
}
type KnxDeviceDisconnectResult ¶
type KnxDeviceDisconnectResult struct {
// contains filtered or unexported fields
}
type KnxMemoryReadFragment ¶
type KnxMemoryReadFragment struct {
// contains filtered or unexported fields
}
type KnxReadResult ¶
type KnxReadResult struct {
// contains filtered or unexported fields
}
type MessageCodec ¶
type MessageCodec struct { _default.DefaultCodec // contains filtered or unexported fields }
func NewMessageCodec ¶
func NewMessageCodec(transportInstance transports.TransportInstance, messageInterceptor func(message spi.Message), _options ...options.WithOption) *MessageCodec
func (*MessageCodec) GetCodec ¶
func (m *MessageCodec) GetCodec() spi.MessageCodec
func (*MessageCodec) Serialize ¶
func (d *MessageCodec) Serialize() ([]byte, error)
func (*MessageCodec) SerializeWithWriteBuffer ¶
func (d *MessageCodec) SerializeWithWriteBuffer(ctx context.Context, writeBuffer utils.WriteBuffer) error
func (*MessageCodec) String ¶
func (d *MessageCodec) String() string
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
func NewReader ¶
func NewReader(connection *Connection, _options ...options.WithOption) *Reader
func (Reader) Read ¶
func (m Reader) Read(ctx context.Context, readRequest apiModel.PlcReadRequest) <-chan apiModel.PlcReadRequestResult
type Subscriber ¶
type Subscriber struct {
// contains filtered or unexported fields
}
func NewSubscriber ¶
func NewSubscriber(connection *Connection, _options ...options.WithOption) *Subscriber
func (*Subscriber) Register ¶
func (s *Subscriber) Register(consumer apiModel.PlcSubscriptionEventConsumer, handles []apiModel.PlcSubscriptionHandle) apiModel.PlcConsumerRegistration
func (*Subscriber) Serialize ¶
func (d *Subscriber) Serialize() ([]byte, error)
func (*Subscriber) SerializeWithWriteBuffer ¶
func (d *Subscriber) SerializeWithWriteBuffer(ctx context.Context, writeBuffer utils.WriteBuffer) error
func (*Subscriber) String ¶
func (d *Subscriber) String() string
func (*Subscriber) Subscribe ¶
func (s *Subscriber) Subscribe(ctx context.Context, subscriptionRequest apiModel.PlcSubscriptionRequest) <-chan apiModel.PlcSubscriptionRequestResult
func (*Subscriber) Unregister ¶
func (s *Subscriber) Unregister(registration apiModel.PlcConsumerRegistration)
func (*Subscriber) Unsubscribe ¶
func (s *Subscriber) Unsubscribe(ctx context.Context, unsubscriptionRequest apiModel.PlcUnsubscriptionRequest) <-chan apiModel.PlcUnsubscriptionRequestResult
type SubscriptionEvent ¶
type SubscriptionEvent struct { *spiModel.DefaultPlcSubscriptionEvent // contains filtered or unexported fields }
func NewSubscriptionEvent ¶
func NewSubscriptionEvent( tags map[string]apiModel.PlcTag, types map[string]apiModel.PlcSubscriptionType, intervals map[string]time.Duration, responseCodes map[string]apiModel.PlcResponseCode, addresses map[string][]byte, values map[string]values.PlcValue, _options ...options.WithOption, ) SubscriptionEvent
func (SubscriptionEvent) GetAddress ¶
func (m SubscriptionEvent) GetAddress(name string) string
GetAddress Decode the binary data in the address according to the tag requested
type SubscriptionHandle ¶
type SubscriptionHandle struct { *spiModel.DefaultPlcSubscriptionHandle // contains filtered or unexported fields }
func NewSubscriptionHandle ¶
func NewSubscriptionHandle(subscriber *Subscriber, tagName string, tag Tag, tagType apiModel.PlcSubscriptionType, interval time.Duration) *SubscriptionHandle
type TagHandler ¶
type TagHandler struct {
// contains filtered or unexported fields
}
func NewTagHandler ¶
func NewTagHandler() TagHandler
func (TagHandler) ParseQuery ¶
func (m TagHandler) ParseQuery(query string) (apiModel.PlcQuery, error)
type ValueDecoder ¶
type ValueDecoder struct {
// contains filtered or unexported fields
}
func NewValueDecoder ¶
func NewValueDecoder(rb utils.ReadBuffer) ValueDecoder
type ValueHandler ¶
type ValueHandler struct { }
func NewValueHandler ¶
func NewValueHandler() ValueHandler
func (ValueHandler) NewPlcValue ¶
Source Files
¶
- Browser.go
- Connection.go
- ConnectionDriverSpecificOperations.go
- ConnectionHelper.go
- ConnectionInternalOperations.go
- ConnectionMetadata_plc4xgen.go
- Discoverer.go
- Driver.go
- MessageCodec.go
- MessageCodec_plc4xgen.go
- Query.go
- Reader.go
- Subscriber.go
- Subscriber_plc4xgen.go
- SubscriptionEvent.go
- SubscriptionHandle.go
- Tag.go
- TagHandler.go
- Utils.go
- ValueDecoder.go
- ValueHandler.go
- Writer.go
Click to show internal directories.
Click to hide internal directories.