|
JSR-043: JTAPI-1.4 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A marker interface indicating that this object (possibly a JTAPI Provider) can be used directly as an argument to construct a MediaService object.
A MediaProvider implementation will provide the media services (for Resource allocation and configuration), call processing services for bind and release, and may provide other services such as OA&M.
A MediaService must be associated with some implementation that provides the requisite call and media services. The simplest way to find the media services implementation is to use the default obtained by using the no argument constructor.
The most general way for an application to specify the media service implementation to be used is by supplying a JtapiPeer class name and a peer-specific providerString to a MediaService constructor.
Sometimes, the media services implementation is obtained by
an alternative, vendor specific technique. For example, a vendor
may specify that its JTAPI Provider object supports media services.
In these cases, it should be declared that the object
implements MediaProvider
, so the object
may be cast to a MediaProvider and used in the constructor
for a MediaService.
BasicMediaService.BasicMediaService(MediaProvider)
Method Summary | |
MediaService |
getMediaService()
Return an unbound instance of this MediaProvider's preferred implementation of MediaService. |
Method Detail |
public MediaService getMediaService()
This precludes the application from extending the MediaService class with their own methods, but guarantees getting the most capable extension above BasicMediaService, without using the class name in the application.
This method allows a portable application to get a MediaService that has been extended by the MediaPeer vendor, without knowing the actual class name or the actual extensions. The application can then use the instanceof operator to see which of the standard optional interfaces has been implemented. Then the application can then upgrade or degrade its capabilities based on that information.
For example:
MediaProvider mp = ...; // get a MediaProvider MediaService ms = mp.getMediaService(); // get preferred MediaService if( ms instanceof ASR ) { ... } // use ASR capabilities if( ms instanceof Delegation ) { ... } // use Delegation capabilites if( ms instanceof Async.MediaService ) { ... } // use Async capabilities if( ms instanceof MediaConnection ) { ... } // use MediaConnection capabilites
|
JSR-043: JTAPI-1.4 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |