コード例 #1
0
 /**
  * This method typecasts the given {@link XmlObject} to the required generator type and returns
  * back the document of that generator type.
  *
  * @param xmlObject which needs to be converted to the document type of the required generator
  * @return {@link XmlObject} document of the required generator type
  * @see org.kuali.kra.s2s.generator.S2SFormGenerator#getFormObject(XmlObject)
  */
 public XmlObject getFormObject(XmlObject xmlObject) {
   NSFSuggestedReviewersDocument nsfReviewersDocument =
       NSFSuggestedReviewersDocument.Factory.newInstance();
   NSFSuggestedReviewers nsfSuggestedReviewers = (NSFSuggestedReviewers) xmlObject;
   nsfReviewersDocument.setNSFSuggestedReviewers(nsfSuggestedReviewers);
   return nsfReviewersDocument;
 }
コード例 #2
0
  /**
   * This method returns NSFSuggestedReviewersDocument object based on proposal development document
   * which contains the NSFSuggestedReviewersDocument informations SuggestedReviewers and inclusion
   * of Reviewer for a particular proposal
   *
   * @return nsfReviewersDocument {@link XmlObject} of type NSFSuggestedReviewersDocument.
   */
  private NSFSuggestedReviewersDocument getNSFSuggestedReviewers() {

    NSFSuggestedReviewersDocument nsfReviewersDocument =
        NSFSuggestedReviewersDocument.Factory.newInstance();
    NSFSuggestedReviewers nsfSuggestedReviewers = NSFSuggestedReviewers.Factory.newInstance();
    nsfSuggestedReviewers.setFormVersion(S2SConstants.FORMVERSION_1_1);
    String suggestedRev = getAbstractText(SUGGESTED_REVIEWERS);
    if (suggestedRev != null && !suggestedRev.equals("")) {
      nsfSuggestedReviewers.setSuggestedReviewers(suggestedRev);
    }
    String doNotInclude = getAbstractText(REVIEWERS_NOT_TO_INCLUDE);
    if (doNotInclude != null && !doNotInclude.equals("")) {
      nsfSuggestedReviewers.setReviewersNotToInclude(doNotInclude);
    }
    nsfReviewersDocument.setNSFSuggestedReviewers(nsfSuggestedReviewers);
    return nsfReviewersDocument;
  }