Пример #1
0
 def parse(self, dataset_name):
     score_objects = []
     for toetsnorm_tag in self.toetsnorm_tags:
         identificatie = self.parse_identificatie(toetsnorm_tag)
         if dataset_name != WATERBEHEERDER_DATASET.get(
             identificatie.waterschapid):
             continue
         score_object = ScoreObject()
         score_object.identificatie = identificatie
         score_object.vanToepassingOpGeoObject = self.parse_vantoepassingopgeoobject(
             toetsnorm_tag)
         score_object.chemischeStof = self.parse_chemischestof(toetsnorm_tag) 
         score_object.onderdeelvannormpakket = self.parse_onderdeelvannormpakket(
             toetsnorm_tag)
         score_objects.append(score_object)           
     return score_objects
Пример #2
0
    def parse(self, dataset_name):
        """Return list of MeasureObjects."""
        measure_objects = []
        for measure_tag in self.measure_tags:
            identificatie = self.parse_identificatie(measure_tag)
            if dataset_name != WATERBEHEERDER_DATASET.get(
                identificatie.waterschapid):
                continue
            measure_object = MeasureObject()
            measure_object.identificatie = identificatie
            measure_object.typeMaatregel = self.parse_typemaatregel(
                measure_tag)
            measure_object.omschrijving = self.parse_omschrijving(measure_tag)
            measure_object.waarde = self.parse_waarde(measure_tag)
            measure_object.maatregelKostenDatatype = self.parse_kostendatatype(
                measure_tag)
            measure_object.initieleKostendrager = self.parse_initielekostendrager(
                measure_tag)
            measure_object.geldenVoorWaterbeheerGebied = self.parse_geldenvoorwaterbeheergebieden(measure_tag)
            measure_object.importRaw = objectify.dump(measure_tag)

            measure_objects.append(measure_object)

        return measure_objects