Move GetAllOutputTypes() to rpc/utils
Summary: Move the function so it can be reused outside of rawtransaction.cpp. This will be later used in the help text of the decodeavalancheproof RPC. There is no change in behavior.
Test Plan:
ninja all check-functional
Reviewers: #bitcoin_abc, PiRK
Reviewed By: #bitcoin_abc, PiRK
Differential Revision: https://reviews.bitcoinabc.org/D10357