Package de.xima.fc.gui.bean.resource
Class ProjectResourceBean
- java.lang.Object
-
- de.xima.fc.gui.common.utils.msg.I18nUtils
-
- de.xima.fc.gui.common.utils.msg.MessageUtils
-
- de.xima.fc.gui.common.utils.msg.AMessaging
-
- de.xima.fc.gui.common.utils.msg.AJSFContext
-
- de.xima.fc.gui.bean.ABackendJSFContext
-
- de.xima.fc.gui.bean.FCContextBean
-
- de.xima.fc.gui.bean.resource.ABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
- de.xima.fc.gui.bean.resource.ProjectResourceBean
-
- All Implemented Interfaces:
Serializable
@Named @ViewScoped public class ProjectResourceBean extends ABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
ProjectResourceBean.EntityListModelImpl
-
Nested classes/interfaces inherited from class de.xima.fc.gui.common.utils.msg.AJSFContext
AJSFContext.RedirectOptions, AJSFContext.RedirectOptionsBuilder
-
-
Field Summary
-
Fields inherited from class de.xima.fc.gui.bean.resource.ABasicResourceBean
FILENAME_RESOURCES_SUFFIX, FILENAME_RESOURCES_ZIP, forceTextEdit, model, resourceContentBean, userManager
-
Fields inherited from class de.xima.fc.gui.bean.FCContextBean
systemUC
-
Fields inherited from class de.xima.fc.gui.common.utils.msg.AJSFContext
localeBean
-
-
Constructor Summary
Constructors Constructor Description ProjectResourceBean()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
checkResourceNameExist(String name)
protected boolean
checkResourceNameExist(String name, ProjektRessource item)
protected ProjektRessource
createResource(String fileName, byte[] data, String userName)
String
getGeneratedUrl(ProjektRessource res)
org.primefaces.model.StreamedContent
getMarkedResources()
GeneratesStreamedContent
from the List of all the marked resources contained within the model.protected IEntityListModel<ProjektRessource>
getNewModel()
Projekt
getProject()
protected void
openResourceConflictDialog()
void
processRefactorFormElementName()
Remote command invoked when the designer conversation event is triggered.void
setProject(IEntityViewModel<Projekt> model)
void
setProject(Long projectId)
void
updateProjectResourceList(List<String> updatesList, List<String> updatesContent)
protected ProjektRessource
updateResource(String fileName, byte[] data, String userName)
-
Methods inherited from class de.xima.fc.gui.bean.resource.ABasicResourceBean
checkResourceUploads, cleanup, getFileConflicts, getGeneratedUrl, getModel, getPreviewType, getStreamedContent, hasResourceData, isForceTextEdit, isImageResource, isPreviewResource, isReaderResource, isShowImagePreview, isShowPreview, isShowReaderPreview, isShowTextPreview, isShowTextPreviewBinary, isSourceCodeResource, isTextPreviewSizeExceeded, isTextResource, onConflictsDialogClose, preCreate, preUpdate, resolveConflicts, resolveConflicts, setForceTextEdit, setModel, updateModel, upload, uploadAndPersist
-
Methods inherited from class de.xima.fc.gui.bean.FCContextBean
getNavigationBean, getSessionBean, isSetupUser, redirectToDashboard, setNavigationBean, setSessionBean, switchMainView, switchMainView, switchSubView, switchSubView
-
Methods inherited from class de.xima.fc.gui.bean.ABackendJSFContext
ec, findEntityContext, isDetached, isHasDB
-
Methods inherited from class de.xima.fc.gui.common.utils.msg.AJSFContext
destroySessionBean, encodeURL, findBean, findBean, findBean, findBean, findBean, findBean, findBean, findCurrentView, findUserContext, getBeanName, getBeanName, getContext, getCurrentViewBean, getLocaleBean, getRequest, getResponse, getSession, getSession, getSessionAttribute, isMasterServerContext, loadLazy, redirect, redirect, redirect, redirect, redirectToDashboard, redirectToDashboard, redirectToDashboard, setLocaleBean, setSessionAttribute, uc
-
Methods inherited from class de.xima.fc.gui.common.utils.msg.MessageUtils
addErrorMsg, addErrorMsg, addErrorMsg, addErrorMsg, addErrorMsg, addErrorMsg, addErrorMsgFromString, addErrorMsgFromString, addErrorMsgToComponent, addErrorMsgToComponent, addErrorMsgToComponent, addErrorMsgToComponent, addErrorMsgToComponent, addErrorMsgToComponent, addInfoMsg, addInfoMsg, addInfoMsg, addInfoMsg, addInfoMsgFromString, addInfoMsgFromString, addInfoMsgToComponent, addInfoMsgToComponent, addInfoMsgToComponent, addInfoMsgToComponent, addMsg, addMsg, addMsg, addMsg, addMsgs, addMsgs, addMsgToComponent, addMsgToComponent, addWarnMsg, addWarnMsg, addWarnMsg, addWarnMsg, addWarnMsgFromString, addWarnMsgFromString, addWarnMsgToComponent, addWarnMsgToComponent, addWarnMsgToComponent, addWarnMsgToComponent, cleanErrorMsg, errorMsg, errorMsg, getErrorMessage, getNewErrorMsg, getNewErrorMsg, getNewErrorMsg, getNewInfoMsg, getNewInfoMsg, getNewMsg, getNewWarnMsg, getNewWarnMsg, msg
-
-
-
-
Method Detail
-
updateProjectResourceList
public void updateProjectResourceList(List<String> updatesList, List<String> updatesContent)
-
getProject
public Projekt getProject()
-
setProject
public void setProject(IEntityViewModel<Projekt> model)
-
setProject
public void setProject(Long projectId)
-
getMarkedResources
public org.primefaces.model.StreamedContent getMarkedResources()
Description copied from class:ABasicResourceBean
GeneratesStreamedContent
from the List of all the marked resources contained within the model. If this list contains only a single entry theStreamedContent
for this resource will be returned. If the list contains more than one entry the resources will be packed into a zip file and the generatedStreamedContent
of the zip file will be returned.- Overrides:
getMarkedResources
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
- Returns:
- the
StreamedContent
of all the marked model resources
-
getNewModel
protected IEntityListModel<ProjektRessource> getNewModel()
- Specified by:
getNewModel
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
createResource
protected ProjektRessource createResource(String fileName, byte[] data, String userName)
- Specified by:
createResource
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
updateResource
protected ProjektRessource updateResource(String fileName, byte[] data, String userName)
- Specified by:
updateResource
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
checkResourceNameExist
protected boolean checkResourceNameExist(String name)
- Specified by:
checkResourceNameExist
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
checkResourceNameExist
protected boolean checkResourceNameExist(String name, ProjektRessource item)
- Specified by:
checkResourceNameExist
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
processRefactorFormElementName
public void processRefactorFormElementName()
Remote command invoked when the designer conversation event is triggered.
-
getGeneratedUrl
public String getGeneratedUrl(ProjektRessource res)
- Specified by:
getGeneratedUrl
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
openResourceConflictDialog
protected void openResourceConflictDialog()
- Specified by:
openResourceConflictDialog
in classABasicResourceBean<ProjektRessourceDateiData,ProjektRessource>
-
-