org.eclipse.ocl.expressions.provider
Class CollectionRangeItemProvider

java.lang.Object
  extended by ItemProviderAdapter
      extended by org.eclipse.ocl.expressions.provider.CollectionLiteralPartItemProvider
          extended by org.eclipse.ocl.expressions.provider.CollectionRangeItemProvider

public class CollectionRangeItemProvider
extends CollectionLiteralPartItemProvider

This is the item provider adapter for a CollectionRange object.


Constructor Summary
CollectionRangeItemProvider(AdapterFactory adapterFactory)
          This constructs an instance from a factory and a notifier
 
Method Summary
protected  void addFirstPropertyDescriptor(java.lang.Object object)
          This adds a property descriptor for the First feature
protected  void addLastPropertyDescriptor(java.lang.Object object)
          This adds a property descriptor for the Last feature
protected  void collectNewChildDescriptors(java.util.Collection<java.lang.Object> newChildDescriptors, java.lang.Object object)
          This adds org.eclipse.emf.edit.command.CommandParameters describing the children that can be created under this object
protected  EStructuralFeature getChildFeature(java.lang.Object object, java.lang.Object child)
           
 java.util.Collection<? extends EStructuralFeature> getChildrenFeatures(java.lang.Object object)
          This specifies how to implement #getChildren and is used to deduce an appropriate feature for an org.eclipse.emf.edit.command.AddCommand, org.eclipse.emf.edit.command.RemoveCommand or org.eclipse.emf.edit.command.MoveCommand in #createCommand
 java.lang.String getCreateChildText(java.lang.Object owner, java.lang.Object feature, java.lang.Object child, java.util.Collection<?> selection)
          This returns the label text for org.eclipse.emf.edit.command.CreateChildCommand
 java.lang.Object getImage(java.lang.Object object)
          This returns CollectionRange.gif
 java.util.List<IItemPropertyDescriptor> getPropertyDescriptors(java.lang.Object object)
          This returns the property descriptors for the adapted class
 java.lang.String getText(java.lang.Object object)
          This returns the label text for the adapted class
 void notifyChanged(Notification notification)
          This handles model notifications by calling #updateChildren to update any cached children and by creating a viewer notification, which it passes to #fireNotifyChanged
protected  boolean shouldComposeCreationImage()
           
 
Methods inherited from class org.eclipse.ocl.expressions.provider.CollectionLiteralPartItemProvider
getResourceLocator
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CollectionRangeItemProvider

public CollectionRangeItemProvider(AdapterFactory adapterFactory)
This constructs an instance from a factory and a notifier.

Method Detail

getPropertyDescriptors

public java.util.List<IItemPropertyDescriptor> getPropertyDescriptors(java.lang.Object object)
This returns the property descriptors for the adapted class.

Overrides:
getPropertyDescriptors in class CollectionLiteralPartItemProvider

addFirstPropertyDescriptor

protected void addFirstPropertyDescriptor(java.lang.Object object)
This adds a property descriptor for the First feature.


addLastPropertyDescriptor

protected void addLastPropertyDescriptor(java.lang.Object object)
This adds a property descriptor for the Last feature.


getChildrenFeatures

public java.util.Collection<? extends EStructuralFeature> getChildrenFeatures(java.lang.Object object)
This specifies how to implement #getChildren and is used to deduce an appropriate feature for an org.eclipse.emf.edit.command.AddCommand, org.eclipse.emf.edit.command.RemoveCommand or org.eclipse.emf.edit.command.MoveCommand in #createCommand.


getChildFeature

protected EStructuralFeature getChildFeature(java.lang.Object object,
                                             java.lang.Object child)


getImage

public java.lang.Object getImage(java.lang.Object object)
This returns CollectionRange.gif.

Overrides:
getImage in class CollectionLiteralPartItemProvider

shouldComposeCreationImage

protected boolean shouldComposeCreationImage()

Overrides:
shouldComposeCreationImage in class CollectionLiteralPartItemProvider

getText

public java.lang.String getText(java.lang.Object object)
This returns the label text for the adapted class.

Overrides:
getText in class CollectionLiteralPartItemProvider

notifyChanged

public void notifyChanged(Notification notification)
This handles model notifications by calling #updateChildren to update any cached children and by creating a viewer notification, which it passes to #fireNotifyChanged.

Overrides:
notifyChanged in class CollectionLiteralPartItemProvider

collectNewChildDescriptors

protected void collectNewChildDescriptors(java.util.Collection<java.lang.Object> newChildDescriptors,
                                          java.lang.Object object)
This adds org.eclipse.emf.edit.command.CommandParameters describing the children that can be created under this object.

Overrides:
collectNewChildDescriptors in class CollectionLiteralPartItemProvider

getCreateChildText

public java.lang.String getCreateChildText(java.lang.Object owner,
                                           java.lang.Object feature,
                                           java.lang.Object child,
                                           java.util.Collection<?> selection)
This returns the label text for org.eclipse.emf.edit.command.CreateChildCommand.


Copyright 2002, 2007 IBM Corporation and others.
All Rights Reserved.