[#wallet-CWalletTx-state-04] = xref:wallet.adoc[wallet]::xref:wallet/CWalletTx.adoc[CWalletTx]::state :relfileprefix: ../../ :mrdocs: Return a pointer to the current state if it is of type T, otherwise nullptr. == Synopsis Declared in `<wallet/transaction.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<typename T> T* state(); ---- == Return Value A pointer to the state if it holds type T, otherwise nullptr. [.small]#Created with https://www.mrdocs.com[MrDocs]#