|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecttuwien.auto.calimero.buffer.StateFilter
public class StateFilter
Predefined filter for filtering KNX messages of datapoints with state semantic into the associated network buffer configuration.
This filter might be used in a configuration to build up and maintain a process image
of the KNX network the used network link communicates with. The buffer will keep the
most up to date state to a KNX group address / datapoint.
KNX messages are buffered using a LDataObject
(an object of this
type is also expected when the request method is invoked).
If a datapoint model is available in the Configuration
, the filter uses that
model in its init(Configuration)
method. It initializes its local lookup
references with necessary updating / invalidating information of other datapoints
stored in that model. Thus, the filter will update or invalidate all other associated
datapoint state values in the network buffer configuration when receiving a new KNX
message.
To reflect subsequent changes of the datapoint model in the filter, the filter has to
be reinitialized (using init(Configuration)
.
Constructor Summary | |
---|---|
StateFilter()
Creates a new state based filter. |
Method Summary | |
---|---|
void |
accept(CEMI frame,
Configuration c)
Applies state based filter rules on frame. |
void |
init(Configuration c)
Does all necessary filter initializations. |
CEMILData |
request(KNXAddress dst,
Configuration c)
Requests data for address dst from the network buffer. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StateFilter()
Method Detail |
---|
public void accept(CEMI frame, Configuration c)
Criteria for accept:
LDataObject
. For easier handling of subsequent read requests on such a
buffered frame, all frames are converted to L-data indications with application
layer group response service code before getting stored.
If update and invalidation information is available, other dependent datapoint state values will be updated or invalidated appropriately.
accept
in interface Configuration.NetworkFilter
frame
- cEMI frame to accept for bufferingc
- the configuration this filter belongs topublic void init(Configuration c)
Configuration.NetworkFilter
This method is invoked by the owning configuration.
init
in interface Configuration.NetworkFilter
c
- the configuration this filter is set forpublic CEMILData request(KNXAddress dst, Configuration c)
Configuration.RequestFilter
dst
from the network buffer.
How a buffer is searched and data is matched depends on the individual filter rules. A filter might use provided information of the configuration if necessary.
request
in interface Configuration.RequestFilter
dst
- address to request data forc
- the configuration this filter belongs to
null
otherwise
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |