Added basic loading of metadata.
- Added InvalidMetadataException.
- Initial work on loading and validating metadata.