2008-09-10 1.1.0

org.eclipse.soda.dk.transport.test.bundle
Class TransportTestBundle

java.lang.Object
  extended by org.eclipse.soda.sat.core.framework.BaseBundleActivator
      extended by org.eclipse.soda.dk.connection.bundle.ServiceBundle
          extended by org.eclipse.soda.dk.connection.bundle.ServiceInterestBundle
              extended by org.eclipse.soda.dk.transport.test.bundle.TransportTestBundle
All Implemented Interfaces:
org.eclipse.soda.sat.core.record.interfaces.ServiceDetecterListener, org.osgi.framework.BundleActivator

public abstract class TransportTestBundle
extends ServiceInterestBundle
implements org.osgi.framework.BundleActivator, org.eclipse.soda.sat.core.record.interfaces.ServiceDetecterListener

Transport Test Bundle class.

Version:
1.1.0

Field Summary
static java.lang.String CLASS_NAME
          Defines the class name.
protected  org.eclipse.soda.sat.core.record.interfaces.IServiceDetecter detecter
          Define the detecter (IServiceDetecter) field.
protected  TransportTestService testCase
          Save the tester object.
 
Fields inherited from class org.eclipse.soda.dk.connection.bundle.ServiceBundle
DEVICE_CLASS, DEVICE_REVISION
 
Fields inherited from class org.eclipse.soda.sat.core.framework.BaseBundleActivator
NO_SERVICES
 
Constructor Summary
TransportTestBundle()
           
 
Method Summary
protected  void activate()
          Activates the bundle.
 java.util.Hashtable createProperties()
          Gets the properties to be registered with the service(s).
 java.lang.Object createService()
          Create the Tester.
 TransportTestService createService(TransportService transport)
          Create the Tester for the specified transport.
protected  void deactivate()
          Stop the test case and the bundle.
abstract  java.lang.String[] getExportedServiceNames()
          Return the service name(s) to be registered by the bundle.
abstract  java.lang.String getInterestServiceName()
          Gets the transport service name to be tested.
 void serviceAdded(org.eclipse.soda.sat.core.record.interfaces.IServiceDetecter detecter, org.osgi.framework.ServiceReference serviceReference, java.lang.Object service)
           
 void serviceRemoved(org.eclipse.soda.sat.core.record.interfaces.IServiceDetecter detecter, org.osgi.framework.ServiceReference serviceReference, java.lang.Object service)
           
 void setInterest(java.lang.Object interest)
          Sets the interest object.
protected  void start()
          Start.
protected  void stop()
          Stop.
 
Methods inherited from class org.eclipse.soda.dk.connection.bundle.ServiceInterestBundle
destroyExportedServices, getInterest, updateProperties
 
Methods inherited from class org.eclipse.soda.dk.connection.bundle.ServiceBundle
getService, log, log, setService
 
Methods inherited from class org.eclipse.soda.sat.core.framework.BaseBundleActivator
acquireImportedService, acquireImportedServices, acquireOptionalImportedServices, addExportedProxyService, addExportedProxyServices, addExportedService, addExportedServices, addImportedServiceFilter, addOptionalImportedServiceFilter, basicGetImportedServiceNames, basicGetOptionalImportedServiceNames, collectImportedServiceNames, collectOptionalImportedServiceNames, getAsyncStartPriority, getBundle, getBundleActivationManager, getBundleContext, getBundleSymbolicName, getDataDirectory, getDataFile, getExportedService, getExportedServiceNamesFromManifest, getExportedServiceProperties, getExportedServiceProperties, getExportedServices, getExportedServices, getFilePropertiesInputStream, getFilePropertiesInputStream, getImportedService, getImportedServiceFilter, getImportedServiceNames, getImportedServiceNamesFromManifest, getImportedServiceProperty, getImportedServicePropertyKeys, getImportedServices, getOptionalImportedService, getOptionalImportedServiceFilter, getOptionalImportedServiceNames, getOptionalImportedServiceProperty, getOptionalImportedServicePropertyKeys, getOptionalImportedServices, getProperties, getPropertiesInputStream, getProperty, getResourcePropertiesInputStream, getResourcePropertiesInputStream, handleAcquiredOptionalImportedService, handleException, handleFailedToFindProperties, handleReleasedOptionalImportedService, isStartAsync, isTransient, isUninstallable, releaseImportedService, releaseImportedServices, releaseOptionalImportedServices, removeExportedService, removeExportedService, removeExportedServices, removeImportedServiceFilter, removeOptionalImportedServiceFilter, restartFramework, setExportedServiceProperties, setExportedServiceProperties, shutdownFramework, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.osgi.framework.BundleActivator
start, stop
 

