Layer revisions¶
Layer revisions¶
1# This example displays the various properties
2# of a database layer revisions object.
3
4# Get the output tool box and clear it.
5otb = impact.gui.output_toolbox
6otb.clear()
7
8# Get the database item of the current active drawing.
9databaseitem = impact.active_drawing.databaseitem
10
11# For each of the database layers within the database item
12# display the layer name along with total number of revisions
13# and then the number of revisions which contain geometry changes.
14for layer in databaseitem.layers:
15 otb.add("Layer: " + str(layer.name))
16 otb.add("Revision Count: " + str(layer.revisions.count))
17 otb.add("Revisions with geometry: " + str(layer.revisions.geometry_revision_count))
18 otb.add("")