dna: Add LandmarkBuilding loading.
This commit is contained in:
parent
caf2ba6106
commit
d7c25ea163
2 changed files with 6 additions and 2 deletions
|
@ -13,6 +13,9 @@ class DNALandmarkBuilding(DNAGroup):
|
|||
self.type = type
|
||||
|
||||
def _makeNode(self, storage, parent):
|
||||
pass # TODO
|
||||
node = storage.findNode(self.code)
|
||||
if node is None:
|
||||
raise DNAError('DNALandmarkBuilding uses unknown code %s' % self.code)
|
||||
return node.copyTo(parent)
|
||||
|
||||
registerElement(DNALandmarkBuilding)
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
import xml.sax
|
||||
|
||||
class DNAParseError(Exception): pass
|
||||
class DNAError(Exception): pass
|
||||
class DNAParseError(DNAError): pass
|
||||
|
||||
elementRegistry = {}
|
||||
def registerElement(element):
|
||||
|
|
Loading…
Reference in a new issue