Field Detail

CLASS_NAME

public static final java.lang.String CLASS_NAME
Defines the class name.


testCase

protected TransportTestService testCase
Save the tester object.


detecter

protected org.eclipse.soda.sat.core.record.interfaces.IServiceDetecter detecter
Define the detecter (IServiceDetecter) field.

Constructor Detail

TransportTestBundle

public TransportTestBundle()
Method Detail

activate

protected void activate()
Activates the bundle.

Overrides:
activate in class ServiceInterestBundle

createProperties

public java.util.Hashtable createProperties()
Gets the properties to be registered with the service(s).

Overrides:
createProperties in class ServiceBundle
Returns:
Hashtable of properties.

createService

public java.lang.Object createService()
Create the Tester.

Overrides:
createService in class ServiceBundle
Returns:
Results of the create service (Object) value.
See Also:
createService(TransportService)

createService

public TransportTestService createService(TransportService transport)
Create the Tester for the specified transport. The transport (TransportService) parameter.

Parameters:
transport - The transport (TransportService) parameter.
Returns:
Results of the create service (Object) value.
See Also:
createService()

deactivate

protected void deactivate()
Stop the test case and the bundle.

Overrides:
deactivate in class org.eclipse.soda.sat.core.framework.BaseBundleActivator

getExportedServiceNames

public abstract java.lang.String[] getExportedServiceNames()
Return the service name(s) to be registered by the bundle.

Specified by:
getExportedServiceNames in class ServiceBundle
Returns:
Results of the get service names (String[]) value.

getInterestServiceName

public abstract java.lang.String getInterestServiceName()
Gets the transport service name to be tested.

Overrides:
getInterestServiceName in class ServiceInterestBundle
Returns:
Results of the get interest service name (String) value.

serviceAdded

public void serviceAdded(org.eclipse.soda.sat.core.record.interfaces.IServiceDetecter detecter,
                         org.osgi.framework.ServiceReference serviceReference,
                         java.lang.Object service)
Specified by:
serviceAdded in interface org.eclipse.soda.sat.core.record.interfaces.ServiceDetecterListener
Parameters:
detecter - The detecter (IServiceDetecter) parameter.
serviceReference - The service reference (ServiceReference) parameter.
service - The service (Object) parameter.

serviceRemoved

public void serviceRemoved(org.eclipse.soda.sat.core.record.interfaces.IServiceDetecter detecter,
                           org.osgi.framework.ServiceReference serviceReference,
                           java.lang.Object service)
Specified by:
serviceRemoved in interface org.eclipse.soda.sat.core.record.interfaces.ServiceDetecterListener
Parameters:
detecter - The detecter (IServiceDetecter) parameter.
serviceReference - The service reference (ServiceReference) parameter.
service - The service (Object) parameter.

setInterest

public void setInterest(java.lang.Object interest)
Sets the interest object. The interest (Object) parameter.

Overrides:
setInterest in class ServiceInterestBundle
Parameters:
interest - The interest (Object) parameter.
See Also:
ServiceInterestBundle.getInterest()

start

protected void start()
              throws java.lang.Exception
Start.

Overrides:
start in class org.eclipse.soda.sat.core.framework.BaseBundleActivator
Throws:
java.lang.Exception - Exception.

stop

protected void stop()
             throws java.lang.Exception
Stop.

Overrides:
stop in class org.eclipse.soda.sat.core.framework.BaseBundleActivator
Throws:
java.lang.Exception - Exception.

2008-09-10 1.1.0

Copyright (c) 1999, 2008 IBM and others. See license in Legal section. OSGi Framework Version 3.4.0.v20080605-1900