Prime_wallet: Add mapj and comapj_rev.
Document most of Prime_wallet.