-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Virtualize System::Layer interfaces (#9366)
* Virtualize System::Layer interfaces. #### Problem Issue #7715 _Virtualize System and Inet interfaces_ #### Change overview - Establishes an abstract `System::Layer` class hierarchy, described below. - Converts the transitional `WatchableEventManager` classes into corresponding `LayerImpl` classes. - Move `LwIPEventHandlerDelegate` into `LayerLwIP`. - Remove `GetClock()`, which was only used in one file. (`System::Clock` is currently fully static, but might benefit from its own virtualization, e.g. for test timeouts.) - For the moment, `CHIP_SYSTEM_CONFIG_USE_DISPATCH` is still included by `#if` on `LayerImplSelect`. With some changes to Inet, Dispatch can probably have its own much simpler implementation of `LayerSockets`. The class hierarchy is: - `Layer`: Core timer methods. - `LayerLwIP`: Adds methods specific to builds using `CHIP_SYSTEM_CONFIG_USING_LWIP`. - `LayerImplLwIP`: Concrete implementation of `LayerLwIP`. (This is currently used by all LwIP-based platforms.) - `LayerSockets`: Adds I/O event methods specific to builds using `CHIP_SYSTEM_CONFIG_USING_SOCKETS`. - `LayerSocketsLoop`: Adds methods for event-loop-based implementations. - `LayerImplSelect`: Concrete implementation of `LayerSocketLoop`, using `select()`. (This is currenly used by all sockets-based platforms.) - `LayerImplLibevent`: Concrete implementation of `LayerSocketLoop`, using `libevent`. (This is currenly a demonstration of substitutability, not used by any platform.) #### Testing CI; no changes to functionality. Tests updated where necessary to create concrete `LayerImpl` objects. * remove debug code from SystemPacketBuffer.h
- Loading branch information
1 parent
35a0f1e
commit 1213432
Showing
44 changed files
with
530 additions
and
719 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.