Jive Forums API (5.5.20.2-oracle) Developer Javadocs

com.jivesoftware.forum.nntp
Class MessageID

java.lang.Object
  extended by com.jivesoftware.forum.nntp.MessageID

public class MessageID
extends java.lang.Object

Utility class for managing, generating, and parsing Message-ID's.


Method Summary
static boolean isMessageID(java.lang.String id)
          Determines if the given string is a valid Message-ID or not.
static long parseMessageID(java.lang.String id)
          Takes a message ID and strips the angle brackets from it.
static java.lang.String toMessageID(long messageID)
          Takes a bare ID string, and converts it into a valid message-id string by wrapping angle brackets around it.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isMessageID

public static boolean isMessageID(java.lang.String id)
Determines if the given string is a valid Message-ID or not. To be a valid ID, the string must begin and end with a angle brackets (e.g. <valid-id>).

Parameters:
id - The ID to validate
Returns:
True if the string is a valid message ID

toMessageID

public static java.lang.String toMessageID(long messageID)
Takes a bare ID string, and converts it into a valid message-id string by wrapping angle brackets around it.

Parameters:
messageID - the ID to convert.
Returns:
the generated ID.

parseMessageID

public static long parseMessageID(java.lang.String id)
Takes a message ID and strips the angle brackets from it.

Parameters:
id - The Message-ID to strip
Returns:
The ID stripped of it's angle brackets

Jive Forums Project Page

Copyright © 1999-2006 Jive Software.