|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.change_vision.jude.api.inf.project.ProjectAccessor
public abstract ProjectAccessor
Interface to Operate Astah project.
Field Summary | |
---|---|
static int |
REFERENCE_PROJECT_STATUS_LATEST
|
static int |
REFERENCE_PROJECT_STATUS_NEED_UPDATE
|
static int |
REFERENCE_PROJECT_STATUS_NOT_FOUND
|
Method Summary | |
---|---|
abstract void |
addEntityEditListener(EntityEditListener listener)
Add EntityEditListener. |
abstract void |
addProjectEventListener(ProjectEventListener listener)
Add ProjectEventListener. |
abstract void |
addReferenceProject(String path)
Not implemented yet. Add Reference Project in Astah Project. |
abstract void |
changeReferenceProject(String fromPath,
String toPath)
Not implemented yet. Change Reference Project Path in Astah Project. |
abstract void |
clearReferenceProject(String path)
Not implemented yet. Clear Reference Project in Astah Project. |
abstract void |
close()
Close Astah Project. |
abstract void |
create(String projectPath,
boolean useDefinedTaggedValues)
Create Astah Project. |
abstract void |
create(String projectPath)
Create Astah Project without loading the user defined tagged values. |
abstract void |
create()
Create Astah Project without loading the user defined tagged values, and it should specify path when save the project. |
abstract void |
create(String projectPath,
String templatePath,
boolean useDefinedTaggedValues)
Create Astah Project. |
abstract void |
create(String projectPath,
String templatePath)
Create Astah Project without loading the user defined tagged values. |
abstract void |
easyCompare(String path)
Compare a project with the current project. |
abstract void |
easyMerge(String path,
boolean isKeepBase)
Not implemented yet. Merge a project into the current project. |
abstract void |
exportXMI(String fileName)
Not implemented yet. Save Astah Project as parameter's xmi name. |
abstract INamedElement[] |
findElements(Class<E> elementKind,
String name)
Search elements in an Astah model by element kind and element name. |
abstract INamedElement[] |
findElements(Class<E> elementKind)
Search elements in an Astah model by element kind. |
abstract INamedElement[] |
findElements(ModelFinder picker)
Search elements in an Astah model by ModelPicker. |
abstract int |
getAstahAPIModelVersion()
Obtain the model version of project created by Astah API |
abstract String |
getAstahAPIVersion()
Obtain the version of Astah API |
abstract String |
getAstahEdition()
Obtain the edition of Astah you currently use |
abstract String |
getAstahInstallPath()
Obtain where the Astah installation path |
abstract int |
getAstahModelVersion()
Obtain the model version of project created by this Astah |
abstract String |
getAstahVersion()
Obtain the version of Astah you currently use |
abstract IModel |
getCurrentProject()
Deprecated. Get the top level model of a facet from a return value of getFacet(), etc. This method will be deleted in the future. |
abstract IDiagramEditorFactory |
getDiagramEditorFactory()
Get IDiagramEditorFactory. |
abstract IEntity |
getEntity(String id)
Returns IEntity that has special ID. |
abstract IFacet |
getFacet(String symbolicName)
Get the facet contained in the project by specifying the symbolic name. |
abstract List<IFacet> |
getFacets()
Get the facets owned by the project accessor. |
abstract IModelEditorFactory |
getModelEditorFactory()
Get IModelEditorFactory. |
abstract IModel |
getProject()
Deprecated. Get the top level model of a facet from a return value of getFacet(), etc. This method will be deleted in the future. |
abstract int |
getProjectModelVersion()
Obtain the model version of project which is currently open |
abstract String |
getProjectPath()
Obtain where the Astah project is saved |
abstract String[] |
getReferenceProjectPaths()
Get Reference Project Paths in Astah Project. |
abstract int |
getReferenceProjectStatus(String path)
Get Reference Project Status in Astah Project. |
abstract ITransactionManager |
getTransactionManager()
Get ITransactionManager. |
abstract IViewManager |
getViewManager()
Get IViewManager. |
abstract boolean |
hasProject()
Get whether a project is open or not. |
abstract boolean |
hasSameElement(String name)
Returns whether there is an element with the same name |
abstract boolean |
hasSameElement(String name,
Class<E> clazz)
Returns whether there is an element with the same name and the same type |
abstract void |
importXMI(String projectName)
Open Astah Project's XMI. |
abstract void |
importXMI(String projectName,
boolean isIgnoreModelVersion)
Open Astah Project's XMI. |
abstract boolean |
isProjectModified()
Returns whether current model is modified |
abstract void |
open(String projectName)
Open Astah Project. |
abstract void |
open(String projectName,
boolean isIgnoreModelVersion)
Open Astah Project. |
abstract void |
open(String projectName,
boolean isIgnoreModelVersion,
boolean lockMode,
boolean allowReadOnly)
Open Astah Project. |
abstract void |
open(InputStream in)
Open Astah Project. |
abstract void |
open(InputStream in,
boolean isIgnoreModelVersion)
Open Astah Project. |
abstract void |
removeEntityEditListener(EntityEditListener listener)
Remove EntityEditListener. |
abstract void |
removeProjectEventListener(ProjectEventListener listener)
Remove ProjectEventListener. |
abstract void |
removeReferenceProject(String path)
Not implemented yet. Delete Reference Project in Astah Project. |
abstract void |
save()
Save Astah Project. |
abstract void |
saveAs(String projectName)
Save Astah Project as parameter's name. |
abstract void |
updateReferenceProject(String path)
Not implemented yet. Update Reference Project in Astah Project. |
abstract void |
validateProject()
Find invalid models in Astah project |
Field Detail |
---|
static final int REFERENCE_PROJECT_STATUS_LATEST
static final int REFERENCE_PROJECT_STATUS_NEED_UPDATE
static final int REFERENCE_PROJECT_STATUS_NOT_FOUND
Method Detail |
---|
abstract void open(String projectName)
projectName
- Project Name
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output error
ProjectLockedException
- Project file has been lockedabstract void open(String projectName, boolean isIgnoreModelVersion)
projectName
- Project NameisIgnoreModelVersion
- Select if you need a Model Version Check
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output error
ProjectLockedException
- Project file has been lockedabstract void open(String projectName, boolean isIgnoreModelVersion, boolean lockMode, boolean allowReadOnly)
projectName
- Project NameisIgnoreModelVersion
- Select if you need a Model Version ChecklockMode
- Select if you lock a project fileallowReadOnly
- Select if you open a project in ReadOnly mode when it has been locked.
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output error
ProjectLockedException
- Project file has been lockedabstract void saveAs(String projectName)
projectName
- File Name
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
IOException
- input/output error
ProjectLockedException
- Project file has been lockedabstract void importXMI(String projectName)
projectName
- Project Name
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output error
InvalidUsingException
- community and UML version cannot use XMI API.abstract void importXMI(String projectName, boolean isIgnoreModelVersion)
projectName
- Project NameisIgnoreModelVersion
- Select if you need a Model Version Check
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output error
InvalidUsingException
- community and UML version cannot use XMI API.abstract void exportXMI(String fileName)
fileName
- File Name
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
IOException
- input/output error
InvalidUsingException
- community and UML version cannot use XMI API.abstract void open(InputStream in)
in
- InputStream
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output error
ProjectLockedException
- Project file has been lockedabstract void open(InputStream in, boolean isIgnoreModelVersion)
in
- InputStreamisIgnoreModelVersion
- Select if you need a Model Version Check
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
NonCompatibleException
- Old Model Version (The version of API is older than the version of Astah this project has been last edited with)
ClassNotFoundException
- Cannot read some models
IOException
- input/output errorabstract IFacet getFacet(String symbolicName)
symbolicName
- symbolic name of the facet
null
.abstract List<IFacet> getFacets()
abstract IModel getProject()
abstract boolean hasProject()
abstract IModel getCurrentProject()
abstract void close()
abstract void create(String projectPath, boolean useDefinedTaggedValues)
projectPath
- Project PathuseDefinedTaggedValues
- Set if you need to load the user defined tagged values as creating the project
IOException
- input/output errorabstract void create(String projectPath)
projectPath
- Project Path
IOException
- input/output errorabstract void create()
IOException
- input/output errorabstract void save()
LicenseNotFoundException
- License cannot be found
ProjectNotFoundException
- Project cannot be found
IOException
- input/output error
Project has been lockedabstract void validateProject()
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models existabstract void addReferenceProject(String path)
path
- Reference Project Path. Absolute/Relative Path can be specified.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models exist
Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in Astah community. PARAMETER_ERROR_KEY - if a parameter is not set properly.
Values: Error messages for exceptions.
abstract void removeReferenceProject(String path)
path
- Reference Project Path. Absolute/Relative Path can be specified.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models exist
Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in Astah community. PARAMETER_ERROR_KEY - if a parameter is not set properly.
Values: Error messages for exceptions.
abstract void updateReferenceProject(String path)
path
- Reference Project Path. Absolute/Relative Path can be specified.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models exist
Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in Astah community. PARAMETER_ERROR_KEY - if a parameter is not set properly.
Values: Error messages for exceptions.
abstract void clearReferenceProject(String path)
path
- Reference Project Path. Absolute/Relative Path can be specified.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models exist
Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in Astah community. PARAMETER_ERROR_KEY - if a parameter is not set properly.
Values: Error messages for exceptions.
abstract void changeReferenceProject(String fromPath, String toPath)
fromPath
- Original Reference Project Path. Absolute/Relative Path can be specified.toPath
- New Reference Project Path
Absolute/Relative Path can be specified.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models exist
Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in Astah community. PARAMETER_ERROR_KEY - if a parameter is not set properly.
Values: Error messages for exceptions.
abstract String[] getReferenceProjectPaths()
ProjectNotFoundException
- Project doesn't existabstract int getReferenceProjectStatus(String path)
path
- Reference Project Path. Absolute/Relative Path can be specified.
ProjectAccessor.REFERENCE_PROJECT_STATUS_LATEST:Latest ProjectAccessor.REFERENCE_PROJECT_STATUS_NEED_UPDATE :Need Update ProjectAccessor.REFERENCE_PROJECT_STATUS_NOT_FOUND :Not Found
ProjectNotFoundException
- Project doesn't existabstract void easyMerge(String path, boolean isKeepBase)
path
- Reference Project Path. Absolute/Relative Path can be specified.isKeepBase
- When differences found, keep current or overwrite with reference.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models exist
Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in Astah community. CAN_NOT_MERGE_IN_TRANSACTION_KEY - if a file is merged in transaction. CAN_NOT_MERGE_WHEN_CURRENT_HAS_REFERENCE_PROJRCT_KEY - if a file is merged to the current project with reference models. PARAMETER_ERROR_KEY - if a parameter is not set properly.
Values: Error messages for exceptions.
abstract void easyCompare(String path)
path
- Reference Project Path. Absolute/Relative Path can be specified.
ProjectNotFoundException
- Project doesn't exist
InvalidEditingException
- Invalid models existabstract ITransactionManager getTransactionManager()
abstract IModelEditorFactory getModelEditorFactory()
abstract IDiagramEditorFactory getDiagramEditorFactory()
abstract INamedElement[] findElements(Class<E> elementKind, String name)
elementKind
- Element kind. API Class name is used for element kind, like IClass.name
- Element name.If name is null,Search elements in an Astah model by element kind.
ProjectNotFoundException
- Project doesn't existabstract INamedElement[] findElements(Class<E> elementKind)
elementKind
- Element kind. API Class name is used for element kind, like IClass.
ProjectNotFoundException
- Project doesn't existabstract INamedElement[] findElements(ModelFinder picker)
picker
- ModelFinder contains conditions searching models.Searching conditions should be implemented.
ProjectNotFoundException
- Project doesn't existabstract void create(String projectPath, String templatePath, boolean useDefinedTaggedValues)
projectPath
- Project PathtemplatePath
- Template PathuseDefinedTaggedValues
- Set if you need to load the user defined tagged values as creating the project
IOException
- input/output error
ProjectNotFoundException
- Project cannot be foundabstract void create(String projectPath, String templatePath)
projectPath
- Project PathtemplatePath
- Template Path
IOException
- input/output error
Project cannot be foundabstract int getProjectModelVersion()
ProjectNotFoundException
- Project cannot be foundabstract String getAstahEdition()
abstract String getAstahVersion()
abstract String getProjectPath()
ProjectNotFoundException
- Project cannot be foundabstract String getAstahInstallPath()
abstract int getAstahModelVersion()
abstract String getAstahAPIVersion()
abstract int getAstahAPIModelVersion()
abstract IViewManager getViewManager()
InvalidUsingException
- InvalidUsingException occurs.abstract void addProjectEventListener(ProjectEventListener listener)
listener
- ProjectEventListenerabstract void removeProjectEventListener(ProjectEventListener listener)
listener
- ProjectEventListenerabstract void addEntityEditListener(EntityEditListener listener)
listener
- EntityEditListenerabstract void removeEntityEditListener(EntityEditListener listener)
listener
- EntityEditListenerabstract IEntity getEntity(String id)
id
- ID string of the IEntity you'd like to search
abstract boolean isProjectModified()
abstract boolean hasSameElement(String name)
name
- Element name
abstract boolean hasSameElement(String name, Class<E> clazz)
name
- Element nameclazz
- Element type class
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |