public synchronized int getUniqueRequestNumber ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getUniqueRequestNumber" ) ; // Always add two requestNumber += 2 ; if ( requestNumber > Short . MAX_VALUE ) { // Reset the number to 0 for even, or 1 for odd requestNumber = requestNumber % 2 ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( this , tc , "getUniqueRequestNumber" , "" + requestNumber ) ; return requestNumber ; }
This method will return a unique number that can be used for JFAP exchanges . as this can be for ME - ME comms unique number is always increased by two . As such if the initiating peer uses odd request numbers they will always use unique numbers .