Adds a debug-dump-facts command for dumping the facts.

Facts can be dumped from factsets or snapshots, and
can be filtered by attribute and/or entity.

See #405.

/cc @charleso @nhibberd @domdere @raronson 
I am about to do a PR to delete it, it is totally unacceptable, it just does an unsafe typecast, things will still compile when we fix it. I will do the other PR first before I merge this and fix this up when it lands.