NEOCCA bindings Specification  0.2.8
Public Member Functions | List of all members
neo::cca::ports::ServiceProvider Class Referenceabstract

NOT YET DEFINED IN CCA.SIDL: ServiceProvider interface implements a non-singleton service Port. More...

#include <ServiceProvider.hh>

Inheritance diagram for neo::cca::ports::ServiceProvider:
Inheritance graph
[legend]
Collaboration diagram for neo::cca::ports::ServiceProvider:
Collaboration graph
[legend]

Public Member Functions

virtual ~ServiceProvider ()
 
virtual const std::string createService (const std::string &portType)=0
 Create the Port for the Service, informing the framework through "addProvidesPort()" on the originating component. More...
 
virtual void destroyService (const std::string &portName)=0
 Informs the originating component that the instance of the provided service is no longer needed. More...
 
- Public Member Functions inherited from neo::cca::Port
virtual ~Port ()
 obligatory virtual destructor More...
 

Detailed Description

NOT YET DEFINED IN CCA.SIDL: ServiceProvider interface implements a non-singleton service Port.

It is a port type that can be exported as normal or to the framework exclusively by using the ServiceRegistry port. This is the Port interface that is implemented by a component wishing to provide a service for other components. The behavior is as follows:

  1. The component registers for a ServiceRegistry Port (above) and does a "getPort()" to get it.
  2. It adds a ServiceProvider Port to the ServiceRegistry.
  3. When called the implementation of ServiceProvider::createService() must create the Port asked for, and addProvidesPort to register it on the originating component. createService() returns the Port instance name for this Port just provided.
  4. The framework connects the originating component to the component requesting the service.

This port is implemented by each binding and the bindings have to intercept corresponding addProvidesPort calls to wrap the native ServiceProvider implementation in a ccafeopq form.

Constructor & Destructor Documentation

◆ ~ServiceProvider()

virtual neo::cca::ports::ServiceProvider::~ServiceProvider ( )
inlinevirtual
40 {}

Member Function Documentation

◆ createService()

virtual const std::string neo::cca::ports::ServiceProvider::createService ( const std::string &  portType)
pure virtual

Create the Port for the Service, informing the framework through "addProvidesPort()" on the originating component.

Returns
the name of the port created.

◆ destroyService()

virtual void neo::cca::ports::ServiceProvider::destroyService ( const std::string &  portName)
pure virtual

Informs the originating component that the instance of the provided service is no longer needed.

The ServiceProvider can now safely removePort on the named port.


The documentation for this class was generated from the following file: