class: EasySubmission

public class: EasySubmission
Author: : Tobias Schraut, created 04.04.2008
Project: Phase: 1.0; Status: Proposed; Version: : $Revision: 2773 $ $LastChangedDate: 2009-07-01 1; Complexity: 1
Dates: Created: 16.07.2009 15:32:14; Modified: 16.07.2009 15:32:14;
Flags: Active: false; IsRoot: false; IsLeaf: false;
Extension Points:
UUID: {175CAB57-4CAF-4b17-A53C-8A0D6F145BA6}
Fragment class for the easy submission. This class provides all functionality for editing, saving and submitting a PubItem within the easy submission process.
 

Goto: Custom Properties, Fields, Methods

Extends: FacesBean

See also: CreatorCollection, TitleCollection, IdentifierCollection, FacesBean, LocatorUploadBean

Appears in: easySubmission

Connections
 
Custom Properties
 
EasySubmission Attributes
Attribute Details
private boolean
  autosuggestJournals
Initial: false
public static const String
  BEAN_NAME
Initial: "EasySubmission"
private String
  contextName
Initial: null
Notes: pub context name.
private CreatorCollection
  creatorCollection
private UIXIterator
  creatorIterator
Initial: new UIXIterator()
private String
  creatorParseString
private DataSourceHandlerBean
  dataSourceHandler
Initial: new DataSourceHandlerBean()
Notes: Import Service
private Vector
  dataSources
Initial: new Vector()
Notes: Import
public SelectItem
  DATE_ACCEPTED
Initial: new SelectItem("DATE_ACCEPTED", getLabel("easy_submission_lblDateAccepted"))
public SelectItem
  DATE_CREATED
Initial: new SelectItem("DATE_CREATED", getLabel("easy_submission_lblDateCreated"))
Notes: constants for Date types
public SelectItem
  DATE_MODIFIED
Initial: new SelectItem("DATE_MODIFIED", getLabel("easy_submission_lblDateModified"))
public SelectItem
  DATE_PUBLISHED_IN_PRINT
Initial: new SelectItem("DATE_PUBLISHED_IN_PRINT", getLabel("easy_submission_lblDatePublishedInPrint"))
public SelectItem
  DATE_PUBLISHED_ONLINE
Initial: new SelectItem("DATE_PUBLISHED_ONLINE", getLabel("easy_submission_lblDatePublishedOnline"))
public SelectItem
  DATE_SUBMITTED
Initial: new SelectItem("DATE_SUBMITTED", getLabel("easy_submission_lblDateSubmitted"))
public SelectItem
  DATE_TYPE_OPTIONS
Initial: new SelectItem[]{this.DATE_CREATED, this.DATE_SUBMITTED, this.DATE_ACCEPTED, this.DATE_PUBLISHED_IN_PRINT, this.DATE_PUBLISHED_ONLINE, this.DATE_MODIFIED}
private HtmlSelectOneMenu
  dateSelect
private TitleCollection
  eventTitleCollection
public SelectItem
  EXTERNAL_SERVICE_OPTIONS
private UIXIterator
  fileIterator
Initial: new UIXIterator()
private boolean
  fromEasySubmission
Initial: false
private const String
  FULLTEXT_ALL
Initial: "ALL"
private const String
  FULLTEXT_DEFAULT
Initial: "FORMAT"
private const String
  FULLTEXT_NONE
Initial: "NONE"
public SelectItem
  FULLTEXT_OPTIONS
private HtmlSelectOneMenu
  genreSelect
Initial: new HtmlSelectOneMenu()
private String
  hiddenAlternativeTitlesField
private String
  hiddenIdsField
private IdentifierCollection
  identifierCollection
private UIXIterator
  identifierIterator
public const String
  INTERNAL_MD_FORMAT
Initial: "eSciDoc-publication-item"
private ItemValidating
  itemValidating
Initial: null
Notes: Validation Service
public static const String
  LOAD_EASYSUBMISSION
Initial: "loadEasySubmission"
Notes: Faces navigation string
private UIXIterator
  locatorIterator
Initial: new UIXIterator()
private String
  locatorUpload
public SelectItem
  locatorVisibilities
private static Logger
  logger
Initial: Logger.getLogger(EasySubmission.class)
private boolean
  overwriteCreators
private HtmlSelectOneRadio
  radioSelect
private HtmlSelectOneRadio
  radioSelectFulltext
Initial: new HtmlSelectOneRadio()
private HtmlSelectOneRadio
  radioSelectReference
Initial: new HtmlSelectOneRadio()
private const String
  REFERENCE_FILE
Initial: "FILE"
private const String
  REFERENCE_LOCATOR
Initial: "LOCATOR"
public SelectItem
  REFERENCE_OPTIONS
private String
  selectedDate
private String
  serviceID
private HtmlSelectOneMenu
  sourceSelect
Initial: new HtmlSelectOneMenu()
public SelectItem
  SUBMISSION_METHOD_FETCH_IMPORT
Initial: new SelectItem("FETCH_IMPORT", getLabel("easy_submission_method_fetch_import"))
public SelectItem
  SUBMISSION_METHOD_MANUAL
Initial: new SelectItem("MANUAL", getLabel("easy_submission_method_manual"))
Notes: constants for the submission method
public SelectItem
  SUBMISSION_METHOD_OPTIONS
Initial: new SelectItem[] { this.SUBMISSION_METHOD_MANUAL, this.SUBMISSION_METHOD_FETCH_IMPORT }
private String
  suggestConeUrl
Initial: null
private Transformation
  transformer
Initial: null
Notes: Transformation Service
private UploadedFile
  uploadedBibTexFile
private UploadedFile
  uploadedFile
private HtmlMessages
  valMessage
Initial: new HtmlMessages()
private XmlTransforming
  xmlTransforming
Initial: null
Notes: XML Transforming Service
 
EasySubmission Methods
Operation Details
public
addCreatorString():String
Sequential
public
addFile():String
Sequential
Notes: This method adds a file to the list of files of the item
@return navigation string (null)
public
addLocator():String
Sequential
Notes: This method adds a locator to the list of files of the item
@return navigation string (null)
private
bindFiles():void
Sequential
private
bindUploadedFiles():void
Sequential
Notes: This method binds the uploaded files to the files in the PubItem during the save process
public
cancelEasySubmission():String
Sequential
public
changeGenre():String
Sequential
Notes: This method changes the Genre and sets the needed property file for genre specific Metadata
@return String null
public
changeImportSource():String
Sequential
Notes: Triggered when the selection of the external system is changed Updates full text selection
@return String navigation string
public
chooseSourceGenre():String
Sequential
Notes: public void chooseSourceGenre(ValueChangeEvent event) { String sourceGenre = event.getNewValue().toString(); System.out.println(sourceGenre); if(sourceGenre.equals(SourceVO.Genre.JOURNAL.toString())) { this.setAutosuggestJournals(true); } }
public
EasySubmission():
Sequential
Notes: Public constructor.
public
fileUploaded(
   ValueChangeEvent event):void
