Class GotoCommandEventHandlerHandler
- java.lang.Object
-
- org.eclipse.core.commands.common.EventManager
-
- org.eclipse.core.commands.AbstractHandler
-
- com._1c.g5.v8.dt.form.ui.commands.AbstractGotoEventHandlerHandler<FormCommand>
-
- com._1c.g5.v8.dt.form.ui.commands.GotoCommandEventHandlerHandler
-
- All Implemented Interfaces:
org.eclipse.core.commands.IHandler
,org.eclipse.core.commands.IHandler2
public class GotoCommandEventHandlerHandler extends AbstractGotoEventHandlerHandler<FormCommand>
Checks selected form button command event handler existence and then selects and reveals it.
-
-
Field Summary
-
Fields inherited from class com._1c.g5.v8.dt.form.ui.commands.AbstractGotoEventHandlerHandler
bmModelManager, moduleEventsLookup
-
-
Constructor Summary
Constructors Constructor Description GotoCommandEventHandlerHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected FormCommand
extractEventOwner(org.eclipse.emf.ecore.EObject element, Form form, org.eclipse.core.commands.ExecutionEvent executionEvent)
Extracts event owner from given form element.protected String
generateEventHandlerName(FormCommand eventOwner, org.eclipse.emf.ecore.EObject element, org.eclipse.core.commands.ExecutionEvent executionEvent)
GenerateseventOwner
event handler name.protected Event
getCreatingEvent(org.eclipse.emf.ecore.EObject eventOwner, org.eclipse.core.commands.ExecutionEvent executionEvent, String handlerName)
Gets event for handler creation.protected String
getEventHandlerName(FormCommand eventOwner, org.eclipse.emf.ecore.EObject element, org.eclipse.core.commands.ExecutionEvent executionEvent)
ReturnseventOwner
event handler name.protected boolean
isCommandHandler()
Returns whether creating event handler is command handler.protected void
setEventHandler(FormCommand eventOwner, String eventHandlerName, org.eclipse.core.commands.ExecutionEvent executionEvent)
SetseventOwner
event handler.-
Methods inherited from class com._1c.g5.v8.dt.form.ui.commands.AbstractGotoEventHandlerHandler
execute, getEditingContext, getForm, getProcedureDirective, isAllowedServerCall, isMainItem, openOrCreateEventHandler, selectAndReveal, shouldCreateEvent
-
Methods inherited from class org.eclipse.core.commands.AbstractHandler
addHandlerListener, dispose, fireHandlerChanged, hasListeners, isEnabled, isHandled, removeHandlerListener, setBaseEnabled, setEnabled
-
-
-
-
Method Detail
-
extractEventOwner
protected FormCommand extractEventOwner(org.eclipse.emf.ecore.EObject element, Form form, org.eclipse.core.commands.ExecutionEvent executionEvent)
Description copied from class:AbstractGotoEventHandlerHandler
Extracts event owner from given form element.- Specified by:
extractEventOwner
in classAbstractGotoEventHandlerHandler<FormCommand>
- Parameters:
element
- the form element to extract event owner from, cannot benull
form
- the owner form, cannot benull
executionEvent
- the current execution event, cannot benull
- Returns:
- the event owner, never
null
-
getCreatingEvent
protected Event getCreatingEvent(org.eclipse.emf.ecore.EObject eventOwner, org.eclipse.core.commands.ExecutionEvent executionEvent, String handlerName)
Description copied from class:AbstractGotoEventHandlerHandler
Gets event for handler creation.- Specified by:
getCreatingEvent
in classAbstractGotoEventHandlerHandler<FormCommand>
- Parameters:
eventOwner
- the owner of event, cannot benull
executionEvent
- the current execution event, cannot benull
handlerName
- the event handler name to create event with, cannot benull
- Returns:
- creating event, never
null
-
getEventHandlerName
protected String getEventHandlerName(FormCommand eventOwner, org.eclipse.emf.ecore.EObject element, org.eclipse.core.commands.ExecutionEvent executionEvent)
Description copied from class:AbstractGotoEventHandlerHandler
ReturnseventOwner
event handler name. Can returnnull
if not provided.- Specified by:
getEventHandlerName
in classAbstractGotoEventHandlerHandler<FormCommand>
- Parameters:
eventOwner
- the owner of event, cannot benull
element
- the currently selected form element, cannot benull
executionEvent
- the current execution event, cannot benull
- Returns:
- the existing event handler name or
null
if none
-
generateEventHandlerName
protected String generateEventHandlerName(FormCommand eventOwner, org.eclipse.emf.ecore.EObject element, org.eclipse.core.commands.ExecutionEvent executionEvent)
Description copied from class:AbstractGotoEventHandlerHandler
GenerateseventOwner
event handler name.- Specified by:
generateEventHandlerName
in classAbstractGotoEventHandlerHandler<FormCommand>
- Parameters:
eventOwner
- the owner of event, cannot benull
element
- the currently selected form element, cannot benull
executionEvent
- the current execution event, cannot benull
- Returns:
- generated event handler name, never
null
-
setEventHandler
protected void setEventHandler(FormCommand eventOwner, String eventHandlerName, org.eclipse.core.commands.ExecutionEvent executionEvent)
Description copied from class:AbstractGotoEventHandlerHandler
SetseventOwner
event handler.- Specified by:
setEventHandler
in classAbstractGotoEventHandlerHandler<FormCommand>
- Parameters:
eventOwner
- the owner of event, cannot benull
eventHandlerName
- the event handler name to set, cannot benull
executionEvent
- the current execution event, cannot benull
-
isCommandHandler
protected boolean isCommandHandler()
Description copied from class:AbstractGotoEventHandlerHandler
Returns whether creating event handler is command handler.- Overrides:
isCommandHandler
in classAbstractGotoEventHandlerHandler<FormCommand>
- Returns:
- whether creating event handler is command handler
-
-