Java 类org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory 实例源码

项目:neoscada    文件:PreviewEditorImpl.java   
public PreviewEditorImpl ()
{
    this.adapterFactory = new ComposedAdapterFactory ( ComposedAdapterFactory.Descriptor.Registry.INSTANCE );
    this.adapterFactory.addAdapterFactory ( new ResourceItemProviderAdapterFactory () );
    this.adapterFactory.addAdapterFactory ( new ReflectiveItemProviderAdapterFactory () );

    final BasicCommandStack commandStack = new BasicCommandStack ();

    this.editingDomain = new AdapterFactoryEditingDomain ( this.adapterFactory, commandStack, new HashMap<Resource, Boolean> () );

    this.factoryContext = new FactoryContext () {

        @Override
        public void loadedResource ( final URI uri )
        {
            handleLoadedResource ( uri );
        }
    };

    ResourcesPlugin.getWorkspace ().addResourceChangeListener ( this.resourceChangeListener, IResourceChangeEvent.POST_CHANGE );
}
项目:slr-toolkit    文件:ModelRegistry.java   
private void createEditingDomain() {
    // Create an adapter factory that yields item providers.
    //
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);

    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new BibtexItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());

    // Create the command stack that will notify this editor as commands are
    // executed.
    //
    BasicCommandStack commandStack = new BasicCommandStack();

    // Create the editing domain with a special command stack.
    //
    sharedEditingDomain = new AdapterFactoryEditingDomain(adapterFactory,commandStack, new HashMap<Resource, Boolean>());
}
项目:ModelDebugging    文件:DSLLaunchConfigurationTab.java   
/**
 * Opens the {@link EObject first instruction} selection dialog.
 * 
 * @param shell
 *            the {@link Shell} to use for display
 * @param resourceSet
 *            the {@link ResourceSet} to get the first instruction from
 * @return the selected first instruction {@link URI} if any selected, <code>null</code> otherwise
 */
public static EObject openFirstInstructionSelection(final Shell shell, ResourceSet resourceSet) {
    final EObject res;
    final ComposedAdapterFactory fatory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    fatory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    fatory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());

    ElementTreeSelectionDialog dialog = new ElementTreeSelectionDialog(shell,
            new AdapterFactoryLabelProvider(fatory), new AdapterFactoryContentProvider(fatory));
    dialog.setTitle("Select first instruction");
    dialog.setMessage("Select the first instruction:");
    dialog.setInput(resourceSet);
    if (dialog.open() == Window.OK) {
        res = (EObject)dialog.getFirstResult();
    } else {
        res = null;
    }
    fatory.dispose();
    return res;
}
项目:OpenSPIFe    文件:EMFDetailFormPart.java   
private void createReferenceBinding(Composite parent, EObject target, IItemPropertyDescriptor pd, EReference reference) {
  // Check to see if the EClassifier would like to be displayed
  // in detail. May want to reserve this for EReference types in
  // the future, and should probably check if the object has its
  // own IItemPropertySource
  if (EMFUtils.testBooleanAnnotation(reference, EMFDetailUtils.ANNOTATION_SOURCE_DETAIL, ANNOTATION_DETAIL_INSPECT_REFERENCE)) {
    if (EMFUtils.testBooleanAnnotation(reference, EMFDetailUtils.ANNOTATION_SOURCE_DETAIL, ANNOTATION_DETAIL_INSPECT_REFLECTIVELY)) {
            ReflectiveItemProviderAdapterFactory ripaf = new ReflectiveItemProviderAdapterFactory();
            EObject eObject = (EObject)target.eGet(reference);
            IItemPropertySource source = (IItemPropertySource) ripaf.adapt(eObject, IItemPropertySource.class);
            if (source != null) {
                List<IItemPropertyDescriptor> pds = source.getPropertyDescriptors(eObject);
                String displayName = pd.getDisplayName(eObject);
        buildPropertySection(parent, eObject, pds, displayName, null);
            }
        return;
    }
inspectReferenceFeature(parent, target, reference);
  } else if (EMFUtils.testBooleanAnnotation(reference, EMFDetailUtils.ANNOTATION_SOURCE_DETAIL, ANNOTATION_DETAIL_TABLE)) {
    DetailProviderParameter parameter = createDetailProviderParameter(parent, target, pd);
    EMFDetailUtils.TABLE_BINDING_FACTORY.createBinding(parameter);
  } else {
    createEditor(parent, target, pd);
  }
 }
