IBM Rational Software Modeler
Release 6.0

com.ibm.xtools.ras.profile.core
Interface IRASProfileService


public interface IRASProfileService

The profile factory is used to create or load instances of the profiles. It handles the version upgrade (if required) and identification of the type of profile. This interface is not intended to be implemented by clients.


Method Summary
 IAssetFactory getAssetFactory(String theProfileId)
          Get the asset factory for the specified profile id.
 IRASAssetReader getAssetReader(String theResourcePath)
          Get the asset reader for the specified resource path
 IRASAssetReader getAssetReader(String theResourcePath, String theManifestReference)
          Get the asset reader for the specified resource path
 IRASAssetWriter getAssetWriter(String theStorageFormat)
          Get the asset writer for the specified storage format.
 String getProfileName(String theProfileId)
          Get the name of profile for the specified profile id.
 IProfileFormat[] getReaderFormats()
          Returns an array of the supported formats for reading an asset.
 IProfileFormat[] getWriterFormats()
          Returns an array of the supported formats for writing an asset.
 

Method Detail

getAssetReader

public IRASAssetReader getAssetReader(String theResourcePath)
                               throws IOException
Get the asset reader for the specified resource path

Parameters:
theResourcePath - the path to the resource. For instance a file path for file based assets.
Returns:
the reader or null if none was found
Throws:
IOException - if there is an error reading the resource path

getAssetReader

public IRASAssetReader getAssetReader(String theResourcePath,
                                      String theManifestReference)
                               throws IOException
Get the asset reader for the specified resource path

Parameters:
theResourcePath - the path to the resource. For instance a file path for file based assets.
theManifestReference - optional; the manifest to use in the asset. This may be null in which case the reader should use the default manifest.
Returns:
the reader or null if none was found
Throws:
IOException - if there is an error reading the resource path

getAssetWriter

public IRASAssetWriter getAssetWriter(String theStorageFormat)
                               throws IOException
Get the asset writer for the specified storage format. The storage format indicates the type of writer to create.

Parameters:
theStorageFormat - indicates the format in which the asset will be stored.
Returns:
IRASAssetWriter the writer or null if none was found
Throws:
IOException - if an error occurred getting the asset writer

getAssetFactory

public IAssetFactory getAssetFactory(String theProfileId)
Get the asset factory for the specified profile id. If the profile is not supported then it will try to get the profile's parent and so on until it either finds a supported profile or one can not be found.

Parameters:
theProfileId - the id of the profile
Returns:
the asset factory or null if the profile id is not supported

getProfileName

public String getProfileName(String theProfileId)
Get the name of profile for the specified profile id. If the profile is not supported then it will return null.

Parameters:
theProfileId - the id of the profile
Returns:
the profile's name or null if the profile id is not supported

getReaderFormats

public IProfileFormat[] getReaderFormats()
Returns an array of the supported formats for reading an asset.

Returns:
the array of formats that are supported

getWriterFormats

public IProfileFormat[] getWriterFormats()
Returns an array of the supported formats for writing an asset.

Returns:
the array of formats that are supported

IBM Rational Software Modeler
Release 6.0


Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp. and others 2004. All rights reserved.