Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFile.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFile.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFile.java	(revision 33649)
@@ -14,4 +14,5 @@
 
 import org.openstreetmap.josm.data.coor.EastNorth;
+import org.openstreetmap.josm.data.osm.DataSet;
 import org.openstreetmap.josm.tools.Logging;
 
@@ -102,4 +103,5 @@
     }
 
+    protected final Path path;
     private boolean bomFound;
     private boolean eomFound;
@@ -107,6 +109,9 @@
     private Block currentBlock;
 
-    EdigeoFile(Path path) throws IOException {
-        init();
+    EdigeoFile(Path path) {
+        this.path = path;
+    }
+
+    public EdigeoFile read(DataSet ds) throws IOException, ReflectiveOperationException {
         try (BufferedReader reader = Files.newBufferedReader(path, StandardCharsets.ISO_8859_1)) {
             String line;
@@ -148,15 +153,17 @@
             }
         }
+        return this;
     }
 
-    protected void init() {
-        // To be overidden if needed
+    protected abstract Block createBlock(String type) throws ReflectiveOperationException;
+
+    protected static <T extends Block> T addBlock(List<T> blocks, T block) {
+        blocks.add(block);
+        return block;
     }
 
-    protected abstract Block createBlock(String type);
-
-    private void processRecord(EdigeoRecord r) {
+    private void processRecord(EdigeoRecord r) throws ReflectiveOperationException {
         if ("RTY".equals(r.name)) {
-            currentBlock = createBlock(r.values.get(0));
+            currentBlock = Objects.requireNonNull(createBlock(r.values.get(0)), r.toString());
             return;
         }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileDIC.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileDIC.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileDIC.java	(revision 33649)
@@ -8,13 +8,18 @@
 import java.util.List;
 
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileDIC.DicBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+
 /**
  * Edigeo DIC file.
  */
-public class EdigeoFileDIC extends EdigeoFile {
+public class EdigeoFileDIC extends EdigeoLotFile<DicBlock> {
 
     /**
      * Abstract definition.
      */
-    abstract static class Def extends Block {
+    abstract static class DicBlock extends ChildBlock {
 
         /** LAB */ String code = "";
@@ -24,6 +29,6 @@
         /** CAT */ String category = "";
 
-        Def(String type) {
-            super(type);
+        DicBlock(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -77,7 +82,7 @@
      * Object definition.
      */
-    public static class ObjectDef extends Def {
-        ObjectDef(String type) {
-            super(type);
+    public static class ObjectDef extends DicBlock {
+        ObjectDef(Lot lot, String type) {
+            super(lot, type);
         }
     }
@@ -86,5 +91,5 @@
      * Attribute definition.
      */
-    public static class AttributeDef extends Def {
+    public static class AttributeDef extends DicBlock {
 
         /** TYP */ String type = "";
@@ -94,6 +99,6 @@
         /** AVD */ final List<String> descrs = new ArrayList<>();
 
-        AttributeDef(String type) {
-            super(type);
+        AttributeDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -155,48 +160,29 @@
      * Relation definition.
      */
-    public static class RelationDef extends Def {
-        RelationDef(String type) {
-            super(type);
-        }
-    }
-
-    /** DID */ List<ObjectDef> objects;
-    /** DIA */ List<AttributeDef> attributes;
-    /** DIR */ List<RelationDef> relations;
+    public static class RelationDef extends DicBlock {
+        RelationDef(Lot lot, String type) {
+            super(lot, type);
+        }
+    }
 
     /**
      * Constructs a new {@code EdigeoFileDIC}.
+     * @param lot parent lot
+     * @param seId subset id
      * @param path path to DIC file
      * @throws IOException if any I/O error occurs
      */
-    public EdigeoFileDIC(Path path) throws IOException {
-        super(path);
+    public EdigeoFileDIC(Lot lot, String seId, Path path) throws IOException {
+        super(lot, seId, path);
+        register("DID", ObjectDef.class);
+        register("DIA", AttributeDef.class);
+        register("DIR", RelationDef.class);
+        lot.dic = this;
     }
 
     @Override
-    protected void init() {
-        objects = new ArrayList<>();
-        attributes = new ArrayList<>();
-        relations = new ArrayList<>();
-    }
-
-    @Override
-    protected Block createBlock(String type) {
-        switch (type) {
-        case "DID":
-            ObjectDef objDef = new ObjectDef(type);
-            objects.add(objDef);
-            return objDef;
-        case "DIA":
-            AttributeDef attDef = new AttributeDef(type);
-            attributes.add(attDef);
-            return attDef;
-        case "DIR":
-            RelationDef relDef = new RelationDef(type);
-            relations.add(relDef);
-            return relDef;
-        default:
-            throw new IllegalArgumentException(type);
-        }
+    public EdigeoFileDIC read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        return this;
     }
 
@@ -206,5 +192,5 @@
      */
     public final List<ObjectDef> getObjects() {
-        return Collections.unmodifiableList(objects);
+        return Collections.unmodifiableList(blocks.getInstances(ObjectDef.class));
     }
 
@@ -214,5 +200,5 @@
      */
     public final List<AttributeDef> getAttributes() {
-        return Collections.unmodifiableList(attributes);
+        return Collections.unmodifiableList(blocks.getInstances(AttributeDef.class));
     }
 
@@ -222,5 +208,5 @@
      */
     public final List<RelationDef> getRelations() {
-        return Collections.unmodifiableList(relations);
+        return Collections.unmodifiableList(blocks.getInstances(RelationDef.class));
     }
 }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileGEN.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileGEN.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileGEN.java	(revision 33649)
@@ -7,18 +7,29 @@
 import java.nio.file.Path;
 
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileGEN.GenBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+
 /**
  * Edigeo GEN file.
  */
-public class EdigeoFileGEN extends EdigeoFile {
+public class EdigeoFileGEN extends EdigeoLotFile<GenBlock> {
+
+    abstract static class GenBlock extends ChildBlock {
+        GenBlock(Lot lot, String type) {
+            super(lot, type);
+        }
+    }
 
     /**
      * Geographic bounds.
      */
-    public static class GeoBounds extends Block {
+    public static class GeoBounds extends GenBlock {
         /** CM1 */ String min = "";
         /** CM2 */ String max = "";
 
-        GeoBounds(String type) {
-            super(type);
+        GeoBounds(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -53,5 +64,5 @@
      * Geographic data.
      */
-    public static class GeoData extends Block {
+    public static class GeoData extends GenBlock {
 
         /**
@@ -84,6 +95,6 @@
         /** REG */ String offsetId = "";
 
-        GeoData(String type) {
-            super(type);
+        GeoData(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -124,28 +135,22 @@
     }
 
-    /** DEG */ GeoBounds bounds;
-    /** GSE */ GeoData geodata;
-
     /**
      * Constructs a new {@code EdigeoFileGEN}.
+     * @param lot parent lot
+     * @param seId subset id
      * @param path path to GEN file
      * @throws IOException if any I/O error occurs
      */
-    public EdigeoFileGEN(Path path) throws IOException {
-        super(path);
+    public EdigeoFileGEN(Lot lot, String seId, Path path) throws IOException {
+        super(lot, seId, path);
+        register("DEG", GeoBounds.class);
+        register("GSE", GeoData.class);
+        lot.gen = this;
     }
 
     @Override
-    protected Block createBlock(String type) {
-        switch (type) {
-        case "DEG":
-            bounds = new GeoBounds(type);
-            return bounds;
-        case "GSE":
-            geodata = new GeoData(type);
-            return geodata;
-        default:
-            throw new IllegalArgumentException(type);
-        }
+    public EdigeoFileGEN read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        return this;
     }
 }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileGEO.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileGEO.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileGEO.java	(revision 33649)
@@ -7,13 +7,24 @@
 import java.nio.file.Path;
 
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileGEO.GeoBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+
 /**
  * Edigeo GEO file.
  */
-public class EdigeoFileGEO extends EdigeoFile {
+public class EdigeoFileGEO extends EdigeoLotFile<GeoBlock> {
+
+    abstract static class GeoBlock extends ChildBlock {
+        GeoBlock(Lot lot, String type) {
+            super(lot, type);
+        }
+    }
 
     /**
      * Coordinates reference.
      */
-    public static class CoorReference extends Block {
+    public static class CoorReference extends GeoBlock {
 
         enum ReferenceType {
@@ -63,6 +74,6 @@
         /** UNH */ String unit = "";
 
-        CoorReference(String type) {
-            super(type);
+        CoorReference(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -132,17 +143,19 @@
     /**
      * Constructs a new {@code EdigeoFileGEO}.
+     * @param lot parent lot
+     * @param seId subset id
      * @param path path to GEO file
      * @throws IOException if any I/O error occurs
      */
-    public EdigeoFileGEO(Path path) throws IOException {
-        super(path);
+    public EdigeoFileGEO(Lot lot, String seId, Path path) throws IOException {
+        super(lot, seId, path);
+        register("GEO", CoorReference.class);
+        lot.geo = this;
     }
 
     @Override
-    protected Block createBlock(String type) {
-        if ("GEO".equals(type)) {
-            return new CoorReference(type);
-        }
-        throw new IllegalArgumentException(type);
+    public EdigeoFileGEO read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        return this;
     }
 }
Index: plications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileMAT.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileMAT.java	(revision 33648)
+++ 	(revision )
@@ -1,27 +1,0 @@
-// License: GPL. For details, see LICENSE file.
-package org.openstreetmap.josm.plugins.fr.cadastre.edigeo;
-
-import java.io.IOException;
-import java.nio.file.Path;
-
-/**
- * Edigeo MAT file.
- */
-public class EdigeoFileMAT extends EdigeoFile {
-
-    /**
-     * Constructs a new {@code EdigeoFileMAT}.
-     * @param path path to MAT file
-     * @throws IOException if any I/O error occurs
-     */
-    EdigeoFileMAT(Path path) throws IOException {
-        super(path);
-    }
-
-    @Override
-    protected Block createBlock(String type) {
-        // TODO Auto-generated method stub
-        return null;
-    }
-
-}
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileQAL.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileQAL.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileQAL.java	(revision 33649)
@@ -8,13 +8,24 @@
 import java.util.List;
 
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileQAL.QalBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+
 /**
  * Edigeo QAL file.
  */
-public class EdigeoFileQAL extends EdigeoFile {
+public class EdigeoFileQAL extends EdigeoLotFile<QalBlock> {
+
+    abstract static class QalBlock extends ChildBlock {
+        QalBlock(Lot lot, String type) {
+            super(lot, type);
+        }
+    }
 
     /**
      * Update descriptor.
      */
-    public static class Update extends Block {
+    public static class Update extends QalBlock {
 
         enum UpdateType {
@@ -67,6 +78,6 @@
         /** COP */ final List<String> mcdRef = new ArrayList<>();
 
-        Update(String type) {
-            super(type);
+        Update(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -90,17 +101,19 @@
     /**
      * Constructs a new {@code EdigeoFileQAL}.
+     * @param lot parent lot
+     * @param seId subset id
      * @param path path to QAL file
      * @throws IOException if any I/O error occurs
      */
-    public EdigeoFileQAL(Path path) throws IOException {
-        super(path);
+    public EdigeoFileQAL(Lot lot, String seId, Path path) throws IOException {
+        super(lot, seId, path);
+        register("QUP", Update.class);
+        lot.qal = this;
     }
 
     @Override
-    protected Block createBlock(String type) {
-        if ("QUP".equals(type)) {
-            return new Update(type);
-        }
-        throw new IllegalArgumentException(type);
+    public EdigeoFileQAL read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        return this;
     }
 }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileSCD.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileSCD.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileSCD.java	(revision 33649)
@@ -7,13 +7,27 @@
 import java.util.List;
 
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileSCD.ScdBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+
 /**
  * Edigeo SCD file.
  */
-public class EdigeoFileSCD extends EdigeoFile {
+public class EdigeoFileSCD extends EdigeoLotFile<ScdBlock> {
+
+    /**
+     * MCD definition.
+     */
+    abstract static class ScdBlock extends ChildBlock {
+        ScdBlock(Lot lot, String type) {
+            super(lot, type);
+        }
+    }
 
     /**
      * MCD Object definition.
      */
-    public static class McdObjDef extends Block {
+    public static class McdObjectDef extends ScdBlock {
 
         /** DIP */ String dictRef = "";
@@ -23,6 +37,6 @@
         /** QAC */ int nQualities;
 
-        McdObjDef(String type) {
-            super(type);
+        McdObjectDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -44,5 +58,5 @@
      * MCD Attribute definition.
      */
-    public static class McdAttrDef extends Block {
+    public static class McdAttributeDef extends ScdBlock {
 
         /** DIP */ String dictRef = "";
@@ -54,6 +68,6 @@
         /** AV2 */ String max = "";
 
-        McdAttrDef(String type) {
-            super(type);
+        McdAttributeDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -77,5 +91,5 @@
      * MCD Primitive definition.
      */
-    public static class McdPrimDef extends Block {
+    public static class McdPrimitiveDef extends ScdBlock {
 
         enum PrimitiveKind {
@@ -103,6 +117,6 @@
         /** QAC */ int nQualities;
 
-        McdPrimDef(String type) {
-            super(type);
+        McdPrimitiveDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -122,16 +136,16 @@
      * MCD Relation definition.
      */
-    abstract static class McdRelDef extends Block {
+    abstract static class McdRelationDef extends ScdBlock {
 
         /** CA1 */ int minCardinal;
         /** CA2 */ int maxCardinal;
         /** SCC */ int nTypes;
-        /** SCP */ final List<String> scdRef = new ArrayList<>();
+        /** SCP */ final List<ScdBlock> scdRef = new ArrayList<>();
         /** OCC */ final List<Integer> nOccurences = new ArrayList<>();
         /** AAC */ int nAttributes;
         /** QAC */ int nQualities;
 
-        McdRelDef(String type) {
-            super(type);
+        McdRelationDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -142,5 +156,5 @@
             case "CA2": maxCardinal = safeGetInt(r); break;
             case "SCC": nTypes = safeGetInt(r); break;
-            case "SCP": safeGet(r, scdRef); break;
+            case "SCP": scdRef.add(lot.scd.find(r.values)); break;
             case "OCC": nOccurences.add(safeGetInt(r)); break;
             case "AAC": nAttributes = safeGetInt(r); break;
@@ -155,10 +169,10 @@
      * MCD Semantic Relation definition.
      */
-    public static class McdSemRelDef extends McdRelDef {
+    public static class McdSemanticRelationDef extends McdRelationDef {
 
         /** DIP */ String dictRef = "";
 
-        McdSemRelDef(String type) {
-            super(type);
+        McdSemanticRelationDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -176,5 +190,5 @@
      * MCD Construction Relation definition.
      */
-    public static class McdBuildRelDef extends McdRelDef {
+    public static class McdConstructionRelationDef extends McdRelationDef {
 
         enum RelationKind {
@@ -206,6 +220,6 @@
         /** KND */ RelationKind kind;
 
-        McdBuildRelDef(String type) {
-            super(type);
+        McdConstructionRelationDef(Lot lot, String type) {
+            super(lot, type);
         }
 
@@ -222,27 +236,23 @@
     /**
      * Constructs a new {@code EdigeoFileSCD}.
+     * @param lot parent lot
+     * @param seId subset id
      * @param path path to SCD file
      * @throws IOException if any I/O error occurs
      */
-    public EdigeoFileSCD(Path path) throws IOException {
-        super(path);
+    public EdigeoFileSCD(Lot lot, String seId, Path path) throws IOException {
+        super(lot, seId, path);
+        register("OBJ", McdObjectDef.class);
+        register("ATT", McdAttributeDef.class);
+        register("PGE", McdPrimitiveDef.class);
+        register("ASS", McdSemanticRelationDef.class);
+        register("REL", McdConstructionRelationDef.class);
+        lot.scd = this;
     }
 
     @Override
-    protected Block createBlock(String type) {
-        switch (type) {
-        case "OBJ":
-            return new McdObjDef(type);
-        case "ATT":
-            return new McdAttrDef(type);
-        case "PGE":
-            return new McdPrimDef(type);
-        case "ASS":
-            return new McdSemRelDef(type);
-        case "REL":
-            return new McdBuildRelDef(type);
-        default:
-            throw new IllegalArgumentException(type);
-        }
+    public EdigeoFileSCD read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        return this;
     }
 }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileTHF.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileTHF.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileTHF.java	(revision 33649)
@@ -10,4 +10,7 @@
 import java.util.Collections;
 import java.util.List;
+import java.util.Objects;
+
+import org.openstreetmap.josm.data.osm.DataSet;
 
 /**
@@ -186,17 +189,24 @@
         /** LON */ String name = "";
         /** INF */ String information = "";
-        /** GNN */ String genDataName = "";
-        /** GNI */ String genDataId = "";
-        /** GON */ String coorRefName = "";
-        /** GOI */ String coorRefId = "";
-        /** QAN */ String qualityName = "";
-        /** QAI */ String qualityId = "";
-        /** DIN */ String dictName = "";
-        /** DII */ String dictId = "";
+        /** GNN */ String genName = "";
+        /** GNI */ String genId = "";
+        /** GON */ String geoName = "";
+        /** GOI */ String geoId = "";
+        /** QAN */ String qalName = "";
+        /** QAI */ String qalId = "";
+        /** DIN */ String dicName = "";
+        /** DII */ String dicId = "";
         /** SCN */ String scdName = "";
         /** SCI */ String scdId = "";
-        /** GDC */ int nGeoData;
-        /** GDN */ final List<String> geoDataName = new ArrayList<>();
-        /** GDI */ final List<String> geoDataId = new ArrayList<>();
+        /** GDC */ int nVec;
+        /** GDN */ final List<String> vecName = new ArrayList<>();
+        /** GDI */ final List<String> vecId = new ArrayList<>();
+
+        EdigeoFileGEN gen;
+        EdigeoFileGEO geo;
+        EdigeoFileDIC dic;
+        EdigeoFileSCD scd;
+        EdigeoFileQAL qal;
+        final List<EdigeoFileVEC> vec = new ArrayList<>();
 
         Lot(String type) {
@@ -209,17 +219,17 @@
             case "LON": safeGetAndLog(r, s -> name += s, tr("Name")); break;
             case "INF": safeGetAndLog(r, s -> information += s, tr("Information")); break;
-            case "GNN": safeGet(r, s -> genDataName += s); break;
-            case "GNI": safeGet(r, s -> genDataId += s); break;
-            case "GON": safeGet(r, s -> coorRefName += s); break;
-            case "GOI": safeGet(r, s -> coorRefId += s); break;
-            case "QAN": safeGet(r, s -> qualityName += s); break;
-            case "QAI": safeGet(r, s -> qualityId += s); break;
-            case "DIN": safeGet(r, s -> dictName += s); break;
-            case "DII": safeGet(r, s -> dictId += s); break;
+            case "GNN": safeGet(r, s -> genName += s); break;
+            case "GNI": safeGet(r, s -> genId += s); break;
+            case "GON": safeGet(r, s -> geoName += s); break;
+            case "GOI": safeGet(r, s -> geoId += s); break;
+            case "QAN": safeGet(r, s -> qalName += s); break;
+            case "QAI": safeGet(r, s -> qalId += s); break;
+            case "DIN": safeGet(r, s -> dicName += s); break;
+            case "DII": safeGet(r, s -> dicId += s); break;
             case "SCN": safeGet(r, s -> scdName += s); break;
             case "SCI": safeGet(r, s -> scdId += s); break;
-            case "GDC": nGeoData = safeGetInt(r); break;
-            case "GDN": safeGet(r, geoDataName); break;
-            case "GDI": safeGet(r, geoDataId); break;
+            case "GDC": nVec = safeGetInt(r); break;
+            case "GDN": safeGet(r, vecName); break;
+            case "GDI": safeGet(r, vecId); break;
             default:
                 super.processRecord(r);
@@ -227,4 +237,16 @@
         }
 
+        void readFiles(Path path, DataSet ds) throws IOException, ReflectiveOperationException {
+            Path dir = path.getParent();
+            new EdigeoFileGEN(this, genId, dir.resolve(name + genName + ".GEN")).read(ds);
+            new EdigeoFileGEO(this, geoId, dir.resolve(name + geoName + ".GEO")).read(ds);
+            new EdigeoFileDIC(this, dicId, dir.resolve(name + dicName + ".DIC")).read(ds);
+            new EdigeoFileSCD(this, scdId, dir.resolve(name + scdName + ".SCD")).read(ds);
+            new EdigeoFileQAL(this, qalId, dir.resolve(name + qalName + ".QAL")).read(ds);
+            for (int i = 0; i < getNumberOfGeoData(); i++) {
+                new EdigeoFileVEC(this, vecId.get(i), dir.resolve(name + vecName.get(i) + ".VEC")).read(ds);
+            }
+        }
+
         /**
          * Returns name.
@@ -248,5 +270,5 @@
          */
         public final String getGenDataName() {
-            return genDataName;
+            return genName;
         }
 
@@ -256,5 +278,5 @@
          */
         public final String getGenDataId() {
-            return genDataId;
+            return genId;
         }
 
@@ -264,5 +286,5 @@
          */
         public final String getCoorRefName() {
-            return coorRefName;
+            return geoName;
         }
 
@@ -272,5 +294,5 @@
          */
         public final String getCoorRefId() {
-            return coorRefId;
+            return geoId;
         }
 
@@ -280,5 +302,5 @@
          */
         public final String getQualityName() {
-            return qualityName;
+            return qalName;
         }
 
@@ -288,5 +310,5 @@
          */
         public final String getQualityId() {
-            return qualityId;
+            return qalId;
         }
 
@@ -296,5 +318,5 @@
          */
         public final String getDictName() {
-            return dictName;
+            return dicName;
         }
 
@@ -304,5 +326,5 @@
          */
         public final String getDictId() {
-            return dictId;
+            return dicId;
         }
 
@@ -328,5 +350,5 @@
          */
         public final int getNumberOfGeoData() {
-            return nGeoData;
+            return nVec;
         }
 
@@ -337,5 +359,5 @@
          */
         public final String getGeoDataName(int i) {
-            return geoDataName.get(i);
+            return vecName.get(i);
         }
 
@@ -345,5 +367,5 @@
          */
         public final List<String> getGeoDataNames() {
-            return Collections.unmodifiableList(geoDataName);
+            return Collections.unmodifiableList(vecName);
         }
 
@@ -353,5 +375,5 @@
          */
         public final List<String> getGeoDataIds() {
-            return Collections.unmodifiableList(geoDataId);
+            return Collections.unmodifiableList(vecId);
         }
 
@@ -362,10 +384,23 @@
          */
         public final String getGeoDataId(int i) {
-            return geoDataId.get(i);
-        }
-    }
-
-    Support support;
-    List<Lot> lots;
+            return vecId.get(i);
+        }
+    }
+
+    /**
+     * Block inside {@link EdigeoLotFile}.
+     */
+    public static class ChildBlock extends Block {
+
+        protected final Lot lot;
+
+        ChildBlock(Lot lot, String type) {
+            super(type);
+            this.lot = Objects.requireNonNull(lot, "lot");
+        }
+    }
+
+    /** GTS */ Support support;
+    /** GTL */ final List<Lot> lots = new ArrayList<>();
 
     /**
@@ -378,9 +413,4 @@
     }
 
-    @Override
-    protected void init() {
-        lots = new ArrayList<>();
-    }
-
     /**
      * Returns the support descriptor.
@@ -402,14 +432,18 @@
     protected Block createBlock(String type) {
         switch (type) {
-            case "GTS":
-                support = new Support(type);
-                return support;
-            case "GTL":
-                Lot lot = new Lot(type);
-                lots.add(lot);
-                return lot;
+            case "GTS": return support = new Support(type);
+            case "GTL": return addBlock(lots, new Lot(type));
             default:
                 throw new IllegalArgumentException(type);
         }
     }
+
+    @Override
+    public EdigeoFileTHF read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        for (Lot lot : getLots()) {
+            lot.readFiles(path, ds);
+        }
+        return this;
+    }
 }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileVEC.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileVEC.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoFileVEC.java	(revision 33649)
@@ -5,4 +5,5 @@
 import java.nio.file.Path;
 import java.util.ArrayList;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.List;
@@ -10,14 +11,43 @@
 
 import org.openstreetmap.josm.data.coor.EastNorth;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.data.osm.Node;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileSCD.McdObjectDef;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileSCD.McdPrimitiveDef;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileSCD.McdRelationDef;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileSCD.ScdBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileVEC.VecBlock;
 
 /**
  * Edigeo VEC file.
  */
-public class EdigeoFileVEC extends EdigeoFile {
+public class EdigeoFileVEC extends EdigeoLotFile<VecBlock<?>> {
+
+    abstract static class VecBlock<T extends ScdBlock> extends ChildBlock {
+        final Class<T> klass;
+
+        /** SCP */ T scdRef;
+
+        VecBlock(Lot lot, String type, Class<T> klass) {
+            super(lot, type);
+            this.klass = klass;
+        }
+
+        @Override
+        void processRecord(EdigeoRecord r) {
+            switch (r.name) {
+            case "SCP": scdRef = lot.scd.find(r.values, klass); break;
+            default:
+                super.processRecord(r);
+            }
+        }
+    }
 
     /**
      * Node descriptor block.
      */
-    public static class NodeBlock extends Block {
+    public static class NodeBlock extends VecBlock<McdPrimitiveDef> {
 
         enum NodeType {
@@ -40,5 +70,4 @@
         }
 
-        /** SCP */ String scdRef = "";
         /** TYP */ NodeType nodeType;
         /** COR */ EastNorth coordinate;
@@ -46,12 +75,11 @@
         /** QAC */ int nQualities;
 
-        NodeBlock(String type) {
-            super(type);
-        }
-
-        @Override
-        void processRecord(EdigeoRecord r) {
-            switch (r.name) {
-            case "SCP": safeGet(r, s -> scdRef += s); break;
+        NodeBlock(Lot lot, String type) {
+            super(lot, type, McdPrimitiveDef.class);
+        }
+
+        @Override
+        void processRecord(EdigeoRecord r) {
+            switch (r.name) {
             case "TYP": nodeType = NodeType.of(safeGetInt(r)); break;
             case "COR": coordinate = safeGetEastNorth(r); break;
@@ -62,4 +90,44 @@
             }
         }
+
+        /**
+         * Returns the reference to SCD.
+         * @return the reference to SCD
+         */
+        public final McdPrimitiveDef getScdRef() {
+            return scdRef;
+        }
+
+        /**
+         * Returns the node type.
+         * @return the node type
+         */
+        public final NodeType getNodeType() {
+            return nodeType;
+        }
+
+        /**
+         * Returns the node coordinates.
+         * @return the node coordinates
+         */
+        public final EastNorth getCoordinate() {
+            return coordinate;
+        }
+
+        /**
+         * Returns the number of attributes.
+         * @return the number of attributes
+         */
+        public final int getNumberOfAttributes() {
+            return nAttributes;
+        }
+
+        /**
+         * Returns the number of quality indicators.
+         * @return the number of quality indicators
+         */
+        public final int getNumberOfQualityIndicators() {
+            return nQualities;
+        }
     }
 
@@ -67,5 +135,5 @@
      * Arc descriptor block.
      */
-    public static class ArcBlock extends Block {
+    public static class ArcBlock extends VecBlock<McdPrimitiveDef> {
         enum ArcType {
             LINE(1),
@@ -88,5 +156,4 @@
         }
 
-        /** SCP */ String scdRef = "";
         /** CM1 */ EastNorth minCoordinate;
         /** CM2 */ EastNorth maxCoordinate;
@@ -98,12 +165,11 @@
         /** QAC */ int nQualities;
 
-        ArcBlock(String type) {
-            super(type);
-        }
-
-        @Override
-        void processRecord(EdigeoRecord r) {
-            switch (r.name) {
-            case "SCP": safeGet(r, s -> scdRef += s); break;
+        ArcBlock(Lot lot, String type) {
+            super(lot, type, McdPrimitiveDef.class);
+        }
+
+        @Override
+        void processRecord(EdigeoRecord r) {
+            switch (r.name) {
             case "CM1": minCoordinate = safeGetEastNorth(r); break;
             case "CM2": maxCoordinate = safeGetEastNorth(r); break;
@@ -129,6 +195,5 @@
      * Face descriptor block.
      */
-    public static class FaceBlock extends Block {
-        /** SCP */ String scdRef = "";
+    public static class FaceBlock extends VecBlock<McdPrimitiveDef> {
         /** CM1 */ EastNorth minCoordinate;
         /** CM2 */ EastNorth maxCoordinate;
@@ -136,12 +201,11 @@
         /** QAC */ int nQualities;
 
-        FaceBlock(String type) {
-            super(type);
-        }
-
-        @Override
-        void processRecord(EdigeoRecord r) {
-            switch (r.name) {
-            case "SCP": safeGet(r, s -> scdRef += s); break;
+        FaceBlock(Lot lot, String type) {
+            super(lot, type, McdPrimitiveDef.class);
+        }
+
+        @Override
+        void processRecord(EdigeoRecord r) {
+            switch (r.name) {
             case "CM1": minCoordinate = safeGetEastNorth(r); break;
             case "CM2": maxCoordinate = safeGetEastNorth(r); break;
@@ -157,6 +221,5 @@
      * Object descriptor block.
      */
-    public static class ObjectBlock extends Block {
-        /** SCP */ String scdRef = "";
+    public static class ObjectBlock extends VecBlock<McdObjectDef> {
         /** CM1 */ EastNorth minCoordinate;
         /** CM2 */ EastNorth maxCoordinate;
@@ -169,12 +232,11 @@
         /** QAP */ final List<String> qualityIndics = new ArrayList<>();
 
-        ObjectBlock(String type) {
-            super(type);
-        }
-
-        @Override
-        void processRecord(EdigeoRecord r) {
-            switch (r.name) {
-            case "SCP": safeGet(r, s -> scdRef += s); break;
+        ObjectBlock(Lot lot, String type) {
+            super(lot, type, McdObjectDef.class);
+        }
+
+        @Override
+        void processRecord(EdigeoRecord r) {
+            switch (r.name) {
             case "CM1": minCoordinate = safeGetEastNorth(r); break;
             case "CM2": maxCoordinate = safeGetEastNorth(r); break;
@@ -195,5 +257,5 @@
      * Relation descriptor block.
      */
-    public static class RelationBlock extends Block {
+    public static class RelationBlock extends VecBlock<McdRelationDef> {
 
         enum Composition {
@@ -216,5 +278,4 @@
         }
 
-        /** SCP */ String scdRef = "";
         /** FTC */ int nElements;
         /** FTP */ final List<String> elements = new ArrayList<>();
@@ -223,12 +284,11 @@
         /** QAC */ int nQualities;
 
-        RelationBlock(String type) {
-            super(type);
-        }
-
-        @Override
-        void processRecord(EdigeoRecord r) {
-            switch (r.name) {
-            case "SCP": safeGet(r, s -> scdRef += s); break;
+        RelationBlock(Lot lot, String type) {
+            super(lot, type, McdRelationDef.class);
+        }
+
+        @Override
+        void processRecord(EdigeoRecord r) {
+            switch (r.name) {
             case "FTC": nElements = safeGetInt(r); break;
             case "FTP": safeGet(r, elements); break;
@@ -244,27 +304,69 @@
     /**
      * Constructs a new {@code EdigeoFileVEC}.
+     * @param lot parent lot
+     * @param seId subset id
      * @param path path to VEC file
      * @throws IOException if any I/O error occurs
      */
-    public EdigeoFileVEC(Path path) throws IOException {
-        super(path);
+    public EdigeoFileVEC(Lot lot, String seId, Path path) throws IOException {
+        super(lot, seId, path);
+        register("PNO", NodeBlock.class);
+        register("PAR", ArcBlock.class);
+        register("PFE", FaceBlock.class);
+        register("FEA", ObjectBlock.class);
+        register("LNK", RelationBlock.class);
+        lot.vec.add(this);
     }
 
     @Override
-    protected Block createBlock(String type) {
-        switch (type) {
-        case "PNO":
-            return new NodeBlock(type);
-        case "PAR":
-            return new ArcBlock(type);
-        case "PFE":
-            return new FaceBlock(type);
-        case "FEA":
-            return new ObjectBlock(type);
-        case "LNK":
-            return new RelationBlock(type);
-        default:
-            throw new IllegalArgumentException(type);
-        }
+    public EdigeoFileVEC read(DataSet ds) throws IOException, ReflectiveOperationException {
+        super.read(ds);
+        for (NodeBlock nb : getNodes()) {
+            assert nb.getNumberOfAttributes() == 0;
+            assert nb.getNumberOfQualityIndicators() == 0;
+            Node n = new Node(nb.getCoordinate());
+            ds.addPrimitive(n);
+        }
+        return this;
+    }
+
+    /**
+     * Returns the list of node descriptors.
+     * @return the list of node descriptors
+     */
+    public final List<NodeBlock> getNodes() {
+        return Collections.unmodifiableList(blocks.getInstances(NodeBlock.class));
+    }
+
+    /**
+     * Returns the list of arc descriptors.
+     * @return the list of arc descriptors
+     */
+    public final List<ArcBlock> getArcs() {
+        return Collections.unmodifiableList(blocks.getInstances(ArcBlock.class));
+    }
+
+    /**
+     * Returns the list of face descriptors.
+     * @return the list of face descriptors
+     */
+    public final List<FaceBlock> getFaces() {
+        return Collections.unmodifiableList(blocks.getInstances(FaceBlock.class));
+    }
+
+    /**
+     * Returns the list of object descriptors.
+     * @return the list of object descriptors
+     */
+    public final List<ObjectBlock> getObjects() {
+        return Collections.unmodifiableList(blocks.getInstances(ObjectBlock.class));
+    }
+
+    /**
+     * Returns the list of relation descriptors.
+     * @return the list of relation descriptors
+     */
+    public final List<RelationBlock> getRelations() {
+        return Collections.unmodifiableList(blocks.getInstances(RelationBlock.class));
     }
 }
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoLotFile.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoLotFile.java	(revision 33649)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/EdigeoLotFile.java	(revision 33649)
@@ -0,0 +1,89 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.plugins.fr.cadastre.edigeo;
+
+import java.io.IOException;
+import java.nio.file.Path;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.ChildBlock;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.utils.ClassToInstancesMap;
+import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.utils.MutableClassToInstancesMap;
+
+/**
+ * An Egideo file belonging to a geographic lot.
+ * @param <B> superclass of all blocks defined in this file
+ */
+public abstract class EdigeoLotFile<B extends ChildBlock> extends EdigeoFile {
+
+    protected final Lot lot;
+    private final String subsetId;
+
+    private final Map<String, Class<? extends B>> classes = new HashMap<>();
+    protected final ClassToInstancesMap<B> blocks = new MutableClassToInstancesMap<>();
+
+    EdigeoLotFile(Lot lot, String subsetId, Path path) throws IOException {
+        super(path);
+        this.lot = Objects.requireNonNull(lot, "lot");
+        this.subsetId = Objects.requireNonNull(subsetId, "subsetId");
+    }
+
+    protected final void register(String key, Class<? extends B> klass) {
+        classes.put(key, klass);
+        blocks.putInstances(klass, new ArrayList<>());
+    }
+
+    @Override
+    protected final Block createBlock(String type) throws ReflectiveOperationException {
+        Class<? extends B> klass = classes.get(type);
+        return addBlock(blocks.get(klass), klass.getDeclaredConstructor(Lot.class, String.class).newInstance(lot, type));
+    }
+
+    /**
+     * Finds a descriptor by its identifier.
+     * @param values 4 values obtained from a {@link EdigeoRecord}:<ol>
+     * <li>Lot identifier</li>
+     * <li>subset identifier</li>
+     * <li>Descriptor type</li>
+     * <li>Descriptor identifier</li></ol>
+     * @param klass descriptor class
+     * @return found descriptor
+     */
+    public final B find(List<String> values) {
+        assert values.size() == 4 : values;
+        return find(values, classes.get(values.get(2)));
+    }
+
+    /**
+     * Finds a descriptor by its identifier.
+     * @param values 4 values obtained from a {@link EdigeoRecord}:<ol>
+     * <li>Lot identifier</li>
+     * <li>subset identifier</li>
+     * <li>Descriptor type</li>
+     * <li>Descriptor identifier</li></ol>
+     * @param klass descriptor class
+     * @return found descriptor
+     */
+    @SuppressWarnings("unchecked")
+    public final <T extends B> T find(List<String> values, Class<T> klass) {
+        assert values.size() == 4 : values;
+        assert values.get(0).equals(lot.identifier) : values;
+        assert values.get(1).equals(subsetId) : values;
+        assert klass.isAssignableFrom(classes.get(values.get(2))) : values;
+        List<T> list = blocks.getInstances(klass);
+        if (list == null) {
+            Class<? extends B> realClass = classes.get(values.get(2));
+            if (klass.isAssignableFrom(realClass)) {
+                list = (List<T>) blocks.getInstances(realClass);
+            } else {
+                throw new IllegalArgumentException(values + " / " + klass + " / " + realClass);
+            }
+        }
+        return list.stream().filter(x -> x.identifier.equals(values.get(3))).findAny().orElseThrow(
+                () -> new IllegalArgumentException(values + " / " + klass));
+    }
+}
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/pci/EdigeoPciReader.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/pci/EdigeoPciReader.java	(revision 33648)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/pci/EdigeoPciReader.java	(revision 33649)
@@ -12,12 +12,5 @@
 import org.openstreetmap.josm.io.AbstractReader;
 import org.openstreetmap.josm.io.IllegalDataException;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileDIC;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileGEN;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileGEO;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileQAL;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileSCD;
 import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileTHF.Lot;
-import org.openstreetmap.josm.plugins.fr.cadastre.edigeo.EdigeoFileVEC;
 
 /**
@@ -40,26 +33,15 @@
         } catch (IOException e) {
             throw e;
-        } catch (Throwable t) {
-            throw new IOException(t);
+        } catch (Exception | AssertionError e) {
+            throw new IOException(e);
         }
     }
 
-    DataSet parse(Path path, ProgressMonitor instance) throws IOException {
-        Path dir = path.getParent();
-        EdigeoFileTHF thf = new EdigeoFileTHF(path);
-        for (Lot lot : thf.getLots()) {
-            EdigeoFileGEN gen = new EdigeoFileGEN(dir.resolve(lot.getName()+lot.getGenDataName()+".GEN"));
-            EdigeoFileGEO geo = new EdigeoFileGEO(dir.resolve(lot.getName()+lot.getCoorRefName()+".GEO"));
-            EdigeoFileDIC dic = new EdigeoFileDIC(dir.resolve(lot.getName()+lot.getDictName()+".DIC"));
-            EdigeoFileSCD scd = new EdigeoFileSCD(dir.resolve(lot.getName()+lot.getScdName()+".SCD"));
-            EdigeoFileQAL qal = new EdigeoFileQAL(dir.resolve(lot.getName()+lot.getQualityName()+".QAL"));
-            for (int i = 0; i < lot.getNumberOfGeoData(); i++) {
-                EdigeoFileVEC vec = new EdigeoFileVEC(dir.resolve(lot.getName()+lot.getGeoDataName(i)+".VEC"));
-            }
-        }
-        DataSet ds = new DataSet();
-        ds.setName(thf.getSupport().getBlockIdentifier());
-        ds.setUploadPolicy(UploadPolicy.DISCOURAGED);
-        return ds;
+    DataSet parse(Path path, ProgressMonitor instance) throws IOException, ReflectiveOperationException {
+        DataSet data = new DataSet();
+        data.setUploadPolicy(UploadPolicy.DISCOURAGED);
+        EdigeoFileTHF thf = new EdigeoFileTHF(path).read(data);
+        data.setName(thf.getSupport().getBlockIdentifier());
+        return data;
     }
 
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/utils/ClassToInstancesMap.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/utils/ClassToInstancesMap.java	(revision 33649)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/utils/ClassToInstancesMap.java	(revision 33649)
@@ -0,0 +1,45 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.plugins.fr.cadastre.edigeo.utils;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * A map, each entry of which maps a Java raw type to a list of instances of that type.
+ * In addition to implementing {@code Map}, the additional type-safe operations
+ * {@link #putInstances}, {@link #addInstance} and {@link #getInstances} are available.
+ *
+ * Inspired from Guava's {@code ClassToInstanceMap}, but handling a list of instances.
+ *
+ * @param <B> the common supertype that all entries must share
+ */
+public interface ClassToInstancesMap<B> extends Map<Class<? extends B>, List<B>> {
+
+    /**
+     * Returns the values the specified class is mapped to, or {@code null} if no
+     * entry for this class is present. This will only return values that were
+     * bound to this specific class, not values that may have been bound to a subtype.
+     * @param type type
+     * @return the values the specified class is mapped to, or {@code null}
+     */
+    <T extends B> List<T> getInstances(Class<T> type);
+
+    /**
+     * Maps the specified class to the specified values. Does <i>not</i> associate
+     * these values with any of the class's supertypes.
+     * @param type type
+     * @param values new values
+     *
+     * @return the values previously associated with this class (possibly {@code
+     *     null}), or {@code null} if there was no previous entry.
+     */
+    <T extends B> List<T> putInstances(Class<T> type, List<T> values);
+
+    /**
+     * Adds a new value to the list mapped to the specified class.
+     * @param type type
+     * @param value value to add
+     * @return {@code true}
+     */
+    <T extends B> boolean addInstance(Class<T> type, T value);
+}
Index: /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/utils/MutableClassToInstancesMap.java
===================================================================
--- /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/utils/MutableClassToInstancesMap.java	(revision 33649)
+++ /applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/edigeo/utils/MutableClassToInstancesMap.java	(revision 33649)
@@ -0,0 +1,30 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.plugins.fr.cadastre.edigeo.utils;
+
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * A mutable class-to-instances map.
+ *
+ * @param <B> the common supertype that all entries must share
+ */
+public class MutableClassToInstancesMap<B> extends HashMap<Class<? extends B>, List<B>> implements ClassToInstancesMap<B> {
+
+    @Override
+    @SuppressWarnings("unchecked")
+    public <T extends B> List<T> getInstances(Class<T> type) {
+        return (List<T>) get(type);
+    }
+
+    @Override
+    @SuppressWarnings("unchecked")
+    public <T extends B> List<T> putInstances(Class<T> type, List<T> values) {
+        return (List<T>) put(type, (List<B>) values);
+    }
+
+    @Override
+    public <T extends B> boolean addInstance(Class<T> type, T value) {
+        return get(type).add(value);
+    }
+}