项目:econ-na-2014-emf-edit    文件:NotYourFathersSWT.java   
protected TreeViewer createViewer(Composite composite) {
    TreeViewer treeViewer = new TreeViewer(composite);
    treeViewer.getTree().setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));

    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory();
    adapterFactory.addAdapterFactory(new DecoratorEXTLibraryItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EXTLibraryItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new TreeItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());

    treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
    treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));

    return treeViewer;
}
项目:emfstore-rest    文件:ESWorkspaceProviderImpl.java   
private EditingDomain createEditingDomain(ResourceSet resourceSet) {
    final ESEditingDomainProvider domainProvider = getDomainProvider();
    if (domainProvider != null) {
        return domainProvider.getEditingDomain(resourceSet);
    }

    AdapterFactory adapterFactory = new ComposedAdapterFactory(
        ComposedAdapterFactory.Descriptor.Registry.INSTANCE);

    adapterFactory = new ComposedAdapterFactory(new AdapterFactory[] { adapterFactory,
        new ReflectiveItemProviderAdapterFactory() });

    final AdapterFactoryEditingDomain domain = new AdapterFactoryEditingDomain(adapterFactory,
        new EMFStoreBasicCommandStack(), resourceSet);
    resourceSet.eAdapters().add(new AdapterFactoryEditingDomain.EditingDomainProvider(domain));
    return domain;
}
项目:emfviews    文件:AttributesSelectionPage.java   
@Override
public void createControl(Composite parent) {

  Composite container = new Composite(parent, SWT.NULL);
  setControl(container);

  checkboxTreeViewer = new CheckboxTreeViewer(container, SWT.BORDER);
  Tree tree = checkboxTreeViewer.getTree();
  tree.setBounds(0, 0, 574, 282);

  AttributeSelectionContentProvider adapterContentProvider =
      new AttributeSelectionContentProvider();
  checkboxTreeViewer.setContentProvider(adapterContentProvider);
  checkboxTreeViewer
      .setLabelProvider(new AdapterFactoryLabelProvider(new ReflectiveItemProviderAdapterFactory()));

}
项目:emfviews    文件:ModelSelectionDialog.java   
@Override
protected Control createDialogArea(Composite parent) {
  this.parent = parent;
  Composite area = (Composite) super.createDialogArea(parent);
  Composite container = new Composite(area, SWT.NONE);
  container.setLayoutData(new GridData(GridData.FILL_BOTH));
  GridLayout layout = new GridLayout(1, false);
  container.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
  container.setLayout(layout);

  treeViewer = new CheckboxTreeViewer(area, SWT.BORDER);

  Tree tree = treeViewer.getTree();
  tree.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 1, 1));

  treeViewer
      .setLabelProvider(new AdapterFactoryLabelProvider(new ReflectiveItemProviderAdapterFactory()));

  treeViewer
      .setContentProvider(new AdapterFactoryContentProvider(new ReflectiveItemProviderAdapterFactory()));

  treeViewer.setInput(modelRoot);
  return area;
}
项目:gemoc-studio-modeldebugging    文件:CustomThreadItemProvider.java   
/**
 * Constructor.
 * 
 * @param adapterFactory
 *            the {@link AdapterFactory}.
 */
