Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.platform.relations.web.listener.ejb
Class RelationActionsBean

java.lang.Object
  extended by org.nuxeo.ecm.platform.ui.web.invalidations.DocumentContextBoundActionBean
      extended by org.nuxeo.ecm.platform.relations.web.listener.ejb.RelationActionsBean
All Implemented Interfaces:
java.io.Serializable, RelationActions, StatefulBaseLifeCycle

@Name(value="relationActions")
@Scope(value=CONVERSATION)
public class RelationActionsBean
extends DocumentContextBoundActionBean
implements RelationActions, java.io.Serializable

Seam component that manages statements involving current document as well as creation, edition and deletion of statements involving current document.

Current document is the subject of the relation. The predicate is resolved thanks to a list of predicates URIs. The object is resolved using a type (literal, resource, qname resource), an optional namespace (for qname resources) and a value.

Author:
Anahide Tchertchian
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.nuxeo.ecm.platform.relations.web.listener.RelationActions
SEARCH_DOCUMENT_LIST
 
Constructor Summary
RelationActionsBean()
           
 
Method Summary
 java.lang.String addStatement()
           
 java.lang.String deleteStatement(StatementInfo stmtInfo)
           
 void destroy()
           
 java.lang.String getComment()
           
 DocumentModel getDocumentModel(Node node)
           
 QNameResource getDocumentResource(DocumentModel document)
           
 boolean getHasSearchResults()
           
 java.util.List<StatementInfo> getIncomingStatementsInfo()
           
 java.lang.String getObjectDocumentTitle()
           
 java.lang.String getObjectDocumentUid()
           
 java.lang.String getObjectLiteralValue()
           
 java.lang.String getObjectType()
           
 java.lang.String getObjectUri()
           
 java.util.List<StatementInfo> getOutgoingStatementsInfo()
           
 java.lang.String getPredicateUri()
           
 java.util.List<DocumentModel> getSearchDocumentResults()
           
 java.lang.String getSearchKeywords()
           
 java.lang.Boolean getShowCreateForm()
           
 void initialize()
           
 void readState()
          Activate method.
 void resetStatements()
           
 void saveState()
          Passivate method.
 java.lang.String searchDocuments()
           
 void setComment(java.lang.String comment)
           
 void setObjectDocumentTitle(java.lang.String objectDocumentTitle)
           
 void setObjectDocumentUid(java.lang.String objectDocumentUid)
           
 void setObjectLiteralValue(java.lang.String objectLiteralValue)
           
 void setObjectType(java.lang.String objectType)
           
 void setObjectUri(java.lang.String objectUri)
           
 void setPredicateUri(java.lang.String predicateUri)
           
 void setSearchKeywords(java.lang.String searchKeywords)
           
 void toggleCreateForm(javax.faces.event.ActionEvent event)
           
 
Methods inherited from class org.nuxeo.ecm.platform.ui.web.invalidations.DocumentContextBoundActionBean
onContextChange
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RelationActionsBean

public RelationActionsBean()
Method Detail

getDocumentModel

public DocumentModel getDocumentModel(Node node)
                               throws ClientException
Specified by:
getDocumentModel in interface RelationActions
Throws:
ClientException

getDocumentResource

public QNameResource getDocumentResource(DocumentModel document)
                                  throws ClientException
Specified by:
getDocumentResource in interface RelationActions
Throws:
ClientException

getIncomingStatementsInfo

@Factory(value="currentDocumentIncomingRelations",
         scope=EVENT)
public java.util.List<StatementInfo> getIncomingStatementsInfo()
                                                        throws ClientException
Specified by:
getIncomingStatementsInfo in interface RelationActions
Throws:
ClientException

getOutgoingStatementsInfo

@Factory(value="currentDocumentOutgoingRelations",
         scope=EVENT)
public java.util.List<StatementInfo> getOutgoingStatementsInfo()
                                                        throws ClientException
Specified by:
getOutgoingStatementsInfo in interface RelationActions
Throws:
ClientException

resetStatements

public void resetStatements()
Specified by:
resetStatements in interface RelationActions

getComment

public java.lang.String getComment()
Specified by:
getComment in interface RelationActions

setComment

public void setComment(java.lang.String comment)
Specified by:
setComment in interface RelationActions

getObjectDocumentTitle

public java.lang.String getObjectDocumentTitle()
Specified by:
getObjectDocumentTitle in interface RelationActions

setObjectDocumentTitle

public void setObjectDocumentTitle(java.lang.String objectDocumentTitle)
Specified by:
setObjectDocumentTitle in interface RelationActions

getObjectDocumentUid

public java.lang.String getObjectDocumentUid()
Specified by:
getObjectDocumentUid in interface RelationActions

setObjectDocumentUid

public void setObjectDocumentUid(java.lang.String objectDocumentUid)
Specified by:
setObjectDocumentUid in interface RelationActions

getObjectLiteralValue

public java.lang.String getObjectLiteralValue()
Specified by:
getObjectLiteralValue in interface RelationActions

setObjectLiteralValue

public void setObjectLiteralValue(java.lang.String objectLiteralValue)
Specified by:
setObjectLiteralValue in interface RelationActions

getObjectType

public java.lang.String getObjectType()
Specified by:
getObjectType in interface RelationActions

setObjectType

public void setObjectType(java.lang.String objectType)
Specified by:
setObjectType in interface RelationActions

getObjectUri

public java.lang.String getObjectUri()
Specified by:
getObjectUri in interface RelationActions

setObjectUri

public void setObjectUri(java.lang.String objectUri)
Specified by:
setObjectUri in interface RelationActions

getPredicateUri

public java.lang.String getPredicateUri()
Specified by:
getPredicateUri in interface RelationActions

setPredicateUri

public void setPredicateUri(java.lang.String predicateUri)
Specified by:
setPredicateUri in interface RelationActions

addStatement

public java.lang.String addStatement()
                              throws ClientException
Specified by:
addStatement in interface RelationActions
Throws:
ClientException

toggleCreateForm

public void toggleCreateForm(javax.faces.event.ActionEvent event)
Specified by:
toggleCreateForm in interface RelationActions

deleteStatement

public java.lang.String deleteStatement(StatementInfo stmtInfo)
                                 throws ClientException
Specified by:
deleteStatement in interface RelationActions
Throws:
ClientException

getSearchKeywords

public java.lang.String getSearchKeywords()
Specified by:
getSearchKeywords in interface RelationActions

setSearchKeywords

public void setSearchKeywords(java.lang.String searchKeywords)
Specified by:
setSearchKeywords in interface RelationActions

searchDocuments

public java.lang.String searchDocuments()
                                 throws ClientException
Specified by:
searchDocuments in interface RelationActions
Throws:
ClientException

getSearchDocumentResults

public java.util.List<DocumentModel> getSearchDocumentResults()
Specified by:
getSearchDocumentResults in interface RelationActions

getHasSearchResults

public boolean getHasSearchResults()
Specified by:
getHasSearchResults in interface RelationActions

getShowCreateForm

public java.lang.Boolean getShowCreateForm()
Specified by:
getShowCreateForm in interface RelationActions

initialize

public void initialize()
Specified by:
initialize in interface RelationActions

destroy

@Destroy
public void destroy()
Specified by:
destroy in interface RelationActions

saveState

public void saveState()
Description copied from interface: StatefulBaseLifeCycle
Passivate method.

Specified by:
saveState in interface StatefulBaseLifeCycle

readState

public void readState()
Description copied from interface: StatefulBaseLifeCycle
Activate method.

Specified by:
readState in interface StatefulBaseLifeCycle

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.