File::close() sets handle invalid
proper OOP for Library
added exception categories