Skip navigation links

Oracle Communications Converged Application Server Java API Reference
5.1

E36938-01


com.oracle.sft.api
Interface Interaction

All Superinterfaces:
Communication
All Known Subinterfaces:
Conference, Conversation, IMConference, IMConversation, MSRPConference, MSRPConversation, QueryInteraction

public interface Interaction
extends Communication

A communication where more than one Participant interact with each other. Conversation Conference etc are typical Communications that are Interactions.


Nested Class Summary

 

Nested classes/interfaces inherited from interface com.oracle.sft.api.Communication
Communication.State

 

Method Summary
<P extends Participant>
void
addParticipant(Class<P> type, String name)
          Add a participant to the interaction.
<P extends Participant>
void
addParticipant(Class<P> type, String name, javax.media.mscontrol.join.Joinable j)
          Add a participant that can be added to the interaction with a specific Joinable.
 void addParticipant(Participant p)
          Add a participant to the communication.
 void addParticipant(String name)
          Add a UserParticipant to the interaction.
<P extends Participant>
P
getParticipant(Class<P> type, String name)
          Retrieve a Participant from the interaction.
 Participant getParticipant(String name)
          Retrieve a Participant from the interaction.
 void removeParticipant(Participant p)
          Remove a participant from the interaction.
 void removeParticipant(String name)
          Remove any type of participant from the interaction.
 void replaceParticipant(Participant replaced, Participant replacing)
          Replace a participant with another Participant.
 void replaceParticipant(Participant replaced, Participant replacing, boolean purge)
          The enhanced function for participants replacement.

 

Methods inherited from interface com.oracle.sft.api.Communication
addAgent, end, getAgent, getAgents, getInitiator, getName, getState, removeAgent

 

Method Detail

addParticipant

void addParticipant(String name)
Add a UserParticipant to the interaction. Executing this method will initiate a call with that participant. Following is an example code. An IllegalArgumentException will be thrown if a participant of the same name already exists. Communication c = ....; c.addParticipant("alice@example.com");
Parameters:
name - Name of the UserParticipant

addParticipant

void addParticipant(Participant p)
Add a participant to the communication.
Parameters:
p - Add a participant to the communicaton.

addParticipant

<P extends Participant> void addParticipant(Class<P> type,
                                            String name)
Add a participant to the interaction. For example, for adding a Recorder to the interaction, the following code could be used. An IllegalArgumentException will be thrown if a participant of the same name already exists. Interaction c = ....; c.addParticipant(Recorder.class, "recorder-1");
Type Parameters:
P - Any Participant type which is a child of a Participant.
Parameters:
type - Any Class that is a child of Participant.
name - Name of the participant

addParticipant

<P extends Participant> void addParticipant(Class<P> type,
                                            String name,
                                            javax.media.mscontrol.join.Joinable j)
Add a participant that can be added to the interaction with a specific Joinable. For example, for adding a Recorder to the interaction, the following code could be used. An IllegalArgumentException will be thrown if a participant of the same name already exists. Interaction c = ....; MediaGroup mg = ....; //Get/create mediagroup. c.createMediaParticipant(Recorder.class, "recorder-1", mg); The Joinable passed in can be retrieved using getJoinable method. If it is null, then a new JSR 309 Joinable will be created by SFT.
Type Parameters:
P - Any Participant type which is a child of a Participant.
Parameters:
type - Any Class that is a child of Participant.
name - Name of the participant
j - An instance of Joinable object.

removeParticipant

void removeParticipant(String name)
Remove any type of participant from the interaction. IMConversation and QueryInteraction will not support this function, and exception will be thrown if the method is invoked
Parameters:
name - Name of the Participant

removeParticipant

void removeParticipant(Participant p)
Remove a participant from the interaction. IMConversation and QueryInteraction will not support this function, and exception will be thrown if the method is invoked
Parameters:
p - Participant object.

getParticipant

Participant getParticipant(String name)
Retrieve a Participant from the interaction.
Parameters:
name - Name of the Participant
Returns:
a Participant object

getParticipant

<P extends Participant> P getParticipant(Class<P> type,
                                         String name)
Retrieve a Participant from the interaction.
Type Parameters:
P - A sub-type of a Participant.
Parameters:
name - Name of the Participant
type - Type of the participant.
Returns:
a Participant object.

replaceParticipant

void replaceParticipant(Participant replaced,
                        Participant replacing)
Replace a participant with another Participant. This method provide an optimized alternative to executing removeParticipant(Participant) followed by addparticipant(Participant). For example, if both the Participants contain the same Joinable, SFT might consider a very simple object replacement, rather than a more intensive Participant replacement that might involve sending re-INVItes to put the Participants on hold.a MSRPConversation, IMConversation and QueryInteraction will not support this function, and exception will be thrown if the method is invoked in those communication
Parameters:
replaced - Participant to be replaced.
replacing - New Participant that replaces the replaced

replaceParticipant

void replaceParticipant(Participant replaced,
                        Participant replacing,
                        boolean purge)
The enhanced function for participants replacement. Only Conversation supports this function. If purge is true, then it is identical to another overload function with two parameters.
Parameters:
replaced - Participant to be replaced.
replacing - New Participant which replaces the replaced
purge - If purge is true, the replaced Participant will be Byed/Canceled/Rejected, and its life-cycle in communication will be terminated; If purge is false, the replaced Participant would be lay-asided, it does not take part in communication activity in certain period. but Communication still maintains its call state, and it will take part in communication activity again once its original role is restored.

Skip navigation links

Oracle Communications Converged Application Server Java API Reference
5.1

E36938-01


Copyright © 2012 Oracle Corporation. All Rights Reserved.