public class NoteModificationResult extends Object
Constructor and Description |
---|
NoteModificationResult()
Creates an empty result object
|
NoteModificationResult(NoteModificationStatus status,
Collection<String> unresolvableBlogs,
Collection<String> unwritableBlogs,
Long noteId,
Long version,
boolean direct,
UserNotificationResult userNotificationResult)
Creates an result object.
|
Modifier and Type | Method and Description |
---|---|
Throwable |
getErrorCause() |
String |
getMessageKey() |
Long |
getNoteId() |
NoteModificationStatus |
getStatus() |
Collection<String> |
getTagsWithProblems() |
Collection<String> |
getUnresolvableBlogs() |
Collection<String> |
getUnwritableBlogs() |
UserNotificationResult |
getUserNotificationResult() |
Long |
getVersion() |
boolean |
isDirect() |
void |
setDirect(boolean direct)
Set whether the created note is a direct message.
|
void |
setErrorCause(Throwable cause) |
void |
setMessageKey(String messageKey) |
void |
setNoteId(Long noteId) |
void |
setStatus(NoteModificationStatus status) |
void |
setTagsWithProblems(Collection<String> tagsWithProblems) |
void |
setUnresolvableBlogs(Collection<String> unresolvableBlogs) |
void |
setUnwritableBlogs(Collection<String> unwritableBlogs) |
void |
setUserNotificationResult(UserNotificationResult userNotificationResult)
Sets the userNotificationResult
|
void |
setVersion(Long version) |
public NoteModificationResult()
public NoteModificationResult(NoteModificationStatus status, Collection<String> unresolvableBlogs, Collection<String> unwritableBlogs, Long noteId, Long version, boolean direct, UserNotificationResult userNotificationResult)
status
- the status of the creation / modificationunresolvableBlogs
- collection of blog aliases that could not be resolved to existing blogsunwritableBlogs
- collection of cross post target blog aliases the user has no write access to.noteId
- ID of the created noteversion
- the version of the notedirect
- true if the note is a direct messageuserNotificationResult
- the notification resultpublic Throwable getErrorCause()
NoteModificationStatus.SYSTEM_ERROR
public String getMessageKey()
public Long getNoteId()
public NoteModificationStatus getStatus()
NoteModificationStatus.SYSTEM_ERROR
getErrorCause()
might lead to
more details.public Collection<String> getTagsWithProblems()
public Collection<String> getUnresolvableBlogs()
public Collection<String> getUnwritableBlogs()
public UserNotificationResult getUserNotificationResult()
public Long getVersion()
public boolean isDirect()
public void setDirect(boolean direct)
direct
- true if the note is a direct messagepublic void setErrorCause(Throwable cause)
cause
- set the cause of an internal error. This should be set if status is
NoteModificationStatus.SYSTEM_ERROR
public void setMessageKey(String messageKey)
messageKey
- A message key, which could be used to display a message for this result.public void setNoteId(Long noteId)
noteId
- ID of the created notepublic void setStatus(NoteModificationStatus status)
status
- the status of the note creation / modificationpublic void setTagsWithProblems(Collection<String> tagsWithProblems)
tagsWithProblems
- the tagsWithProblems to setpublic void setUnresolvableBlogs(Collection<String> unresolvableBlogs)
unresolvableBlogs
- collection of blog aliases that could not be resolved to existing blogspublic void setUnwritableBlogs(Collection<String> unwritableBlogs)
unwritableBlogs
- collection of cross post target blog aliases the user has no write access topublic void setUserNotificationResult(UserNotificationResult userNotificationResult)
userNotificationResult
- the notification resultpublic void setVersion(Long version)
version
- the version of the created noteCopyright © 2019 Communote team. All rights reserved.