public void setTransactionID ( byte [ ] tranID ) throws StunException { if ( tranID == null || ( tranID . length != TRANSACTION_ID_LENGTH && tranID . length != RFC3489_TRANSACTION_ID_LENGTH ) ) throw new StunException ( StunException . ILLEGAL_ARGUMENT , "Invalid transaction id length" ) ; int tranIDLength = tranID . length ; this . transactionID = new byte [ tranIDLength ] ; System . arraycopy ( tranID , 0 , this . transactionID , 0 , tranIDLength ) ; }
Copies the specified tranID and sets it as this message s transactionID .