Caching metaData of the class. This metaData is used to do annotation
checks. Also, cleaned up code a bit.