org.jivesoftware.smackx.jingle
Class JingleSessionRequest

java.lang.Object
  extended by org.jivesoftware.smackx.jingle.JingleSessionRequest

public class JingleSessionRequest
extends java.lang.Object

A Jingle session request.

This class is a facade of a received Jingle request. The user can have direct access to the Jingle packet (JingleSessionRequest.getJingle() ) of the request or can use the convencience methods provided by this class.

Author:
Alvaro Saurin

Constructor Summary
JingleSessionRequest(JingleManager manager, Jingle jingle)
          A recieve request is constructed from the Jingle Initiation request received from the initator.
 
Method Summary
 JingleSession accept()
          Accepts this request and creates the incoming Jingle session.
 java.lang.String getFrom()
          Returns the fully-qualified jabber ID of the user that requested this session.
 Jingle getJingle()
          Returns the Jingle packet that was sent by the requester which contains the parameters of the session.
 java.lang.String getSessionID()
          Returns the session ID that uniquely identifies this session.
 void reject()
          Rejects the session request.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JingleSessionRequest

public JingleSessionRequest(JingleManager manager,
                            Jingle jingle)
A recieve request is constructed from the Jingle Initiation request received from the initator.

Parameters:
manager - The manager handling this request
jingle - The jingle IQ recieved from the initiator.
Method Detail

getFrom

public java.lang.String getFrom()
Returns the fully-qualified jabber ID of the user that requested this session.

Returns:
Returns the fully-qualified jabber ID of the user that requested this session.

getSessionID

public java.lang.String getSessionID()
Returns the session ID that uniquely identifies this session.

Returns:
Returns the session ID that uniquely identifies this session

getJingle

public Jingle getJingle()
Returns the Jingle packet that was sent by the requester which contains the parameters of the session.


accept

public JingleSession accept()
                     throws XMPPException
Accepts this request and creates the incoming Jingle session.

Returns:
Returns the IncomingJingleSession on which the negotiation can be carried out.
Throws:
XMPPException

reject

public void reject()
Rejects the session request.