@Override
  public final CompostableWasteCollectionRequestDocument modelToXml() {

    Calendar calendar = Calendar.getInstance();
    LocalTime localTime = new LocalTime();
    Date date = null;
    CompostableWasteCollectionRequestDocument compostableWasteCollectionRequestDoc =
        CompostableWasteCollectionRequestDocument.Factory.newInstance();
    CompostableWasteCollectionRequestDocument.CompostableWasteCollectionRequest
        compostableWasteCollectionRequest =
            compostableWasteCollectionRequestDoc.addNewCompostableWasteCollectionRequest();
    super.fillCommonXmlInfo(compostableWasteCollectionRequest);
    int i = 0;

    if (getCollectionAddress() != null)
      compostableWasteCollectionRequest.setCollectionAddress(
          Address.modelToXml(getCollectionAddress()));

    i = 0;
    if (getCompostableWasteType() != null) {
      fr.cg95.cvq.xml.common.LocalReferentialDataType[] compostableWasteTypeTypeTab =
          new fr.cg95.cvq.xml.common.LocalReferentialDataType[getCompostableWasteType().size()];
      for (LocalReferentialData object : getCompostableWasteType()) {
        compostableWasteTypeTypeTab[i++] = LocalReferentialData.modelToXml(object);
      }
      compostableWasteCollectionRequest.setCompostableWasteTypeArray(compostableWasteTypeTypeTab);
    }

    compostableWasteCollectionRequest.setOtherWaste(getOtherWaste());

    return compostableWasteCollectionRequestDoc;
  }
  public static CompostableWasteCollectionRequest xmlToModel(
      CompostableWasteCollectionRequestDocument compostableWasteCollectionRequestDoc) {
    CompostableWasteCollectionRequestDocument.CompostableWasteCollectionRequest
        compostableWasteCollectionRequestXml =
            compostableWasteCollectionRequestDoc.getCompostableWasteCollectionRequest();
    Calendar calendar = Calendar.getInstance();
    LocalTime localTime = new LocalTime();
    List list = new ArrayList();
    CompostableWasteCollectionRequest compostableWasteCollectionRequest =
        new CompostableWasteCollectionRequest();
    compostableWasteCollectionRequest.fillCommonModelInfo(
        compostableWasteCollectionRequest, compostableWasteCollectionRequestXml);

    if (compostableWasteCollectionRequestXml.getCollectionAddress() != null)
      compostableWasteCollectionRequest.setCollectionAddress(
          Address.xmlToModel(compostableWasteCollectionRequestXml.getCollectionAddress()));

    List<fr.cg95.cvq.business.request.LocalReferentialData> compostableWasteTypeList =
        new ArrayList<fr.cg95.cvq.business.request.LocalReferentialData>(
            compostableWasteCollectionRequestXml.sizeOfCompostableWasteTypeArray());
    for (LocalReferentialDataType object :
        compostableWasteCollectionRequestXml.getCompostableWasteTypeArray()) {
      compostableWasteTypeList.add(
          fr.cg95.cvq.business.request.LocalReferentialData.xmlToModel(object));
    }
    compostableWasteCollectionRequest.setCompostableWasteType(compostableWasteTypeList);

    compostableWasteCollectionRequest.setOtherWaste(
        compostableWasteCollectionRequestXml.getOtherWaste());

    return compostableWasteCollectionRequest;
  }