VLink  2.0.0
A high-performance communication middleware
setter_impl.h 文件参考

Transport-neutral base class for every field-model setter (latest-value writer). 更多...

#include "./node_impl.h"
setter_impl.h 的引用(Include)关系图:
此图展示该文件直接或间接的被哪些文件引用了:

浏览源代码.

class  vlink::SetterImpl
 Field-model writer base shared by every transport-specific setter. 更多...
 

命名空间

 

详细描述

Transport-neutral base class for every field-model setter (latest-value writer).

This is an internal implementation header used by the public Setter template; applications should depend on setter.h. SetterImpl extends NodeImpl with the field-model write semantics: writing overwrites the topic's single tracked value and the backend may notify the setter via a sync callback when a late getter needs the cached value resent.

ImplType
The constructor stamps impl_type with kSetter so the discovery and recording layers correctly identify outgoing field updates.
Lifecycle
  • Constructed by the matching Conf::create_setter().
  • init() / deinit() inherited from NodeImpl bring the transport up.
  • sync() is invoked by the public Setter once the user wires a late-getter sync callback.
  • write() pushes the serialised value to all matched getters.
Role table
Capability Provider
Wire write Subclass override of write()
Late-getter resend Subclass override of sync()
Internal API contract
Method Default Subclass duty
write(const Bytes&) Pure virtual Push frame to transport
sync(SyncCallback&&) Pure virtual Bind late-join callback