Runtime

## org.eclipse.gmf.runtime.diagram.ui.view.factories
Class AbstractShapeViewFactory

    java.lang.Object
      org.eclipse.gmf.runtime.diagram.ui.view.factories.AbstractViewFactory
          org.eclipse.gmf.runtime.diagram.ui.view.factories.BasicNodeViewFactory
              org.eclipse.gmf.runtime.diagram.ui.view.factories.AbstractShapeViewFactory

All Implemented Interfaces:
  ViewFactory

Direct Known Subclasses:
  TextShapeViewFactory

public abstract class AbstractShapeViewFactory
extends BasicNodeViewFactory

The base abstract node view factory

See Also:
  `BasicNodeViewFactory`

Constructor Summary
`AbstractShapeViewFactory()`

Method Summary
`protected LayoutConstraint` `createLayoutConstraint()` Method used to create the layout constraint that will get set on the created view.
`protected java.util.List` `createStyles(View view)` this method is called by @link #createView(IAdaptable, View, String, int, boolean) to create the styles for the view that will be created, you can override this method in you factory sub class to provide additional styles
`protected void` `initializeFromPreferences(View view)` Initialize the newly created view from the preference store, this method get called by @link #decorateView(View, IAdaptable, String)

Methods inherited from class org.eclipse.gmf.runtime.diagram.ui.view.factories.BasicNodeViewFactory
`createNode, createView, decorateView, isUnProtectedSilentTransactionInProgress`

Methods inherited from class org.eclipse.gmf.runtime.diagram.ui.view.factories.AbstractViewFactory
`getEditingDomain, getPreferencesHint, getViewService, requiresElement, requiresElement, setPreferencesHint`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AbstractShapeViewFactory

    public AbstractShapeViewFactory()

Method Detail

### createLayoutConstraint

    protected LayoutConstraint createLayoutConstraint()

  Method used to create the layout constraint that will get set on the created view. You can override this method in your own factory to change the default constraint. This method is called by @link #createView(IAdaptable, View, String, int, boolean)

  Overrides:
    `createLayoutConstraint` in class `BasicNodeViewFactory`
  Returns:
    a new layout constraint for the view

### initializeFromPreferences

    protected void initializeFromPreferences(View view)

  Initialize the newly created view from the preference store, this method get called by @link #decorateView(View, IAdaptable, String)

  Overrides:
    `initializeFromPreferences` in class `AbstractViewFactory`
  Parameters:
    `view` - the view to initialize

### createStyles

    protected java.util.List createStyles(View view)

  this method is called by @link #createView(IAdaptable, View, String, int, boolean) to create the styles for the view that will be created, you can override this method in you factory sub class to provide additional styles

  Overrides:
    `createStyles` in class `AbstractViewFactory`
  Returns:
    a list of style for the newly created view or an empty list if none (do not return null)

Runtime

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.