Class FormItemInformationService


  • public class FormItemInformationService
    extends Object
    TODO: no type for ButtonGroupExtInfo, ContextMenu, FormTableExtensionForValueTable

    Special service for providing information about methods, properties and events for FormItem and their extension
    • Constructor Detail

      • FormItemInformationService

        public FormItemInformationService()
    • Method Detail

      • getEventHandlers

        public List<EventHandler> getEventHandlers​(org.eclipse.emf.ecore.EObject object)
        Returns a list of active event handlers for the provideded form model object. The returned list is a live view of model object handlers so changes to one affect the other.
        Parameters:
        object - the form model object, cannot be null
        Returns:
        a list of active even handlers for the provideded form model object or an empty list, if object does not have active event handlers or object cannot have event handlers
      • getAllowedEvents

        public List<Event> getAllowedEvents​(FormVisualEntity item,
                                            org.eclipse.emf.ecore.EStructuralFeature extInfoFeature)
        Gets allowed Events for FormVisualEntity (contains events of extension too)
        Parameters:
        item - form visual item, can't be null
        extInfoFeature - EStructuralFeature of extension info property, can be null
        Returns:
        list of allowed Events
      • getAllowedIndexedEvents

        public Collection<org.eclipse.xtext.resource.IEObjectDescription> getAllowedIndexedEvents​(FormVisualEntity item)
        Gets allowed indexed Events for FormVisualEntity (contains events of extension too)
        Parameters:
        item - form visual item, can't be null
        Returns:
        list of allowed indexed Events, never null
      • getAllowedEvents

        public List<Event> getAllowedEvents​(FormVisualEntity item,
                                            org.eclipse.emf.ecore.resource.Resource resource)
        Gets allowed Events for FormVisualEntity (contains events of extension too)
        Parameters:
        item - form visual item, can't be null
        resource - the resource to resolve proxies
        Returns:
        list of allowed Events
      • getAllowedIndexedEvents

        public Collection<org.eclipse.xtext.resource.IEObjectDescription> getAllowedIndexedEvents​(FormVisualEntity item,
                                                                                                  org.eclipse.emf.ecore.resource.Resource resource)
        Gets allowed indexed Events for FormVisualEntity (contains events of extension too)
        Parameters:
        item - form visual item, can't be null
        resource - the resource to resolve proxies
        Returns:
        list of allowed indexed Events, never null
      • getAllowedEvents

        public List<Event> getAllowedEvents​(ExtInfo extInfo,
                                            org.eclipse.emf.ecore.resource.Resource resource)
        Gets allowed Events for ExtInfo
        Parameters:
        extInfo - ExtInfo, can't be null
        resource - the resource to resolve proxies
        Returns:
        list of allowed Events
      • getAllowedIndexedEvents

        public Collection<org.eclipse.xtext.resource.IEObjectDescription> getAllowedIndexedEvents​(ExtInfo extInfo,
                                                                                                  org.eclipse.emf.ecore.resource.Resource resource)
        Gets allowed indexed Events for ExtInfo
        Parameters:
        extInfo - ExtInfo, can't be null
        resource - the resource to resolve proxies
        Returns:
        list of allowed indexed Events, never null
      • getAllowedEventNames

        public Set<String> getAllowedEventNames​(org.eclipse.emf.ecore.EClass eClass,
                                                Version version)
        Gets allowed event names
        Parameters:
        eClass - of object contains events
        version - of runtime
        Returns:
        list of allowed event names
      • getAllowedContextDefItem

        public List<ContextDef> getAllowedContextDefItem​(FormItem item,
                                                         org.eclipse.emf.ecore.EStructuralFeature extInfoFeature)
        Gets allowed Method and Property for FormItem (contains elements of contextDef of extension too)
        Parameters:
        item - form item, can't be null
        extInfoFeature - EStructuralFeature of extension info property, can't be null
        Returns:
        list of ContextDef
      • getTypeOfFormItem

        public Type getTypeOfFormItem​(FormVisualEntity item)
        Gets Type of the form item
        Parameters:
        item - FormItem
        Returns:
        actual Type or null if item doesn't have type
      • getTypesOfFormItem

        public List<Type> getTypesOfFormItem​(FormVisualEntity item)
        Gets Types of the form item
        Parameters:
        item - FormItem, can't be null
        Returns:
        actual Types for form item and it extension or empty list if item doesn't have type
      • getExtensionInfo

        public ExtInfo getExtensionInfo​(org.eclipse.emf.ecore.EObject object)
        Gets ExtInfo for object
        Parameters:
        object - object from form
        Returns:
        found ExtInfo or null if extInfo wasn't found