// Get factory
RefClass stereotypeFactory = modelElement.refOutermostPackage().refPackage("Core").
refClass("Stereotype");
// Get all Core.Stereotype
Collection registeredStereotypes = stereotypeFactory.refAllOfClass();
// Get the baseClass
String baseClass = (String)modelElement.refClass().refMetaObject().refGetValue("name");
// Lookup for a matching concept