|
Oracle Discussions Java API Reference 10g Release 1 (10.1.2) B25496-01 |
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
oracle.discussions.sdk.TdMessage
TdMessage is a light-weight object representing a Message in a Board.
On the contrary of its super classes OracleMessage it can be loaded with few pre-fetched headers without havgin the whole message and message body parsed.
The value of those pre-fetched fields is supplied through the loadFetchedFields method.
If these fields have been loaded then the corresponding accessors will returned the pre-fetched value, otherwise the super class implementation will be called and therefore the whole message will be loaded.
If any modification is made to the message through a setter, then the whole message will be parse the super class getters will be used from that moment on.
Oracle discussions elements names have been changed in the webui compared to that of sdk portion. The existing names to the new names mapping is as shown.
TdThread
Field Summary | |
protected oracle.discussions.sdk.impl.data.event.TdEventFactory |
_evtfac |
protected oracle.discussions.sdk.impl.event.publisher.EventPublisher |
_evtpub |
protected javax.mail.Flags |
_flags |
protected static java.util.Hashtable |
_htRb |
protected oracle.discussions.util.log.LoggerIf |
_logger |
protected oracle.discussions.sdk.impl.data.TdMessageInfo |
_msgInfo |
protected TdBoard |
_tdb |
protected oracle.discussions.sdk.impl.data.TdBodyInfo |
_tdBodyInfo |
protected TdBoardSettings |
_tdbs |
protected TdRole |
_tdr |
protected oracle.discussions.sdk.impl.TdSession |
_tdsession |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsDelete |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsGetBodyPlainText |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsGetBodyRichText |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsGetContent |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsGetNumberOfReplies |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsGetParent |
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent |
s_dmsUndelete |
protected static oracle.dms.instrument.Noun |
s_nMessage |
Method Summary | |
TdThread |
clip() Moves a message and all its replies and create a new thread. |
void |
delete() Deletes the current message and all its replies. |
void |
erase() Erases the current message. |
java.util.List |
getAnnotations() Returns all annotations of a message,in descending order of the time. |
java.util.Iterator |
getAttachmentBodyParts() Returns an Iterator of attachment body Parts. |
javax.mail.Part |
getAttachmentById(java.lang.String id) Returns a Part based on the attachment id |
java.util.List |
getAttachments() Returns a List of TdAttachment objects that are contained in this message. |
TdBoard |
getBoard() Returns the board this message belong to. |
TdBoardSettings |
getBoardSettings() Returns the settings of the current board lazily loading it if necessary. |
java.lang.String |
getBodyPlainText() Returns the String plain text format of the body. |
java.lang.Object |
getBodyRichText() Returns a part or a multipart for the message containing the rich text representation of this message. |
java.lang.Object |
getContent() Gets the body content of the current message. |
javax.mail.Flags |
getFlags() Returns flags of the current message. |
javax.mail.Address[] |
getFrom() Returns the From address of the message sender. |
TdAnnotation |
getLastAnnotation() Returns the lastest annotation on the message. |
int |
getLevel() Returns the level of this message thread tree |
int |
getNumberOfReplies() Returns the number of replies for this message. |
int |
getOracleMessageId() Returns the oracle specific message id corresponding to this message |
long |
getOracleMessageUid() Returns the oracle specific message uid corresponding to this message |
int |
getOracleThreadId() Returns the oracle specific thread id corresponding to this message |
TdMessage |
getParent() Returns the parent message of this message in the thread tree. |
int |
getParentMessageId() Returns the message id of the parent message of the current message. |
TdMessagePermissions |
getPermissions() Returns the permissions on this message for the currently connected user. |
protected java.util.ResourceBundle |
getResourceBundle(java.util.Locale loc) Returns the name of the ResourceBundle to be used by the toString(loc). |
protected java.lang.String |
getResourceBundleName() Returns the name of the ResourceBundle to be used by the toString(loc). |
java.lang.String |
getRfc822MessageId() Returns the value of the Message-ID header. |
java.lang.String |
getRfc822References() Returns the value of the References header. |
protected TdRole |
getRole() Returns the role of the currently connected user in this board lazily loading it if necessary. |
java.util.Date |
getSentDate() Returns the date on which the message is sent. |
int |
getSize() Returns the size of the message in bytes. |
java.lang.String |
getSubject() Returns the subject of the message. |
TdThread |
getThread() Returns the thread this message belong to. |
java.lang.String |
getXPriority() Returns the priority of the current message in the message tree. |
boolean |
hasAttachments() Returns true if the messsage has attachments |
protected void |
invalidateCache() Invalidates the cache. |
boolean |
isByModerator() Returns a boolean value indicating if the message is posted by moderator. |
boolean |
isDeleted() Returns if the current message is deleted. |
boolean |
isNew() This is the result of "OR" on isNewSinceSessions and isNewSinceLastVisit. |
boolean |
isNewSinceLastVisit() Returns a boolean value indicating if the message is new since user's last visit |
boolean |
isNewSinceSession() Returns a boolean value indicating if the message is new since user session startup. |
protected void |
refreshRole() Refreshes the users role. |
void |
setFlag(javax.mail.Flags.Flag flag, boolean set) Sets a flag of the message to the value passed. |
void |
setFlags(javax.mail.Flags flag, boolean set) Sets the message flags to the flags object passed as a parameter. |
protected void |
setParent(TdMessage parentMsg) Sets the parent message to the current message. |
java.lang.String |
toString() Converts the message into its corresponding string representation. |
java.lang.String |
toString(java.util.Locale loc) Converts the message into a locale specific string |
void |
undelete() Undeletes the current message. |
protected void |
updateUserFlags(javax.mail.Flags flags) Sets the message user's flags marking new message since last visit/session. |
Field Detail |
protected static oracle.dms.instrument.Noun s_nMessage
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsDelete
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsUndelete
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsGetContent
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsGetBodyRichText
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsGetBodyPlainText
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsGetNumberOfReplies
protected static oracle.discussions.sdk.impl.data.dms.TdPhaseEvent s_dmsGetParent
protected static java.util.Hashtable _htRb
protected javax.mail.Flags _flags
protected TdBoard _tdb
protected oracle.discussions.sdk.impl.data.TdMessageInfo _msgInfo
protected oracle.discussions.sdk.impl.TdSession _tdsession
protected oracle.discussions.sdk.impl.event.publisher.EventPublisher _evtpub
protected oracle.discussions.sdk.impl.data.event.TdEventFactory _evtfac
protected oracle.discussions.util.log.LoggerIf _logger
protected oracle.discussions.sdk.impl.data.TdBodyInfo _tdBodyInfo
protected TdBoardSettings _tdbs
protected TdRole _tdr
Method Detail |
public java.lang.String getRfc822MessageId() throws javax.mail.MessagingException
public java.lang.String getRfc822References() throws javax.mail.MessagingException
public javax.mail.Address[] getFrom() throws javax.mail.MessagingException
public java.lang.String getSubject() throws javax.mail.MessagingException
public java.util.Date getSentDate() throws javax.mail.MessagingException
public int getSize() throws javax.mail.MessagingException
public boolean hasAttachments() throws TdException, javax.mail.MessagingException
public javax.mail.Flags getFlags() throws javax.mail.MessagingException
public TdMessage getParent() throws javax.mail.MessagingException, TdException
public java.lang.Object getContent() throws javax.mail.MessagingException, java.io.IOException
public java.lang.String getXPriority() throws javax.mail.MessagingException
public int getLevel()
public int getOracleThreadId()
public int getOracleMessageId()
public long getOracleMessageUid()
public int getParentMessageId()
public java.lang.Object getBodyRichText() throws TdException, javax.mail.MessagingException
public java.lang.String getBodyPlainText() throws TdException, javax.mail.MessagingException
public javax.mail.Part getAttachmentById(java.lang.String id) throws TdException, javax.mail.MessagingException
id
- the attachment idpublic java.util.Iterator getAttachmentBodyParts() throws TdException, javax.mail.MessagingException
public java.util.List getAttachments() throws TdException, javax.mail.MessagingException
public void setFlag(javax.mail.Flags.Flag flag, boolean set) throws javax.mail.MessagingException
flag
- the flag value which is to be setset
- boolean value indicating if the flag is to be setpublic void setFlags(javax.mail.Flags flag, boolean set) throws javax.mail.MessagingException
flag
- the flags to which the message flags are to be set.set
- boolean variable indicating if the flags are to be set.public void delete() throws TdException
Message deletion depends on the deletion policy defined when the board is created.
public void undelete() throws TdException
Deletion depends of the deletion policy defined when creating the board.
public boolean isDeleted() throws javax.mail.MessagingException
Deletion depends of the deletion policy defined when creating the board.
public void erase() throws javax.mail.MessagingException, TdException
public TdBoard getBoard()
public TdThread getThread() throws TdException, javax.mail.MessagingException
public TdMessagePermissions getPermissions() throws TdException
public int getNumberOfReplies() throws TdException, javax.mail.MessagingException
protected void updateUserFlags(javax.mail.Flags flags) throws TdException, javax.mail.MessagingException
flags
- the flags that are being set.public boolean isNewSinceSession() throws javax.mail.MessagingException
public boolean isNewSinceLastVisit() throws javax.mail.MessagingException
public boolean isNew() throws javax.mail.MessagingException
public boolean isByModerator() throws javax.mail.MessagingException
public TdThread clip() throws TdException, javax.mail.MessagingException
Clipping a message involves moving the message and all its replies into a new thread.
protected void setParent(TdMessage parentMsg)
parentMsg
- the parent message for the current message.protected void invalidateCache() throws TdException, javax.mail.MessagingException
Cache invalidation involves removing the old entries from the cache.
protected TdRole getRole() throws TdException
protected void refreshRole() throws TdException
public TdBoardSettings getBoardSettings() throws TdException
public java.lang.String toString()
public java.lang.String toString(java.util.Locale loc)
loc
- locale on which the conversion is madeprotected java.lang.String getResourceBundleName()
protected final java.util.ResourceBundle getResourceBundle(java.util.Locale loc) throws java.util.MissingResourceException
loc
- the locale on which the resource bundle is to be retrievedpublic java.util.List getAnnotations() throws javax.mail.MessagingException
public TdAnnotation getLastAnnotation() throws javax.mail.MessagingException
|
Oracle Discussions Java API Reference 10g Release 1 (10.1.2) B25496-01 |
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |