eclipseme.core.model.impl
Class PlatformComponent

java.lang.Object
  extended byeclipseme.core.model.impl.PlatformComponent
All Implemented Interfaces:
org.eclipse.core.runtime.IAdaptable, IPlatformComponent, java.io.Serializable
Direct Known Subclasses:
AbstractEmulator, Configuration, PlatformDefinition, Profile, WirelessToolkit

public abstract class PlatformComponent
extends java.lang.Object
implements IPlatformComponent, java.io.Serializable

Abstract superclass of the various platform components.

Note: This class/interface is part of an interim API that is still under development and expected to change before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken as the API evolves.

Copyright (c) 2003-2005 Craig Setera
All Rights Reserved.
Licensed under the Eclipse Public License - v 1.0


$Revision: 1.5 $
$Date: 2005/07/07 02:36:58 $

Author:
Craig Setera
See Also:
Serialized Form

Constructor Summary
PlatformComponent(java.lang.String identifier, java.lang.String name, Version version)
          Construct a new PlatformComponent.
 
Method Summary
 void addDependentComponent(IPlatformComponent component)
          Add a component to the list of components that are dependent on this component.
 java.lang.Object getAdapter(java.lang.Class adapter)
           
 java.util.Iterator getDependentComponents()
          Return an Iterator on the list of components that are dependent on this component.
 java.lang.String getIdentifier()
          Return the unique identifier of this platform component.
 java.lang.String getName()
          Return the name of this platform component.
 Version getVersion()
          Get the version of this platform component.
 boolean hasDependentComponents()
          Return a boolean indicating whether there are components that are dependent on this component.
 boolean isDerived()
          Return a boolean indicating whether or not this component is derived from another component.
 void removeDependentComponent(IPlatformComponent component)
          Remove a component from the list of components that are dependent on this component.
 void setDerived(boolean derived)
          Set the derived status of this component.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface eclipseme.core.model.IPlatformComponent
getPersistenceDelegate
 

Constructor Detail

PlatformComponent

public PlatformComponent(java.lang.String identifier,
                         java.lang.String name,
                         Version version)
Construct a new PlatformComponent.

Parameters:
identifier - the unique identifier for this component
name - the displayable name for this component
version - the version of this component
Method Detail

addDependentComponent

public void addDependentComponent(IPlatformComponent component)
Description copied from interface: IPlatformComponent
Add a component to the list of components that are dependent on this component.

Specified by:
addDependentComponent in interface IPlatformComponent
Parameters:
component - the dependent component
See Also:
IPlatformComponent.addDependentComponent(eclipseme.core.model.IPlatformComponent)

getAdapter

public java.lang.Object getAdapter(java.lang.Class adapter)
Specified by:
getAdapter in interface org.eclipse.core.runtime.IAdaptable
See Also:
IAdaptable.getAdapter(java.lang.Class)

getDependentComponents

public java.util.Iterator getDependentComponents()
Description copied from interface: IPlatformComponent
Return an Iterator on the list of components that are dependent on this component.

Specified by:
getDependentComponents in interface IPlatformComponent
Returns:
the components dependent on this component
See Also:
IPlatformComponent.getDependentComponents()

getIdentifier

public java.lang.String getIdentifier()
Description copied from interface: IPlatformComponent
Return the unique identifier of this platform component. This identifier must be unique across all components of the same type (platform definition, profile, configuration, etc.) and must not be null.

Specified by:
getIdentifier in interface IPlatformComponent
Returns:
the unique identifier for this platform component. This value should never be null.
See Also:
IPlatformComponent.getIdentifier()

getName

public java.lang.String getName()
Description copied from interface: IPlatformComponent
Return the name of this platform component.

Specified by:
getName in interface IPlatformComponent
Returns:
The name. This value should never be null.
See Also:
IPlatformComponent.getName()

getVersion

public Version getVersion()
Description copied from interface: IPlatformComponent
Get the version of this platform component.

Specified by:
getVersion in interface IPlatformComponent
Returns:
the version of this component
See Also:
IPlatformComponent.getVersion()

isDerived

public boolean isDerived()
Description copied from interface: IPlatformComponent
Return a boolean indicating whether or not this component is derived from another component. Derived components are not persisted directly, as they are handled by their owning component.

Specified by:
isDerived in interface IPlatformComponent
Returns:
whether this component is a derivative of another component
See Also:
IPlatformComponent.isDerived()

hasDependentComponents

public boolean hasDependentComponents()
Description copied from interface: IPlatformComponent
Return a boolean indicating whether there are components that are dependent on this component.

Specified by:
hasDependentComponents in interface IPlatformComponent
Returns:
whether this component has dependent components
See Also:
IPlatformComponent.hasDependentComponents()

removeDependentComponent

public void removeDependentComponent(IPlatformComponent component)
Description copied from interface: IPlatformComponent
Remove a component from the list of components that are dependent on this component.

Specified by:
removeDependentComponent in interface IPlatformComponent
Parameters:
component - the component to be removed
See Also:
IPlatformComponent.removeDependentComponent(eclipseme.core.model.IPlatformComponent)

setDerived

public void setDerived(boolean derived)
Set the derived status of this component.

Parameters:
derived -