String publishSubject(long sessionId) {
    if (prefix == null) {
      return String.format("publish-%d", sessionId);
    } else {
      return String.format("%s-publish-%d", prefix, sessionId);
    }
  }
String publishSubject ( long sessionId ) { if ( prefix == null ) { return String . format ( "publish-%d" , sessionId ) ; } else { return String . format ( "%s-publish-%d" , prefix , sessionId ) ; } }
Returns the publish subject for the given session.

@param sessionId the session for which to return the publish subject
@return the publish subject for the given session