Preferences model

New preferences model implementation that features JSON-based preferences, path-based preferences files and notifications for changes.