org.alfresco.web.bean.ml
Class AddTranslationDialog

java.lang.Object
  extended by org.alfresco.web.bean.dialog.BaseDialogBean
      extended by org.alfresco.web.bean.wizard.BaseWizardBean
          extended by org.alfresco.web.bean.content.BaseContentWizard
              extended by org.alfresco.web.bean.content.AddContentDialog
                  extended by org.alfresco.web.bean.ml.AddTranslationDialog
All Implemented Interfaces:
java.io.Serializable, IDialogBean, IWizardBean

public class AddTranslationDialog
extends AddContentDialog

Dialog bean to upload a new document and to add it to an existing MLContainer.

See Also:
Serialized Form

Field Summary
protected  org.alfresco.service.cmr.repository.NodeRef mlTranslation
           
 
Fields inherited from class org.alfresco.web.bean.content.AddContentDialog
file, inlineEditableMimeTypes
 
Fields inherited from class org.alfresco.web.bean.content.BaseContentWizard
author, createdNode, description, encoding, fileName, inlineEdit, logger, mimeType, MSG_NODE_LOCKED, objectType, objectTypes, otherPropertiesChoiceVisible, showOtherProperties, title
 
Fields inherited from class org.alfresco.web.bean.dialog.BaseDialogBean
browseBean, isFinished, navigator, parameters
 
Constructor Summary
AddTranslationDialog()
           
 
Method Summary
 java.lang.String cancel()
          Action handler called when the dialog is cancelled
protected  java.lang.String finishImpl(javax.faces.context.FacesContext context, java.lang.String outcome)
          Performs the actual processing for the wizard.
 boolean getFinishButtonDisabled()
          Determines whether the finish button on the dialog should be disabled
 java.lang.String getFinishButtonLabel()
          Returns the label to use for the finish button
 java.lang.String getLanguage()
           
 org.alfresco.service.cmr.ml.MultilingualContentService getMultilingualContentService()
           
 javax.faces.model.SelectItem[] getUnusedLanguages()
          Method calls by the dialog to limit the list of languages.
 UserPreferencesBean getUserPreferencesBean()
           
 void init(java.util.Map parameters)
          Initialises the dialog bean
 void setLanguage(java.lang.String language)
           
 void setMultilingualContentService(org.alfresco.service.cmr.ml.MultilingualContentService multilingualContentService)
           
 void setUnusedLanguages(javax.faces.model.SelectItem[] unusedLanguages)
           
 void setUserPreferencesBean(UserPreferencesBean userPreferencesBean)
           
 
Methods inherited from class org.alfresco.web.bean.content.AddContentDialog
clearUpload, doPostCommitProcessing, formatErrorMessage, getDefaultFinishOutcome, getFileName, getFileUploadSuccessMsg, getInlineEditableMimeTypes, removeUploadedFile, setFileName, start
 
Methods inherited from class org.alfresco.web.bean.content.BaseContentWizard
getAuthor, getContentService, getDescription, getEncoding, getEncodings, getMimeType, getObjectType, getObjectTypes, getOtherPropertiesChoiceVisible, getShowOtherProperties, getSummaryMimeType, getSummaryObjectType, getTitle, initOtherProperties, isInlineEdit, saveContent, setAuthor, setContentService, setDescription, setEncoding, setInlineEdit, setMimeType, setObjectType, setShowOtherProperties, setTitle
 
Methods inherited from class org.alfresco.web.bean.wizard.BaseWizardBean
back, buildSummary, getBackButtonLabel, getDefaultCancelOutcome, getNextButtonDisabled, getNextButtonLabel, getStepDescription, getStepTitle, next
 
Methods inherited from class org.alfresco.web.bean.dialog.BaseDialogBean
finish, getActionsConfigId, getActionsContext, getAdditionalButtons, getCancelButtonLabel, getCheckOutCheckInService, getContainerDescription, getContainerSubTitle, getContainerTitle, getDictionaryService, getErrorMessageId, getErrorOutcome, getFileFolderService, getMoreActionsConfigId, getNamespaceService, getNodeService, getRuleService, getSearchService, getTransactionService, isFinished, restored, setBrowseBean, setDictionaryService, setFileFolderService, setNamespaceService, setNavigator, setNodeService, setSearchService
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.alfresco.web.bean.dialog.IDialogBean
finish, getActionsConfigId, getActionsContext, getAdditionalButtons, getCancelButtonLabel, getContainerDescription, getContainerSubTitle, getContainerTitle, getMoreActionsConfigId, isFinished, restored
 

Field Detail

mlTranslation

protected org.alfresco.service.cmr.repository.NodeRef mlTranslation
Constructor Detail

AddTranslationDialog

public AddTranslationDialog()
Method Detail

init

public void init(java.util.Map parameters)
Description copied from interface: IDialogBean
Initialises the dialog bean

Specified by:
init in interface IDialogBean
Overrides:
init in class AddContentDialog
Parameters:
parameters - Map of parameters for the dialog

finishImpl

protected java.lang.String finishImpl(javax.faces.context.FacesContext context,
                                      java.lang.String outcome)
                               throws java.lang.Exception
Description copied from class: BaseDialogBean
Performs the actual processing for the wizard. NOTE: This method is called within the context of a transaction so no transaction handling is required

Overrides:
finishImpl in class AddContentDialog
Parameters:
context - FacesContext
outcome - The default outcome
Returns:
The outcome
Throws:
java.lang.Exception

cancel

public java.lang.String cancel()
Description copied from class: AddContentDialog
Action handler called when the dialog is cancelled

Specified by:
cancel in interface IDialogBean
Overrides:
cancel in class AddContentDialog
Returns:
The outcome to return

getFinishButtonDisabled

public boolean getFinishButtonDisabled()
Description copied from interface: IDialogBean
Determines whether the finish button on the dialog should be disabled

Specified by:
getFinishButtonDisabled in interface IDialogBean
Overrides:
getFinishButtonDisabled in class BaseContentWizard
Returns:
true if the button should be disabled

getLanguage

public java.lang.String getLanguage()
Returns:
the locale of this new translation

setLanguage

public void setLanguage(java.lang.String language)
Parameters:
language - the locale of this new translation

setUnusedLanguages

public void setUnusedLanguages(javax.faces.model.SelectItem[] unusedLanguages)
Parameters:
unusedLanguages -

getUnusedLanguages

public javax.faces.model.SelectItem[] getUnusedLanguages()
Method calls by the dialog to limit the list of languages.

Returns:
the list of availables translation in the MLContainer

getMultilingualContentService

public org.alfresco.service.cmr.ml.MultilingualContentService getMultilingualContentService()

setMultilingualContentService

public void setMultilingualContentService(org.alfresco.service.cmr.ml.MultilingualContentService multilingualContentService)

getUserPreferencesBean

public UserPreferencesBean getUserPreferencesBean()

setUserPreferencesBean

public void setUserPreferencesBean(UserPreferencesBean userPreferencesBean)

getFinishButtonLabel

public java.lang.String getFinishButtonLabel()
Description copied from interface: IDialogBean
Returns the label to use for the finish button

Specified by:
getFinishButtonLabel in interface IDialogBean
Overrides:
getFinishButtonLabel in class AddContentDialog
Returns:
The finish button label


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.