org.eclipse.eef.core.internal.controllers

## Class EEFButtonController

- java.lang.Object
- - org.eclipse.eef.core.api.controllers.AbstractEEFController
  - - org.eclipse.eef.core.api.controllers.AbstractEEFWidgetController
    - - org.eclipse.eef.core.internal.controllers.EEFButtonController

All Implemented Interfaces:
  IEEFButtonController, IEEFController, IEEFWidgetController

    public class EEFButtonController
    extends AbstractEEFWidgetController
    implements IEEFButtonController

This class will be used in order to manage the behavior of the button.

### Field Summary

### Fields inherited from class org.eclipse.eef.core.api.controllers.AbstractEEFWidgetController

`newHelpConsumer, newLabelConsumer`

### Fields inherited from class org.eclipse.eef.core.api.controllers.AbstractEEFController

`interpreter, variableManager`

### Constructor Summary

Constructors
Constructor and Description
`EEFButtonController(EEFButtonDescription description, org.eclipse.sirius.common.interpreter.api.IVariableManager variableManager, org.eclipse.sirius.common.interpreter.api.IInterpreter interpreter, EditingContextAdapter contextAdapter)` The constructor.

### Method Summary

All Methods Instance Methods Concrete Methods
`protected EEFWidgetDescription` `getDescription()` Returns the widget description.
`void` `onNewButtonLabel(IConsumer<java.lang.String> consumer)` Register a consumer which will be called with the new value of the button's label when it will change.
`org.eclipse.core.runtime.IStatus` `pushed()` Invoked when the user pushes the button.
`void` `refresh()` Refresh the controller.
`void` `removeNewButtonLabelConsumer()` Remove the consumer of the new value of the button's label.

### Methods inherited from class org.eclipse.eef.core.api.controllers.AbstractEEFWidgetController

`computeHelp, getValidationRulesContainer, getValidationRulesReference, onNewHelp, onNewLabel, removeNewHelpConsumer, removeNewLabelConsumer`

### Methods inherited from class org.eclipse.eef.core.api.controllers.AbstractEEFController

`newEval, onValidation, removeValidationConsumer`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.eclipse.eef.core.api.controllers.IEEFWidgetController

`computeHelp, onNewHelp, onNewLabel, removeNewHelpConsumer, removeNewLabelConsumer`

### Methods inherited from interface org.eclipse.eef.core.api.controllers.IEEFController

`onValidation, removeValidationConsumer`

### Constructor Detail

#### EEFButtonController

    public EEFButtonController(EEFButtonDescription description,
                               org.eclipse.sirius.common.interpreter.api.IVariableManager variableManager,
                               org.eclipse.sirius.common.interpreter.api.IInterpreter interpreter,
                               EditingContextAdapter contextAdapter)

The constructor.

Parameters:
  `description` - The description
  `variableManager` - The variable manager
  `interpreter` - The interpreter
  `contextAdapter` - The editing context adapter

### Method Detail

#### onNewButtonLabel

    public void onNewButtonLabel(IConsumer<java.lang.String> consumer)

Description copied from interface: `IEEFButtonController`
Register a consumer which will be called with the new value of the button's label when it will change.

Specified by:
  `onNewButtonLabel` in interface `IEEFButtonController`
Parameters:
  `consumer` - The consumer of the new value of the button's label

#### removeNewButtonLabelConsumer

    public void removeNewButtonLabelConsumer()

Description copied from interface: `IEEFButtonController`
Remove the consumer of the new value of the button's label.

Specified by:
  `removeNewButtonLabelConsumer` in interface `IEEFButtonController`

#### getDescription

    protected EEFWidgetDescription getDescription()

Description copied from class: `AbstractEEFWidgetController`
Returns the widget description.

Specified by:
  `getDescription` in class `AbstractEEFWidgetController`
Returns:
  The widget description

#### refresh

    public void refresh()

Description copied from class: `AbstractEEFWidgetController`
Refresh the controller.

Specified by:
  `refresh` in interface `IEEFController`
Overrides:
  `refresh` in class `AbstractEEFWidgetController`
See Also:
  `AbstractEEFController.refresh()`

#### pushed

    public org.eclipse.core.runtime.IStatus pushed()

Description copied from interface: `IEEFButtonController`
Invoked when the user pushes the button.

Specified by:
  `pushed` in interface `IEEFButtonController`
Returns:
  the status of the pushed execution.