README.md
1# src/node/
2
3The [`src/node/`](./) directory contains code that needs to access node state
4(state in `CChain`, `CBlockIndex`, `CCoinsView`, `CTxMemPool`, and similar
5classes).
6
7Code in [`src/node/`](./) is meant to be segregated from code in
8[`src/wallet/`](../wallet/) and [`src/qt/`](../qt/), to ensure wallet and GUI
9code changes don't interfere with node operation, to allow wallet and GUI code
10to run in separate processes, and to perhaps eventually allow wallet and GUI
11code to be maintained in separate source repositories.
12
13As a rule of thumb, code in one of the [`src/node/`](./),
14[`src/wallet/`](../wallet/), or [`src/qt/`](../qt/) directories should avoid
15calling code in the other directories directly, and only invoke it indirectly
16through the more limited [`src/interfaces/`](../interfaces/) classes.
17
18This directory is at the moment
19sparsely populated. Eventually more substantial files like
20[`src/validation.cpp`](../validation.cpp) and
21[`src/txmempool.cpp`](../txmempool.cpp) might be moved there.
22