Sequential
Notes: Uploads a file
public
getAbstract():String
Sequential
Notes: returns the value of the first abstract of the publication
@return String the value of the first abstract of the publication
public
getContentCategories():SelectItem
Sequential
Notes: Returns all options for content category.
@return all options for content category.
protected
getContextListSessionBean():ContextListSessionBean
Sequential
Notes: Returns the CollectionListSessionBean.
@return a reference to the scoped data bean (CollectionListSessionBean)
public
getContextName():String
Sequential
public
getCreatorCollection():CreatorCollection
Sequential
public
getCreatorIterator():UIXIterator
Sequential
public
getCreatorParseString():String
Sequential
public
getDATE_TYPE_OPTIONS():SelectItem
Sequential <<property get>>
Tags: attribute_name=DATE_TYPE_OPTIONS
public
getDateSelect():HtmlSelectOneMenu
Sequential
public
getDegreeTypes():SelectItem
Sequential
Notes: Returns all options for degreeType.
@return all options for degreeType
public
getDisableBibtexFields():boolean
Sequential
Notes: returns a flag which sets the fields of the import method 'Upload Bibtex file' to disabled or not
@return boolean the flag for disabling
public
getDisableExternalFields():boolean
Sequential
Notes: returns a flag which sets the fields of the import method 'fetch metadata from external systems' to disabled or not
@return boolean the flag for disabling
public
getDisableNextButton():boolean
Sequential
Notes: This method examines if the user has already selected a context for creating an item. If yes, the 'Next' button will be enabled, otherwise disabled
@return boolean Flag if the 'Next' button should be enabled or disabled
protected
getEasySubmissionSessionBean():EasySubmissionSessionBean
Sequential
Notes: Returns the EasySubmissionSessionBean.
@return a reference to the scoped data bean (EasySubmissionSessionBean)
protected
getEditItemSessionBean():EditItemSessionBean
Sequential
Notes: Returns the EditItemSessionBean.
@return a reference to the scoped data bean (EditItemSessionBean)
public
getEventTitleCollection():TitleCollection
Sequential
public
getEXTERNAL_SERVICE_OPTIONS():SelectItem
Sequential <<property get>>
Tags: attribute_name=EXTERNAL_SERVICE_OPTIONS
public
getFileIterator():UIXIterator
Sequential
public
getFiles():List
Sequential
public
getFreeKeywords():String
Sequential
public
getFromEasySubmission():boolean
Sequential
public
getFULLTEXT_OPTIONS():SelectItem
Sequential <<property get>>
Tags: attribute_name=FULLTEXT_OPTIONS
public
getGenres():SelectItem
Sequential
Notes: localized creation of SelectItems for the genres available.
@return SelectItem[] with Strings representing genres.
public
getGenreSelect():HtmlSelectOneMenu
Sequential
public
getHiddenAlternativeTitlesField():String
Sequential
public
getHiddenIdsField():String
Sequential
public
getIdentifierCollection():IdentifierCollection
Sequential
public
getIdentifierIterator():UIXIterator
Sequential
public
getInvited():boolean
Sequential
Notes: Invitationstatus of event has to be converted as it's an enum that is supposed to be shown in a checkbox.
@return true if invitationstatus in VO is set, else false
public
getItem():PubItemVO
Sequential
Notes: public PubItemVO getItem() { return this.getEasySubmissionSessionBean().getCurrentItem(); } public void setItem(PubItemVO item) { this.getEasySubmissionSessionBean().setCurrentItem(item); }
protected
getItemControllerSessionBean():ItemControllerSessionBean
Sequential
Notes: Returns the ItemControllerSessionBean.
@return a reference to the scoped data bean (ItemControllerSessionBean)
protected
getItemListSessionBean():ItemListSessionBean
Sequential
Notes: Returns the ItemListSessionBean.
@return a reference to the scoped data bean (ItemListSessionBean)
public
getLocatorIterator():UIXIterator
Sequential
public
getLocators():List
Sequential
public
getLocatorUpload():String
Sequential
public
getLocatorVisibilities():SelectItem
Sequential
Notes: Returns all options for visibility.
@return all options for visibility
public
getNumberOfFiles():int
Sequential
Notes: Returns the number of files attached to the current item
@return int the number of files
public
getNumberOfLocators():int
Sequential
Notes: Returns the number of files attached to the current item
@return int the number of files
public
getOverwriteCreators():boolean
Sequential
public
getPublicationLanguage():String
Sequential
Notes: returns the first language entry of the publication as String
@return String the first language entry of the publication as String
public
getPublicationLanguages():SelectItem
Sequential
Notes: Returns all options for publication language.
@return all options for publication language
public
getRadioSelect():HtmlSelectOneRadio
Sequential
public
getRadioSelectFulltext():HtmlSelectOneRadio
Sequential
public
getRadioSelectReference():HtmlSelectOneRadio
Sequential
public
getREFERENCE_FILE():String
Sequential <<property get>>
Tags: attribute_name=REFERENCE_FILE
public
getREFERENCE_LOCATOR():String
Sequential <<property get>>
Tags: attribute_name=REFERENCE_LOCATOR
public
getREFERENCE_OPTIONS():SelectItem
Sequential <<property get>>
Tags: attribute_name=REFERENCE_OPTIONS
public
getSelectedDate():String
Sequential
public
getServiceID():String
Sequential
public
getSource():SourceVO
Sequential
public
getSourceGenreOptions():SelectItem
Sequential
Notes: localized creation of SelectItems for the source genres available
@return SelectItem[] with Strings representing source genres
public
getSourceIdentifier():String
Sequential
public
getSourcePublisher():String
Sequential
public
getSourcePublisherPlace():String
Sequential
public
getSourceSelect():HtmlSelectOneMenu
Sequential
public
getSourceTitle():String
Sequential
public
getSubject():String
Sequential
Notes: returns the value of the first subject of the publication
@return String the value of the first subject of the publication
public
getSUBMISSION_METHOD_OPTIONS():SelectItem
Sequential <<property get>>
Tags: attribute_name=SUBMISSION_METHOD_OPTIONS
public
getSuggestConeUrl():String
Sequential
Tags: throws=Exception
Notes: This method returns the URL to the cone autosuggest service read from the properties
@author Tobias Schraut
@return String the URL to the cone autosuggest service
public
getUploadedBibTexFile():UploadedFile
Sequential
public
getUploadedFile():UploadedFile
Sequential
public
getValMessage():HtmlMessages
Sequential
public
getVisibilities():SelectItem
Sequential
Notes: Returns all options for visibility.
@return all options for visibility
public
harvestData():String
Sequential
Notes: Handles the import from an external ingestion sources
public
init():void
Sequential
Notes: Callback method that is called whenever a page containing this page fragment is navigated to, either directly via a URL, or indirectly via page navigation.
public
isAutosuggestJournals():boolean
Sequential
public
loadPreview():String
Sequential
public
loadStep1():String
Sequential
public
loadStep2():String
Sequential
public
loadStep3Manual():String
Sequential
public
loadStep4Manual():String
Sequential
public
loadStep5Manual():String
Sequential
private
mapSelectedDate():void
Sequential
Notes: This method maps the entered date into the MD record of the item according to the selected type
public
newEasySubmission():String
Sequential
public
newImport():String
Sequential
public
parseAndSetAlternativeSourceTitlesAndIds():String
Sequential
Notes: Takes the text from the hidden input fields, splits it using the delimiter and adds them to the item. Format of alternative titles: alt title 1 ||##|| alt title 2 ||##|| alt title 3 Format of ids: URN|urn:221441 ||##|| URL|http://www.xwdc.de ||##|| ESCIDOC|escidoc:21431
@return
public
reorganizeFileIndexes():void
Sequential
Notes: This method reorganizes the index property in PubFileVOPresentation after removing one element of the list.
public
reorganizeLocatorIndexes():void
Sequential
Notes: This method reorganizes the index property in PubFileVOPresentation after removing one element of the list.
public
save():String
Sequential
Notes: Saves the item.
@return string, identifying the page that should be navigated to after this methodcall
public
saveLocator():String
Sequential
public
saveValues():String
Sequential
public
selectImportBibtex():String
Sequential
Notes: This method selects the import method 'Upload Bibtex file'
@return String navigation string
public
selectImportExternal():String
Sequential
Notes: This method selects the import method 'fetch metadata from external systems'
@return String navigation string
public
selectSubmissionMethod():String
Sequential
public
setAbstract(
   String publicationAbstract):void
