- java.lang.Object
-
- org.tentackle.model.impl.ModelEntityImpl
-
- All Implemented Interfaces:
ModelEntity
public class ModelEntityImpl extends Object implements ModelEntity
Entity as a component of a model.- Author:
- harald
-
-
Constructor Summary
Constructors Constructor Description ModelEntityImpl(Entity entity, String filePath)Creates a model entity.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EntitygetEntity()Gets the entity.StringgetFilePath()Gets the path of the modelfile.booleanhasChanged()Returns whether the modelfile has changed.StringtoString()
-
-
-
Constructor Detail
-
ModelEntityImpl
public ModelEntityImpl(Entity entity, String filePath) throws ModelException
Creates a model entity.- Parameters:
entity- the entityfilePath- the modelfile's path- Throws:
ModelException- if file does not exist or is not a regular file
-
-
Method Detail
-
getEntity
public Entity getEntity()
Description copied from interface:ModelEntityGets the entity.- Specified by:
getEntityin interfaceModelEntity- Returns:
- the entity
-
getFilePath
public String getFilePath()
Description copied from interface:ModelEntityGets the path of the modelfile.- Specified by:
getFilePathin interfaceModelEntity- Returns:
- the canonical file path
-
hasChanged
public boolean hasChanged()
Description copied from interface:ModelEntityReturns whether the modelfile has changed.- Specified by:
hasChangedin interfaceModelEntity- Returns:
- true if changed
-
-