Class EmfPictureModel
- java.lang.Object
-
- com._1c.g5.aef2.validators.Validable
-
- com._1c.g5.aef2.models.Model
-
- com._1c.g5.aef2.models.EditableModel
-
- com._1c.g5.aef2.models.value.Value<T>
-
- com._1c.g5.aef2.emf.models.EmfValue<Picture>
-
- com._1c.g5.v8.dt.md.ui.aef.models.EmfPictureModel
-
- All Implemented Interfaces:
IAttribute<org.eclipse.emf.ecore.EObject,org.eclipse.emf.ecore.EStructuralFeature>
,IEditableModel
,IEmfAttribute<org.eclipse.emf.ecore.EObject>
,IModel
,IEmfValueAttribute<Picture,org.eclipse.emf.ecore.EObject>
,IValue<Picture>
,IValidable
,IPictureModel
public class EmfPictureModel extends EmfValue<Picture> implements IPictureModel
TheIPictureModel
EMF implementation.
-
-
Constructor Summary
Constructors Constructor Description EmfPictureModel(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, IV8Project v8project)
Instantiates a new picture model.EmfPictureModel(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, IV8Project v8project, IPictureService pictureService, boolean canChoiseFromFile)
Instantiates a new picture model.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clean()
Clean picture valuevoid
dispose()
Disposes this model.IChange
getChange()
org.eclipse.emf.ecore.EObject
getModelObject()
Gets model object for setting pictureIPictureService
getPictureService()
Returns picture service.IV8Project
getV8project()
Returns V8 project.boolean
isEqual(Picture other)
Checks the value for equality with the current stored value.boolean
isPictureCanChoiseFromFile()
true
if this picture can be stored as file in file system.void
set(Object object, Point transparentPoint)
Sets picture parts.-
Methods inherited from class com._1c.g5.aef2.emf.models.EmfValue
getObject, getProperty
-
Methods inherited from class com._1c.g5.aef2.models.value.Value
addValueListener, createWorkingCopy, discard, get, getCommittedValue, getUncommittedValue, getValidatorTarget, notifyValueChanged, queueNotifyValueChanged, removeValueListener, set, setCommittedValue, setUncommittedValue, setValue, toString
-
Methods inherited from class com._1c.g5.aef2.models.EditableModel
isEditable, setEditable
-
Methods inherited from class com._1c.g5.aef2.models.Model
addModelListener, beginExternalUpdate, checkOffline, checkOnline, commit, endExternalUpdate, getComponent, getCurrentChangeOrigin, getRunnableQueue, isOnline, notifyModelChanged, notifyModelCommitted, removeModelListener, setComponent, setOnline
-
Methods inherited from class com._1c.g5.aef2.validators.Validable
addValidator, removeValidator, validate, validate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com._1c.g5.aef2.models.IModel
addModelListener, commit, discard, getComponent, isOnline, removeModelListener, setComponent
-
Methods inherited from interface com._1c.g5.aef2.validators.IValidable
addValidator, removeValidator, validate, validate
-
Methods inherited from interface com._1c.g5.aef2.models.value.IValue
addValueListener, createWorkingCopy, get, removeValueListener, set
-
-
-
-
Constructor Detail
-
EmfPictureModel
public EmfPictureModel(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, IV8Project v8project)
Instantiates a new picture model.- Parameters:
object
- the object, can not benull
.feature
- the object feature, can not benull
.v8project
- the V8 project, can not benull
.
-
EmfPictureModel
public EmfPictureModel(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, IV8Project v8project, IPictureService pictureService, boolean canChoiseFromFile)
Instantiates a new picture model.- Parameters:
object
- the object, can not benull
.feature
- the object feature, can not benull
.v8project
- the V8 project, can not benull
.pictureService
- the pictureService, can benull
.canChoiseFromFile
- is this picture can choise from file, must be false ifpictureService
isnull
.
-
-
Method Detail
-
dispose
public void dispose()
Description copied from interface:IModel
Disposes this model.
-
getV8project
public IV8Project getV8project()
Description copied from interface:IPictureModel
Returns V8 project.- Specified by:
getV8project
in interfaceIPictureModel
- Returns:
- the V8 project.
-
getPictureService
public IPictureService getPictureService()
Description copied from interface:IPictureModel
Returns picture service.- Specified by:
getPictureService
in interfaceIPictureModel
- Returns:
- the picture service
-
isPictureCanChoiseFromFile
public boolean isPictureCanChoiseFromFile()
Description copied from interface:IPictureModel
true
if this picture can be stored as file in file system. This option affect to show tab "from file" in choise picture dialog.- Specified by:
isPictureCanChoiseFromFile
in interfaceIPictureModel
- Returns:
true
if this picture can be stored as file,false
in otherwise.
-
isEqual
public boolean isEqual(Picture other)
Description copied from interface:IValue
Checks the value for equality with the current stored value.
-
getChange
public IChange getChange()
-
set
public void set(Object object, Point transparentPoint)
Description copied from interface:IPictureModel
Sets picture parts.- Specified by:
set
in interfaceIPictureModel
- Parameters:
object
- the picture to set -null
,Picture
orString
typetransparentPoint
- the transparentPoint
-
clean
public void clean()
Description copied from interface:IPictureModel
Clean picture value- Specified by:
clean
in interfaceIPictureModel
-
getModelObject
public org.eclipse.emf.ecore.EObject getModelObject()
Description copied from interface:IPictureModel
Gets model object for setting picture- Specified by:
getModelObject
in interfaceIPictureModel
- Returns:
- model object for setting picture, never
null
-
-