Sequential
public
setAutosuggestJournals(
   boolean autosuggestJournals):void
Sequential
private
setBibTexInfo():void
Sequential
public
setContextName(
   String contextName):void
Sequential
public
setCreatorCollection(
   CreatorCollection creatorCollection):void
Sequential
public
setCreatorIterator(
   UIXIterator creatorIterator):void
Sequential
public
setCreatorParseString(
   String creatorParseString):void
Sequential
public
setDATE_TYPE_OPTIONS(
   SelectItem[] date_type_options):void
Sequential <<property set>>
Tags: attribute_name=DATE_TYPE_OPTIONS
public
setDateSelect(
   HtmlSelectOneMenu dateSelect):void
Sequential
public
setEventTitleCollection(
   TitleCollection eventTitleCollection):void
Sequential
public
setEXTERNAL_SERVICE_OPTIONS(
   SelectItem[] external_service_options):void
Sequential <<property set>>
Tags: attribute_name=EXTERNAL_SERVICE_OPTIONS
public
setFileIterator(
   UIXIterator fileIterator):void
Sequential
public
setFiles(
   List files):void
Sequential
public
setFreeKeywords(
   String publicationSubject):void
Sequential
public
setFromEasySubmission(
   boolean fromEasySubmission):void
Sequential
public
setFULLTEXT_OPTIONS(
   SelectItem[] fulltext_options):void
