@ CheckForNull public String extractMemcachedId ( @ Nonnull final String sessionId ) { final int idxDash = sessionId . indexOf ( ' ' ) ; if ( idxDash < 0 ) { return null ; } final int idxDot = sessionId . indexOf ( ' ' ) ; if ( idxDot < 0 ) { return sessionId . substring ( idxDash + 1 ) ; } else if ( idxDot < idxDash ) /* The dash was part of the jvmRoute */ { return null ; } else { return sessionId . substring ( idxDash + 1 , idxDot ) ; } }
Extract the memcached id from the given session id .