Beispiel #1
0
 public EntityCreator(Transaction trans,
                      string blockname,
                      string layername)
 {
     _trans      = trans;
     _blocktable = Active.BlockTableForRead(_trans);
     _modelspace = Active.ModelSpaceForWrite(_trans);
     if (!_blocktable.Has(blockname))
     {
         throw new ArgumentException(
                   "Error while constructing new EntityCreator: No Block named " +
                   $"\"{blockname}\" found in provided blocktable.");
     }
     _blockname = blockname;
     Active.CreateLayerIFNonExisting(layername);
     _layername = layername;
 }