Sequential <<property set>>
Tags: attribute_name=FULLTEXT_OPTIONS
public
setGenreSelect(
   HtmlSelectOneMenu genreSelect):void
Sequential
public
setHiddenAlternativeTitlesField(
   String hiddenAlternativeTitlesField):void
Sequential
public
setHiddenIdsField(
   String hiddenIdsField):void
Sequential
public
setIdentifierCollection(
   IdentifierCollection identifierCollection):void
Sequential
public
setIdentifierIterator(
   UIXIterator identifierIterator):void
Sequential
private
setImportSourcesInfo():void
Sequential
Notes: Fill import source values dynamically from importsourceHandler
public
setInvited(
   boolean invited):void
Sequential
Notes: Invitationstatus of event has to be converted as it's an enum that is supposed to be shown in a checkbox.
public
setItem(
   PubItemVOPresentation item):void
Sequential
public
setLocatorIterator(
   UIXIterator locatorIterator):void
Sequential
public
setLocators(
   List files):void
Sequential
public
setLocatorUpload(
   String locatorUpload):void
Sequential
public
setOverwriteCreators(
   boolean overwriteCreators):void
Sequential
public
setPublicationLanguage(
   String language):void
Sequential
public
setRadioSelect(
   HtmlSelectOneRadio radioSelect):void
Sequential
public
setRadioSelectFulltext(
   HtmlSelectOneRadio radioSelectFulltext):void
Sequential
public
setRadioSelectReference(
   HtmlSelectOneRadio radioSelectReference):void
Sequential
public
setREFERENCE_OPTIONS(
   SelectItem[] reference_options):void
Sequential <<property set>>
Tags: attribute_name=REFERENCE_OPTIONS
public
setSelectedDate(
   String selectedDate):void
Sequential
public
setServiceID(
   String serviceID):void
Sequential
public
setSource(
   SourceVO source):void
Sequential
public
setSourceIdentifier(
   String id):void
Sequential
public
setSourcePublisher(
   String publisher):void
Sequential
public
setSourcePublisherPlace(
   String place):void
Sequential
public
setSourceSelect(
   HtmlSelectOneMenu sourceSelect):void
Sequential
public
setSourceTitle(
   String title):void
Sequential
public
setSubject(
   String publicationSubject):void
Sequential
public
setSUBMISSION_METHOD_OPTIONS(
   SelectItem[] submission_method_options):void
Sequential <<property set>>
Tags: attribute_name=SUBMISSION_METHOD_OPTIONS
public
setUploadedBibTexFile(
   UploadedFile uploadedBibTexFile):void
Sequential
public
setUploadedFile(
   UploadedFile uploadedFile):void
Sequential
public
setValMessage(
   HtmlMessages valMessage):void
Sequential
private
showValidationMessages(
   ValidationReportVO report):void
Sequential
Notes: Displays validation messages.
@author Michael Franke
public
upload(
   boolean needMessages):String
Sequential
Notes: This method uploads a selected file and gives out error messages if needed
@return String navigation string
@author schraut
public
uploadBibtexFile():String
Sequential
public
uploadFile(
   UploadedFile file):String
Sequential
Notes: Uploads a file to the FIZ Framework and recieves and returns the location of the file in the FW
@return
protected
uploadFile(
   UploadedFile uploadedFile,
   String mimetype,
   String userHandle):URL
Sequential
Tags: throws=Exception
Notes: Uploads a file to the staging servlet and returns the corresponding URL.
@return The URL of the uploaded file.
protected
uploadFile(
   InputStream in,
   String mimetype,
   String userHandle):URL
Sequential
Tags: throws=Exception
Notes: Uploads a file to the staging servlet and returns the corresponding URL.
@param InputStream to upload
@return The URL of the uploaded file.
public
uploadLocator():void
Sequential
Notes: Uploads a file from a given locator.
private
validateStep5(
   String navigateTo):String
Sequential