Class TypeSelectionValueComponentPart
- java.lang.Object
-
- com._1c.g5.v8.dt.md.ui.aef.components.value.AbstractValueComponentPart<TypeSelectionControlViewModel,Value>
-
- com._1c.g5.v8.dt.md.ui.aef.components.value.TypeSelectionValueComponentPart
-
- All Implemented Interfaces:
IValueComponentPart<TypeSelectionControlViewModel,IValueModel,Value>
public class TypeSelectionValueComponentPart extends AbstractValueComponentPart<TypeSelectionControlViewModel,Value>
TheIValueComponentPart
implementation for choosing the type.
-
-
Constructor Summary
Constructors Constructor Description TypeSelectionValueComponentPart()
Creates a new component part.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IMapper<Value,?>
createMapper(TypeSelectionControlViewModel viewModel, IValueModel model)
Returns the newly created mapper that maps theValue
to view model.TypeSelectionControlViewModel
createViewModel(IValueModel model)
Creates a view model for the givenmodel
.org.eclipse.emf.ecore.EStructuralFeature
getViewModelBindingFeature()
Returns the view model feature that is binds by value component.void
handleButtonPressed(TypeSelectionControlViewModel viewModel, IValueModel model)
Handles the button events.boolean
hasClearAction(TypeSelectionControlViewModel viewModel, IValueModel model)
Returnstrue
if the value component should create clear action button for the given model.boolean
isSuitable(IValueModel model)
Returns thetrue
if the part is suitable for the givenmodel
.-
Methods inherited from class com._1c.g5.v8.dt.md.ui.aef.components.value.AbstractValueComponentPart
bindViewModel, getTypeName, isEditable, isSuitableTypeName, isSuitableValue
-
-
-
-
Method Detail
-
createViewModel
public TypeSelectionControlViewModel createViewModel(IValueModel model)
Description copied from interface:IValueComponentPart
Creates a view model for the givenmodel
.- Parameters:
model
- theIValueModel
.- Returns:
- the newly created view model.
-
isSuitable
public boolean isSuitable(IValueModel model)
Description copied from interface:IValueComponentPart
Returns thetrue
if the part is suitable for the givenmodel
.- Specified by:
isSuitable
in interfaceIValueComponentPart<TypeSelectionControlViewModel,IValueModel,Value>
- Overrides:
isSuitable
in classAbstractValueComponentPart<TypeSelectionControlViewModel,Value>
- Parameters:
model
- theIValueModel
.- Returns:
- the
true
if the part is suitable for the givenmodel
.
-
handleButtonPressed
public void handleButtonPressed(TypeSelectionControlViewModel viewModel, IValueModel model)
Description copied from interface:IValueComponentPart
Handles the button events.- Specified by:
handleButtonPressed
in interfaceIValueComponentPart<TypeSelectionControlViewModel,IValueModel,Value>
- Overrides:
handleButtonPressed
in classAbstractValueComponentPart<TypeSelectionControlViewModel,Value>
- Parameters:
viewModel
- the view model.model
- theIValueModel
.
-
hasClearAction
public boolean hasClearAction(TypeSelectionControlViewModel viewModel, IValueModel model)
Description copied from interface:IValueComponentPart
Returnstrue
if the value component should create clear action button for the given model.- Specified by:
hasClearAction
in interfaceIValueComponentPart<TypeSelectionControlViewModel,IValueModel,Value>
- Overrides:
hasClearAction
in classAbstractValueComponentPart<TypeSelectionControlViewModel,Value>
- Parameters:
viewModel
- the view model.model
- theIValueModel
.- Returns:
true
if the clear action button is required.
-
getViewModelBindingFeature
public org.eclipse.emf.ecore.EStructuralFeature getViewModelBindingFeature()
Description copied from interface:IValueComponentPart
Returns the view model feature that is binds by value component.- Returns:
- the view model feature that is binds by
value component or
null
.
-
createMapper
public IMapper<Value,?> createMapper(TypeSelectionControlViewModel viewModel, IValueModel model)
Description copied from interface:IValueComponentPart
Returns the newly created mapper that maps theValue
to view model.- Parameters:
viewModel
- the view model.model
- theIValueModel
.- Returns:
- the mapper.
-
-