context.setBeanInfo(info);
// update class scope with class info
repository = kernel.getMetaDataRepository();
// remove old context
repository.removeMetaData(context);
// create new scope key
ScopeInfo scopeInfo = context.getScopeInfo();
ScopeKey scopeKey = new ScopeKey(scopeInfo.getScope().getScopes());
scopeKey.addScope(CommonLevels.CLASS, info.getClassInfo().getType());
scopeInfo.setScope(scopeKey);