ManagerInterface mi = de.FeatureModellingTool.FeatureModel.Manager.getInstance();
mi.getContext().putValue(de.FeatureModellingTool.FeatureModel.Manager.NAME_CONTEXT, " ");
mi.getContext().putValue(de.FeatureModellingTool.FeatureModel.Manager.DESCRIPTION_CONTEXT, " ");
FComponent featureModel = null;
try {
featureModel = (FComponent) mi.getInstance(de.FeatureModellingTool.FeatureModel.Manager.FEATURE_MODEL_NAME, FComponent.class);
} catch (IllegalParameterException ipe) {
}
/** old way
FeatureModel fm = de.FeatureModellingTool.FeatureModel.Manager.createFeatureModel(" ", " ");
FeatureModelEditor fme = de.FeatureModellingTool.FeatureModel.Manager.getFeatureModelEditor(fm);
FeatureEditor fe = de.FeatureModellingTool.FeatureModel.Manager.getFeatureEditor(fm);
FeatureModelPropertyEditor fmpe = de.FeatureModellingTool.FeatureModel.Manager.getFeatureModelPropertyEditor(fm);
**/
//new way
FeatureModel fm = (FeatureModel) featureModel.getInterface(de.FeatureModellingTool.FeatureModel.Manager.FEATURE_MODEL_INTERFACE);
FeatureModelEditor fme = (FeatureModelEditor) featureModel.getInterface(de.FeatureModellingTool.FeatureModel.Manager.FEATURE_MODEL_EDITOR_INTERFACE);
FeatureEditor fe = (FeatureEditor) featureModel.getInterface(de.FeatureModellingTool.FeatureModel.Manager.FEATURE_EDITOR_INTERFACE);
FeatureModelPropertyEditor fmpe = (FeatureModelPropertyEditor) featureModel.getInterface(de.FeatureModellingTool.FeatureModel.Manager.FEATURE_MODEL_PROPERTY_EDITOR_INTERFACE);
//
Namespace fmd = Namespace.getNamespace("fmd", "http://sei.pku.edu.cn/DomainEngineering/featuremodel");
SAXBuilder saxBuilder = new SAXBuilder(false);