public class SomPumiceMessageStore extends SomPumiceObject implements SomPumiceHandler
Modifier and Type | Field and Description |
---|---|
static int |
SOM_PUMICE_CONNECTED_ANON |
static int |
SOM_PUMICE_CONNECTED_AUTH |
static int |
SOM_PUMICE_CONNECTING |
static int |
SOM_PUMICE_DISCONNECTED |
java.lang.Integer |
som_version |
errortext, somSession
Constructor and Description |
---|
SomPumiceMessageStore()
Create a new empty Message Store object, with some default settings
|
Modifier and Type | Method and Description |
---|---|
void |
abort(SomCommandListener listener)
Tell the Message Store to abort
|
void |
block(SomCommandListener listener,
java.lang.String op)
Tell the Message Store to block an operation
|
java.lang.String |
blockedOperations()
Get list of blocked operations in the Message Store
|
void |
connect()
Connect to the Message Store
|
java.lang.Integer |
curBindOps()
Get number of current outstanding Bind operations in the Message Store
|
java.lang.Integer |
curCancelDeferredDeliveryOps()
Get number of current outstanding cancel deferred delivery operations in the Message Store
|
java.lang.Integer |
curChangeCredentialsOps()
Get number of current change credentials operations in the Message Store
|
java.lang.Integer |
curDeleteOps()
Get number of current outstanding delete operations in the Message Store
|
java.lang.Integer |
curDeliverMessageOps()
Get number of current outstanding message delivery operations in the Message Store
|
java.lang.Integer |
curDeliverReportOps()
Get number of current outstanding report delivery operations in the Message Store
|
java.lang.Integer |
curDeliveryControlOps()
Get number of current outstanding delivery control operations in the Message Store
|
java.lang.Integer |
curFetchOps()
Get number of current outstanding fetch operations in the Message Store
|
java.lang.Integer |
curListOps()
Get number of current outstanding list operations in the Message Store
|
java.lang.Integer |
curRegisterMsOps()
Get number of current outstanding registerMS operations in the Message Store
|
java.lang.Integer |
curRegisterOps()
Get number of current outstanding register operations in the Message Store
|
java.lang.Integer |
curSubmitMessageOps()
Get number of current outstanding message submission operations in the Message Store
|
java.lang.Integer |
curSubmitProbeOps()
Get number of current outstanding probe submission operations in the Message Store
|
java.lang.Integer |
curSummarizeOps()
Get number of current outstanding summarize operations in the Message Store
|
java.lang.Integer |
curUnbindOps()
Get number of current outstanding unbind operations in the Message Store
|
void |
disconnect()
Disconnect from the Message Store (if we are connected)
|
SomPumiceConnection[] |
getConnections()
Get the set of connections which have been read from the Message Store server
|
java.util.Date |
getCurrentTime()
Get current time
|
java.lang.Integer |
getCurrentTimeOffset()
Get current Message Store time offset
|
java.lang.String |
getFriendlyName()
Get the friendly name for this Message Store
|
java.lang.String |
getHostName()
Get the host name used to connect to the Message Store
|
java.lang.String |
getInfoString()
Get a string summarizing the connection state of the server stats on message counts
|
SomPumiceMailbox[] |
getMailboxes()
Get the set of mailboxes which have been read from the Message Store server
|
java.lang.String |
getPassword()
Get the password to be used when connecting to the Message Store
|
int |
getPort()
Get the port used to connect to the Message Store
|
java.lang.String |
getSaslMechanism()
Get the name of the SASL mechanism
|
int |
getState()
Return current state of connection
|
void |
getStatus(SomCommandListener listener)
Issue a SOM command requesting the status of this object.
|
void |
getSubordinateConnections(SomCommandListener listener)
Issue a SOM command requesting the list of connections to this Store.
|
void |
getSubordinateMailboxes(SomCommandListener listener)
Issue a SOM command requesting the list of mailboxes subordinate to this Store.
|
java.lang.String |
getUsername()
Get the user name (SASL id) used when connecting to the Message Store
|
boolean |
getUseTls()
Get the value of the flag which indicates whether TLS should be used
|
void |
handleBindResponse(int status,
java.lang.String detail)
Handle the response to a Bind operation
|
void |
handleResponse(SomCommand command,
int status,
SomPumiceConnection object) |
void |
handleResponse(SomCommand command,
int status,
SomPumiceMailbox object) |
void |
handleResponse(SomCommand command,
int status,
SomPumiceMessage object) |
void |
handleResponse(SomCommand command,
int status,
java.lang.String detail)
Generic command response handler
|
void |
handleResponse(SomCommand command,
int status,
java.lang.String[] pairs) |
void |
importBackup(SomCommandListener listener,
java.lang.String source) |
boolean |
isConnectionExpected()
Check whether we are in the middle of connecting to the Store server
|
void |
logout(SomCommandListener listener,
java.lang.String mailbox)
Tell the Message Store to log out a user
|
void |
maxconns(SomCommandListener listener,
java.lang.Integer n)
Set the maximum number of connections which the Message Store will accept
|
void |
maxmsgs(SomCommandListener listener,
java.lang.Integer n) |
java.lang.Integer |
maxNumMessages()
Get configured maximum number of messages in Message Store
|
java.lang.Integer |
maxP3Associations()
Get configured maximum number of P3 associations allowed in Message Store
|
java.lang.Integer |
maxP7Associations()
Get configured maximum number of P7 associations allowed in Message Store
|
void |
maxvol(SomCommandListener listener,
java.lang.Integer v)
Set the maximum volume of messages which the Message Store will accept
|
java.lang.Integer |
maxVolMessages()
Get configured maximum volume of messages in Message Store
|
void |
monitor(SomCommandListener listener,
java.lang.Boolean enable)
Switch on or off Store monitoring.
|
java.lang.Integer |
numMailboxes()
Get number of mailboxes in Message Store
|
java.lang.Integer |
numMessages()
Get number of messages in Message Store
|
java.lang.Integer |
numMgmtAssociations()
Get current number of management associations to the Message Store
|
java.lang.Integer |
numP3Associations()
Get current number of P3 associations to/from the Message Store
|
java.lang.Integer |
numP7Associations()
Get current number of P7 associations to the Message Store
|
java.lang.Integer |
numReports()
Get number of reports in Message Store
|
java.lang.Integer |
numSubmitted()
Get number of submitted messages in Message Store
|
java.lang.Integer |
queuedDapSearchOps()
Get number of DAP search operations queued in the Message Store
|
void |
rebuild(SomCommandListener listener)
Tell the Message Store rebuild its mailbox list
|
void |
rebuildStats(SomCommandListener listener)
Tell the Message Store to rebuild its internal statistics
|
void |
reload(SomCommandListener listener)
Tell the Message Store to reload its configuration
|
void |
restart(SomCommandListener listener)
Tell the Message Store to restart
|
void |
resynchronize(SomCommandListener listener)
Tell the Message Store to resynchronize its indexes
|
static void |
setConnectionTimeout(int value)
Set the connection timeout used for all SOM sessions
created via this object
|
void |
setFriendlyName(java.lang.String f)
Set the friendly name for this Message Store
|
void |
setHostName(java.lang.String n)
Set the host name used to connect to the Message Store
|
void |
setPassword(java.lang.String n)
Set the password to use when connecting to the Message Store
|
void |
setPort(int p)
Set the port used to connect to the Message Store
|
void |
setSaslMechanism(java.lang.String mech)
Configure the name of the SASL mechanism which we want to use for authentication
|
void |
setSizeLimits(java.lang.Integer mailboxSizeLimit,
java.lang.Integer messageSizeLimit,
java.lang.Integer connectionSizeLimit)
Configure the sizelimits which we will use when requesting information
about the number of mailboxes, connections and message from the MS.
|
void |
setUsername(java.lang.String n)
Set the user name (SASL id) to be used when connecting to the Message Store
|
void |
setUseTls(boolean use)
Set the flag which indicates whether TLS should be used for this connection
|
void |
shutdown(SomCommandListener listener)
Tell the Message Store to shut down
|
java.lang.Integer |
somVersion()
Get SOM version of Message Store
|
void |
unblock(SomCommandListener listener,
java.lang.String op)
Tell the Message Store to unlock an operation
|
java.lang.Integer |
unreadHigh()
Get number of unread high priority messages in Message Store
|
java.lang.Integer |
unreadLow()
Get number of unread low priority messages in Message Store
|
java.lang.Integer |
unreadMedium()
Get number of unread medium priority messages in Message Store
|
java.lang.String |
uptime()
Get uptime as string for Message Store
|
java.lang.String |
version()
Get version string for Message Store
|
java.lang.Integer |
volMessages()
Get volume of messages in Message Store
|
java.lang.Integer |
volSubmittedMessages()
Get volume of submitted messages in Message Store
|
addAttribute, addAttribute, addBindListener, clearAttributes, getBooleanAttributeValue, getIntegerAttributeValue, getSession, getStringAttributeValue, notifyBindListeners, notifyListener, notifyListeners, notifyListeners, notifyListeners, parsePairs, print, removeBindListener, setSkipNotifications
public java.lang.Integer som_version
public static final int SOM_PUMICE_DISCONNECTED
public static final int SOM_PUMICE_CONNECTING
public static final int SOM_PUMICE_CONNECTED_ANON
public static final int SOM_PUMICE_CONNECTED_AUTH
public SomPumiceMessageStore()
public static void setConnectionTimeout(int value)
value
- the timeout valuepublic void setSizeLimits(java.lang.Integer mailboxSizeLimit, java.lang.Integer messageSizeLimit, java.lang.Integer connectionSizeLimit)
mailboxSizeLimit
- limit on the number of mailboxes on which to reportmessageSizeLimit
- limit on the number of messages on which to reportconnectionSizeLimit
- limit on the number of connections on which to reportpublic SomPumiceMailbox[] getMailboxes()
public SomPumiceConnection[] getConnections()
public boolean isConnectionExpected()
public int getState()
public void handleBindResponse(int status, java.lang.String detail)
SomHandler
handleBindResponse
in interface SomHandler
status
- operation statusdetail
- error detail on failurepublic void handleResponse(SomCommand command, int status, java.lang.String detail)
SomHandler
handleResponse
in interface SomPumiceHandler
handleResponse
in interface SomHandler
command
- the command to which the response appliesstatus
- status from commanddetail
- error detailpublic void handleResponse(SomCommand command, int status, java.lang.String[] pairs)
handleResponse
in interface SomPumiceHandler
public void handleResponse(SomCommand command, int status, SomPumiceMailbox object)
handleResponse
in interface SomPumiceHandler
public void handleResponse(SomCommand command, int status, SomPumiceConnection object)
handleResponse
in interface SomPumiceHandler
public void handleResponse(SomCommand command, int status, SomPumiceMessage object)
handleResponse
in interface SomPumiceHandler
public java.lang.String getInfoString()
public void getStatus(SomCommandListener listener) throws SomException
listener
- Object to notify once status has been updatedSomException
- on errorpublic void getSubordinateMailboxes(SomCommandListener listener) throws SomException
listener
- Object to notify once list of mailboxes has been updatedSomException
- on errorpublic void getSubordinateConnections(SomCommandListener listener) throws SomException
listener
- Object to notify once list of connections has been updatedSomException
- on errorpublic int getPort()
public void setPort(int p)
p
- the port to be usedpublic java.lang.String getHostName()
public void setHostName(java.lang.String n)
n
- the host name to usepublic java.lang.String getUsername()
public void setUsername(java.lang.String n)
n
- the user name to usepublic java.lang.String getPassword()
public void setPassword(java.lang.String n)
n
- the password to usepublic java.lang.String getFriendlyName()
public void setFriendlyName(java.lang.String f)
f
- the friendly name to usepublic void setUseTls(boolean use)
use
- true to use TLSpublic boolean getUseTls()
public void connect() throws SomException
SomException
- on errorpublic void disconnect() throws SomException
SomException
- on errorpublic void monitor(SomCommandListener listener, java.lang.Boolean enable) throws SomException
listener
- Listener object which will be updated with new dataenable
- Control whether we are turning monitoring on or offSomException
- on errorpublic void shutdown(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic void abort(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic void restart(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic void logout(SomCommandListener listener, java.lang.String mailbox) throws SomException
listener
- which will be informed when the operation is completemailbox
- The mailbox to log out, or the string "ALL"SomException
- on errorpublic void block(SomCommandListener listener, java.lang.String op) throws SomException
listener
- which will be informed when the operation is completeop
- the operation to blockSomException
- on errorpublic void importBackup(SomCommandListener listener, java.lang.String source) throws SomException
SomException
public void unblock(SomCommandListener listener, java.lang.String op) throws SomException
listener
- which will be informed when the operation is completeop
- the operation to unblockSomException
- on errorpublic void maxconns(SomCommandListener listener, java.lang.Integer n) throws SomException
listener
- which will be informed when the operation is completen
- the maximum number of connections to acceptSomException
- on errorpublic void maxvol(SomCommandListener listener, java.lang.Integer v) throws SomException
listener
- which will be informed when the operation is completev
- the maximum volumeSomException
- on errorpublic void maxmsgs(SomCommandListener listener, java.lang.Integer n) throws SomException
SomException
public void rebuild(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic void resynchronize(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic void rebuildStats(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic void reload(SomCommandListener listener) throws SomException
listener
- which will be informed when the operation is completeSomException
- on errorpublic java.lang.Integer somVersion() throws SomException
SomException
- on errorpublic java.lang.String version() throws SomException
SomException
- on errorpublic java.lang.String uptime() throws SomException
SomException
- on errorpublic java.lang.Integer numMailboxes() throws SomException
SomException
- on errorpublic java.lang.Integer numMessages() throws SomException
SomException
- on errorpublic java.lang.Integer numReports() throws SomException
SomException
- on errorpublic java.lang.Integer numSubmitted() throws SomException
SomException
- on errorpublic java.lang.Integer unreadLow() throws SomException
SomException
- on errorpublic java.lang.Integer unreadMedium() throws SomException
SomException
- on errorpublic java.lang.Integer unreadHigh() throws SomException
SomException
- on errorpublic java.lang.Integer volMessages() throws SomException
SomException
- on errorpublic java.lang.Integer volSubmittedMessages() throws SomException
SomException
- on errorpublic java.lang.Integer maxNumMessages() throws SomException
SomException
- on errorpublic java.lang.Integer maxVolMessages() throws SomException
SomException
- on errorpublic java.lang.Integer numP7Associations() throws SomException
SomException
- on errorpublic java.lang.Integer numP3Associations() throws SomException
SomException
- on errorpublic java.lang.Integer numMgmtAssociations() throws SomException
SomException
- on errorpublic java.lang.Integer maxP7Associations() throws SomException
SomException
- on errorpublic java.lang.Integer maxP3Associations() throws SomException
SomException
- on errorpublic java.lang.Integer queuedDapSearchOps() throws SomException
SomException
- on errorpublic java.lang.String blockedOperations() throws SomException
SomException
- on errorpublic java.lang.Integer curBindOps() throws SomException
SomException
- on errorpublic java.lang.Integer curCancelDeferredDeliveryOps() throws SomException
SomException
- on errorpublic java.lang.Integer curChangeCredentialsOps() throws SomException
SomException
- on errorpublic java.lang.Integer curDeleteOps() throws SomException
SomException
- on errorpublic java.lang.Integer curDeliverMessageOps() throws SomException
SomException
- on errorpublic java.lang.Integer curDeliverReportOps() throws SomException
SomException
- on errorpublic java.lang.Integer curDeliveryControlOps() throws SomException
SomException
- on errorpublic java.lang.Integer curFetchOps() throws SomException
SomException
- on errorpublic java.lang.Integer curListOps() throws SomException
SomException
- on errorpublic java.lang.Integer curRegisterMsOps() throws SomException
SomException
- on errorpublic java.lang.Integer curRegisterOps() throws SomException
SomException
- on errorpublic java.lang.Integer curSubmitMessageOps() throws SomException
SomException
- on errorpublic java.lang.Integer curSubmitProbeOps() throws SomException
SomException
- on errorpublic java.lang.Integer curSummarizeOps() throws SomException
SomException
- on errorpublic java.lang.Integer curUnbindOps() throws SomException
SomException
- on errorpublic java.lang.Integer getCurrentTimeOffset()
public java.util.Date getCurrentTime()
public void setSaslMechanism(java.lang.String mech)
mech
- mechanism name which may be nullpublic java.lang.String getSaslMechanism()
Version: 18.0v6-0
Copyright (c) 2017-2020 Isode