public class CaseImpl extends Object implements Case
Constructor and Description |
---|
CaseImpl(DocumentModel envelope,
HasParticipants recipientsAdapter) |
Modifier and Type | Method and Description |
---|---|
boolean |
addCaseItem(CaseItem item,
CoreSession session)
Adds given item to the envelope.
|
void |
addInitialExternalParticipants(Map<String,List<String>> recipients)
Adds to the list of initial external recipients.
|
void |
addInitialInternalParticipants(Map<String,List<String>> recipients)
Adds to the list of initial internal recipients.
|
void |
addParticipants(Map<String,List<String>> recipients)
Adds to the list of recipients.
|
boolean |
canFollowTransition(String transition) |
void |
followTransition(String transition)
Follow the given transition.
|
Map<String,List<String>> |
getAllParticipants()
Gets the list of all recipients keyed by type.
|
List<CaseItem> |
getCaseItems(CoreSession session)
Returns unmodifiable list of items.
|
DocumentModel |
getDocument()
Gets the document model describing the envelope.
|
List<DocumentModel> |
getDocuments()
Gets the items as document with the session of the envelope.
|
List<DocumentModel> |
getDocuments(CoreSession session)
Gets the items as document
|
CaseItem |
getFirstItem(CoreSession session)
Gets the first document within this envelope
|
Map<String,List<String>> |
getInitialExternalParticipants()
Gets the list of initial external recipients keyed by type.
|
Map<String,List<String>> |
getInitialInternalParticipants()
Gets the list of initial internal recipients keyed by type.
|
boolean |
isDraft()
Is this a draft envelope?
|
boolean |
isEmpty()
Is this an empty envelope?
|
boolean |
moveDownEmailsInCase(List<CaseItem> selected,
CoreSession session)
Moves down given selected items in the envelope.
|
boolean |
moveUpEmailsInCase(List<CaseItem> selected,
CoreSession session)
Moves up given selected items in the envelope.
|
boolean |
removeCaseItem(CaseItem item,
CoreSession session)
Removes given item from the envelope.
|
void |
save(CoreSession session)
Persists the envelope.
|
public CaseImpl(DocumentModel envelope, HasParticipants recipientsAdapter)
public DocumentModel getDocument()
Case
getDocument
in interface Case
public List<CaseItem> getCaseItems(CoreSession session)
Case
getCaseItems
in interface Case
public CaseItem getFirstItem(CoreSession session)
Case
getFirstItem
in interface Case
public boolean addCaseItem(CaseItem item, CoreSession session)
Case
addCaseItem
in interface Case
public boolean removeCaseItem(CaseItem item, CoreSession session)
Case
removeCaseItem
in interface Case
public boolean moveUpEmailsInCase(List<CaseItem> selected, CoreSession session)
Case
moveUpEmailsInCase
in interface Case
public boolean moveDownEmailsInCase(List<CaseItem> selected, CoreSession session)
Case
moveDownEmailsInCase
in interface Case
public void save(CoreSession session)
Case
public List<DocumentModel> getDocuments()
Case
getDocuments
in interface Case
public List<DocumentModel> getDocuments(CoreSession session)
Case
getDocuments
in interface Case
public boolean isDraft() throws ClientException
Case
isDraft
in interface Case
ClientException
public boolean isEmpty() throws ClientException
Case
isEmpty
in interface Case
ClientException
public void addInitialExternalParticipants(Map<String,List<String>> recipients)
HasParticipants
addInitialExternalParticipants
in interface HasParticipants
recipients
- A map keyed with the message type and valued with a
list of Mailbox
public void addInitialInternalParticipants(Map<String,List<String>> recipients)
HasParticipants
addInitialInternalParticipants
in interface HasParticipants
recipients
- A map keyed with the message type and valued with a
list of Mailbox
public void addParticipants(Map<String,List<String>> recipients)
HasParticipants
addParticipants
in interface HasParticipants
recipients
- A map keyed with the message type and valued with a
list of Mailbox
public Map<String,List<String>> getAllParticipants()
HasParticipants
getAllParticipants
in interface HasParticipants
public Map<String,List<String>> getInitialExternalParticipants()
HasParticipants
getInitialExternalParticipants
in interface HasParticipants
public Map<String,List<String>> getInitialInternalParticipants()
HasParticipants
getInitialInternalParticipants
in interface HasParticipants
public boolean canFollowTransition(String transition)
canFollowTransition
in interface Case
public void followTransition(String transition)
Case
followTransition
in interface Case
Copyright © 2013 Nuxeo SA. All Rights Reserved.