Esempio n. 1
0
  /**
   * Cleans For MIE Transformation. The intent of this method is to house "cleansing" operations
   * that must occur on the BMS in order to transform to an assignment MIE. Ideally the cleansing
   * would occur in the transformation but it is MUM at the point in time of the creation of this
   * class... If an AssignmentAddRq exists in the provide CIECA Document then a cleansed version of
   * the CIECADocument is returned, otherwise a copy of the provided Document is returned as is. The
   * fields that are cleansed are based on the logic in the BMS to MIE transformation, not every
   * single field in the BMS.
   *
   * @param ciecaDoc A CIECADocument. Nothing really happens unless the AssignmentAddRq is
   *     populated.
   * @return Returns a copy of the input CIECADocument. In the case where the input does include an
   *     AssignmentAddRq, that portion of the Document is cleansed for "to MIE" transformation.
   */
  public CIECADocument cleansForMIETransformation(CIECADocument ciecaDoc) {
    CIECADocument cDoc = null;
    if (ciecaDoc != null) {

      // Make a copy of the document so that the input is not modified
      cDoc = (CIECADocument) ciecaDoc.copy();

      // If there is an assignment then cleanse it
      AssignmentAddRq asgAddRq = cDoc.getCIECA().getAssignmentAddRq();
      if (asgAddRq != null) {

        asgAddRq = cleanseAsgAddRqForMIE(asgAddRq);
      }
    }
    return cDoc;
  }