/** * Accepts the In-Band Bytestream open request and returns the session to * send/receive data. * * @return the session to send/receive data * @throws NotConnectedException * @throws InterruptedException */ @Override public InBandBytestreamSession accept() throws NotConnectedException, InterruptedException { XMPPConnection connection = this.manager.getConnection(); // create In-Band Bytestream session and store it InBandBytestreamSession ibbSession = new InBandBytestreamSession(connection, this.byteStreamRequest, this.byteStreamRequest.getFrom()); this.manager.getSessions().put(this.byteStreamRequest.getSessionID(), ibbSession); // acknowledge request IQ resultIQ = IQ.createResultIQ(this.byteStreamRequest); connection.sendStanza(resultIQ); return ibbSession; }
/** * Accepts the In-Band Bytestream open request and returns the session to * send/receive data. * * @return the session to send/receive data * @throws XMPPException if stream is invalid. */ public InBandBytestreamSession accept() throws XMPPException { Connection connection = this.manager.getConnection(); // create In-Band Bytestream session and store it InBandBytestreamSession ibbSession = new InBandBytestreamSession(connection, this.byteStreamRequest, this.byteStreamRequest.getFrom()); this.manager.getSessions().put(this.byteStreamRequest.getSessionID(), ibbSession); // acknowledge request IQ resultIQ = IQ.createResultIQ(this.byteStreamRequest); connection.sendPacket(resultIQ); return ibbSession; }
/** * Accepts the In-Band Bytestream open request and returns the session to * send/receive data. * * @return the session to send/receive data * @throws XMPPException if stream is invalid. */ public InBandBytestreamSession accept() throws XMPPException { Connection connection = this.manager.getConnection(); // create In-Band Bytestream session and store it InBandBytestreamSession ibbSession = new InBandBytestreamSession(connection, this.byteStreamRequest, this.byteStreamRequest.getFrom()); this.manager.getSessions().put(this.byteStreamRequest.getSessionID(), ibbSession); // acknowledge request IQ resultIQ = IQ.createResultIQ(this.byteStreamRequest); connection.sendPacket(resultIQ); return ibbSession; }
/** * Accepts the In-Band Bytestream open request and returns the session to * send/receive data. * * @return the session to send/receive data * @throws XMPPException if stream is invalid. */ public InBandBytestreamSession accept() throws XMPPException { Connection connection = this.manager.getConnection(); // create In-Band Bytestream session and store it InBandBytestreamSession ibbSession = new InBandBytestreamSession(connection, this.byteStreamRequest, this.byteStreamRequest.getFrom()); this.manager.getSessions().put(this.byteStreamRequest.getSessionID(), ibbSession); // acknowledge request IQ resultIQ = IQ.createResultIQ(this.byteStreamRequest); connection.sendPacket(resultIQ); return ibbSession; }