public CustomThreadItemProvider(AdapterFactory adapterFactory) {
    super(adapterFactory);

    efactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    efactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    efactory.addAdapterFactory(debugFactory);
    efactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:gemoc-studio-modeldebugging    文件:CustomStackFrameItemProvider.java   
/**
 * Constructor.
 * 
 * @param adapterFactory
 *            the {@link AdapterFactory}.
 */
public CustomStackFrameItemProvider(AdapterFactory adapterFactory) {
    super(adapterFactory);

    efactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    efactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    efactory.addAdapterFactory(debugFactory);
    efactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:gemoc-studio-modeldebugging    文件:CustomDebugTargetItemProvider.java   
/**
 * Constructor.
 * 
 * @param adapterFactory
 *            the {@link AdapterFactory}.
 */
public CustomDebugTargetItemProvider(AdapterFactory adapterFactory) {
    super(adapterFactory);

    efactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    efactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    efactory.addAdapterFactory(debugFactory);
    efactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:gemoc-studio-modeldebugging    文件:DSLBreakpoint.java   
/**
 * Initializes the {@link ComposedAdapterFactory} used for markers.
 * 
 * @return the {@link ComposedAdapterFactory} used for markers
 */
private static ComposedAdapterFactory initLabelProvider() {
    final ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    adapterFactory.addAdapterFactory(debugFactory);
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:gemoc-studio-modeldebugging    文件:DSLDebugModelPresentation.java   
/**
 * Constructor.
 */
public DSLDebugModelPresentation() {
    super();
    final ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);

    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    adapterFactory.addAdapterFactory(debugFactory);
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    eLabelProvider = new AdapterFactoryLabelProvider(adapterFactory);
}
项目:gemoc-studio-modeldebugging    文件:SelectDiagramDefinitionPage.java   
public SelectDiagramDefinitionPage(
        NewGemocDebugRepresentationWizard newGemocDebugRepresentationWizard) {
    super("Select diagram definition");
    this.newGemocDebugRepresentationWizard = newGemocDebugRepresentationWizard;

    adapterFactory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory
            .addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory
            .addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:DarwinSPL    文件:DwprofileAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:DwprofileCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:DarwinSPL    文件:HyexpressionCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:DarwinSPL    文件:HyexpressionAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:HyvalidityformulaCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:DarwinSPL    文件:HyvalidityformulaAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:HydatavalueCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:DarwinSPL    文件:HydatavalueAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:HymappingAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:HymappingCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:DarwinSPL    文件:HyconstraintsCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:DarwinSPL    文件:HyconstraintsAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:HymanifestAdapterFactoryProvider.java   
public AdapterFactory getAdapterFactory() {
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:DarwinSPL    文件:HymanifestCodeCompletionHelper.java   
protected Image getImage(EObject element) {
    if (!Platform.isRunning()) {
        return null;
    }
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    AdapterFactoryLabelProvider labelProvider = new AdapterFactoryLabelProvider(adapterFactory);
    return labelProvider.getImage(element);
}
项目:NEXCORE-UML-Modeler    文件:UiCorePlugin.java   
/**
 * 
 * 
 * @param factories
 *            void
 */
@SuppressWarnings("unchecked")
protected void fillItemProviderFactories(List factories) {
    factories.add(new EcoreItemProviderAdapterFactory());
    factories.add(new ReflectiveItemProviderAdapterFactory());
    factories.add(new UMLItemProviderAdapterFactory());
    // factories.add(new RelativeItemProviderAdapterFactory());
}
项目:limpet    文件:StackedchartsEditControl.java   
public StackedchartsEditControl(Composite parent)
{
  super(parent, SWT.NONE);

  setLayout(new FillLayout());

  editDomain = new EditDomain();

  viewer = new ScrollingGraphicalViewer();

  // connect external Drop support
  // add Dataset to Axis

  viewer.addDropTargetListener(new ProxyDropTargetListener(
      new DatasetToAxisDropTargetListener(viewer),
      new DatasetToAxisLandingDropTargetListener(viewer),
      new ScatterSetToScatterSetContainerTargetListener(viewer),
      new DatasetToChartDropTargetListener(viewer)
      ));

  viewer.createControl(this);
  editDomain.addViewer(viewer);

  viewer.getControl().setBackground(ColorConstants.listBackground);

  viewer.setEditPartFactory(new StackedChartsEditPartFactory());

  // emf edit domain
  adapterFactory =
      new ComposedAdapterFactory(
          ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
  BasicCommandStack commandStack = new BasicCommandStack();
  adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
  adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
  adapterFactory
      .addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
  emfEditingDomain =
      new AdapterFactoryEditingDomain(adapterFactory, commandStack);

}
项目:limpet    文件:CombinedProperty.java   
private static ComposedAdapterFactory createAdapterFactory()
{
  final ComposedAdapterFactory factory =
      new ComposedAdapterFactory(
          ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
  factory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());

  return factory;
}
项目:ModelDebugging    文件:CustomThreadItemProvider.java   
/**
 * Constructor.
 * 
 * @param adapterFactory
 *            the {@link AdapterFactory}.
 */
public CustomThreadItemProvider(AdapterFactory adapterFactory) {
    super(adapterFactory);

    efactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    efactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    efactory.addAdapterFactory(debugFactory);
    efactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:ModelDebugging    文件:CustomStackFrameItemProvider.java   
/**
 * Constructor.
 * 
 * @param adapterFactory
 *            the {@link AdapterFactory}.
 */
public CustomStackFrameItemProvider(AdapterFactory adapterFactory) {
    super(adapterFactory);

    efactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    efactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    efactory.addAdapterFactory(debugFactory);
    efactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:ModelDebugging    文件:CustomDebugTargetItemProvider.java   
/**
 * Constructor.
 * 
 * @param adapterFactory
 *            the {@link AdapterFactory}.
 */
public CustomDebugTargetItemProvider(AdapterFactory adapterFactory) {
    super(adapterFactory);

    efactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    efactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    efactory.addAdapterFactory(debugFactory);
    efactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:ModelDebugging    文件:DSLBreakpoint.java   
/**
 * Initializes the {@link ComposedAdapterFactory} used for markers.
 * 
 * @return the {@link ComposedAdapterFactory} used for markers
 */
private static ComposedAdapterFactory initLabelProvider() {
    final ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    adapterFactory.addAdapterFactory(debugFactory);
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    return adapterFactory;
}
项目:ModelDebugging    文件:DSLDebugModelPresentation.java   
/**
 * Constructor.
 */
public DSLDebugModelPresentation() {
    super();
    final ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);

    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    CustomDebugItemProviderAdapterFactory debugFactory = new CustomDebugItemProviderAdapterFactory();
    adapterFactory.addAdapterFactory(debugFactory);
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
    eLabelProvider = new AdapterFactoryLabelProvider(adapterFactory);
}
项目:ModelDebugging    文件:SelectDiagramDefinitionPage.java   
public SelectDiagramDefinitionPage(
        NewGemocDebugRepresentationWizard newGemocDebugRepresentationWizard) {
    super("Select diagram definition");
    this.newGemocDebugRepresentationWizard = newGemocDebugRepresentationWizard;

    adapterFactory = new ComposedAdapterFactory(
            ComposedAdapterFactory.Descriptor.Registry.INSTANCE);
    adapterFactory
            .addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory
            .addAdapterFactory(new ReflectiveItemProviderAdapterFactory());
}
项目:OpenSPIFe    文件:AdapterUtils.java   
/**
 * Returns an adapter factory containing all the global EMF registry's factories.
 * 
 * @return An adapter factory made of all the adapter factories declared in the registry.
 */
private static ComposedAdapterFactory createAdapterFactory() {
    final List<AdapterFactory> factories = new ArrayList<AdapterFactory>();
    factories.add(new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE));
    factories.add(new ReflectiveItemProviderAdapterFactory());
    return new ComposedAdapterFactory(factories);
}
项目:anatlyzer    文件:UiUtils.java   
public static IContentProvider getContentProviderForMetamodelViewer(Resource metamodelResource) {       
    // From EcoreEditor
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);

    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());

    return new AdapterFactoryContentProvider(adapterFactory);

}
项目:anatlyzer    文件:UiUtils.java   
public static ILabelProvider getLabelProviderForMetamodelViewer(Resource metamodelResource) {
    // From EcoreEditor
    ComposedAdapterFactory adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE);

    adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory());
    adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory());

    return new AdapterFactoryLabelProvider(adapterFactory);

}