private ComposableBody applySessionData ( final long rid , final ComposableBody orig ) throws BOSHException { assertLocked ( ) ; Builder builder = orig . rebuild ( ) ; builder . setAttribute ( Attributes . SID , cmParams . getSessionID ( ) . toString ( ) ) ; builder . setAttribute ( Attributes . RID , Long . toString ( rid ) ) ; if ( cfg . isAckEnabled ( ) ) { applyResponseAcknowledgement ( builder , rid ) ; } return builder . build ( ) ; }
Applies existing session data to the outbound request returning the modified request .