edu.cmu.sei.osate.workspace
Interface IAadlWorkspace

All Superinterfaces:
IAadlElement, IParent

public interface IAadlWorkspace
extends IAadlElement, IParent

Represent the root AADL element corresponding to the workspace. There is only one such root element. The AADL model element has no parent (it is the root of the Java element hierarchy). Its children are IJavaProject s.

This interface provides methods for performing copy, move, rename, and delete operations on multiple Java elements.

This interface is not intended to be implemented by clients. An instance of one of these handles can be created via JavaCore.create(workspace.getRoot()).


Field Summary
 
Fields inherited from interface edu.cmu.sei.osate.workspace.IAadlElement
AADL_PACKAGE, AADL_PROPERTYSET, AADL_SPECIFICATION
 
Method Summary
 boolean contains(org.eclipse.core.resources.IResource resource)
           
 org.eclipse.core.resources.IFile findAadlModelFile(java.lang.String name)
          Search all projects in the workspace for the XML model file of the given package or property set name.
 org.eclipse.core.resources.IFile findAadlSourceFile(java.lang.String name)
          Search all projects in the workspace for the source file of the given package or property set name.
 IAadlProject getAadlProject(org.eclipse.core.resources.IResource resource)
          Returns the AADL project for a given workbench resource.
 IAadlProject getAadlProject(java.lang.String name)
          Returns the AADL project with the given name.
 IAadlProject[] getAadlProjects()
          Returns the AADL projects in this AADL workspace, or an empty array if there are none.
 org.eclipse.emf.common.util.EList<org.eclipse.core.resources.IFile> getAllModelFiles()
          return all model & instance files in a Workspace, i.e., files with the extension "aadl"
 IAadlProject[] getOpenAadlProjects()
          Creates AADL projects for all open projects in the workspace that have an AADL nature.
 org.eclipse.core.resources.IWorkspace getWorkspace()
          Returns the workspace associated with this Java model.
 void removeFromLookupTable(org.eclipse.core.resources.IFile f)
          remove the specified file from the lookup table
 
Methods inherited from interface edu.cmu.sei.osate.workspace.IAadlElement
getAadlProject, getParent
 
Methods inherited from interface edu.cmu.sei.osate.workspace.IParent
getChildren, hasChildren
 

Method Detail

contains

boolean contains(org.eclipse.core.resources.IResource resource)
Parameters:
resource - the resource to check
Returns:
true if the resource is accessible through the Java model
Since:
2.1

getAadlProject

IAadlProject getAadlProject(java.lang.String name)
Returns the AADL project with the given name. This is a handle-only method. The project may or may not exist.

Parameters:
name - the name of the AADL project
Returns:
the AADL project with the given name

getAadlProject

IAadlProject getAadlProject(org.eclipse.core.resources.IResource resource)
Returns the AADL project for a given workbench resource. This is a handle-only method. The project may or may not exist.

Returns:
the AADL project with the given name

getAadlProjects

IAadlProject[] getAadlProjects()
Returns the AADL projects in this AADL workspace, or an empty array if there are none.

Returns:
the AADL projects in this AADL workspace, or an empty array if there are none

getOpenAadlProjects

IAadlProject[] getOpenAadlProjects()
Creates AADL projects for all open projects in the workspace that have an AADL nature.

Returns:
An array of AADL project handles.

getWorkspace

org.eclipse.core.resources.IWorkspace getWorkspace()
Returns the workspace associated with this Java model.

Returns:
the workspace associated with this Java model

findAadlSourceFile

org.eclipse.core.resources.IFile findAadlSourceFile(java.lang.String name)
Search all projects in the workspace for the source file of the given package or property set name. Also check if the file is unique in the workspace.

Parameters:
name - the name of the package to find.
Returns:
the source file for the package, or null if not found.

findAadlModelFile

org.eclipse.core.resources.IFile findAadlModelFile(java.lang.String name)
Search all projects in the workspace for the XML model file of the given package or property set name. Also check if the file is unique in the workspace.

Parameters:
name - the name of the file to find.
Returns:
the model file for the package, or null if not found.

getAllModelFiles

org.eclipse.emf.common.util.EList<org.eclipse.core.resources.IFile> getAllModelFiles()
return all model & instance files in a Workspace, i.e., files with the extension "aadl"

Returns:
EList of IFiles that represent AADL model files

removeFromLookupTable

void removeFromLookupTable(org.eclipse.core.resources.IFile f)
remove the specified file from the lookup table

Parameters:
f - IFile