GUI -- reworking code to eliminate unnecessary 'ONOS' global.
 - re-package fn and keys factories into util module.

Change-Id: I3d9f50b9a91468140845e862aff3fdb518948774