mirror of https://github.com/status-im/go-waku.git
Jakub Sokołowski
a4009b70d1
Use of `statusim.net` domain been deprecated since March: https://github.com/status-im/infra-shards/commit/7df38c14 Signed-off-by: Jakub Sokołowski <jakub@status.im> |
||
---|---|---|
.. | ||
waku-csharp | ||
.gitignore | ||
README.md | ||
waku-csharp.sln |
README.md
C Sharp Example
Requirements
- git bash (which is installed as part of Git)
- chocolatey
- make
- mingw
- go
Running this example
These instructions should be executed in git bash:
# Clone the repository
git clone https://github.com/waku-org/go-waku.git
cd go-waku
# Build the .dll
make dynamic-library
# Copy the library into `libs/` folder
cp ./build/lib/libgowaku.* ./build/examples/waku-csharp/waku-csharp/libs/.
Open the solution waku-csharp.sln
in Visual Studio and run the program.
Description
The following files are available:
Program.cs
contains an example program which uses the waku libraryWaku.cs
: file containing theWaku
namespace with classes that allows you to instantiate a Go-Waku nodeWaku.Config
: class used to configure the waku node when instantiationWaku.Node
: waku node. The following methods are available:Node
- constructor. Initializes a waku node. Receives an optionalWaku.Config
Start
- mounts all the waku2 protocolsStop
- stops the waku nodePeerId
- obtain the peer ID of the node.PeerCnt
- obtain the number of connected peersListenAddresses
- obtain the multiaddresses the node is listening to
Help wanted!
- Is it possible to build go-waku automatically by executing
make dynamic-library
and copying the .dll automatically intolibs/
in Visual Studio?