Top Description Fields Constructors Methods
com.sun.mail.imap.protocol

public Class MessageSet

extends Object
Class Inheritance
Imports
java.util.List, .ArrayList

This class holds the 'start' and 'end' for a range of messages.

Field Summary

Modifier and TypeField and Description
public int
public int

Constructor Summary

AccessConstructor and Description
public
public
MessageSet(int start, int end)

Method Summary

Modifier and TypeMethod and Description
public static MessageSet[]

Returns:

array of MessageSet objects
createMessageSets
(int[]
the messages
msgs
)

Convert an array of integers into an array of MessageSets

public int

Returns:

how many messages in this MessageSet
size
()

Count the total number of elements in a MessageSet

public static int
size(MessageSet[] msgsets)

public static String

Returns:

IMAP sequence string
toString
(MessageSet[]
the MessageSets
msgsets
)

Convert an array of MessageSets into an IMAP sequence range

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

endback to summary
public int end
startback to summary
public int start

Constructor Detail

MessageSetback to summary
public MessageSet()
MessageSetback to summary
public MessageSet(int start, int end)

Method Detail

createMessageSetsback to summary
public static MessageSet[] createMessageSets(int[] msgs)

Convert an array of integers into an array of MessageSets

Parameters
msgs:int[]

the messages

Returns:MessageSet[]

array of MessageSet objects

sizeback to summary
public int size()

Count the total number of elements in a MessageSet

Returns:int

how many messages in this MessageSet

sizeback to summary
public static int size(MessageSet[] msgsets)
toStringback to summary
public static String toString(MessageSet[] msgsets)

Convert an array of MessageSets into an IMAP sequence range

Parameters
msgsets:MessageSet[]

the MessageSets

Returns:String

IMAP sequence string