equal
deleted
inserted
replaced
17 def __init__(self, *args, **kwargs): |
17 def __init__(self, *args, **kwargs): |
18 "Initializes a Geometry Collection from a sequence of Geometry objects." |
18 "Initializes a Geometry Collection from a sequence of Geometry objects." |
19 |
19 |
20 # Checking the arguments |
20 # Checking the arguments |
21 if not args: |
21 if not args: |
22 raise TypeError, 'Must provide at least one Geometry to initialize %s.' % self.__class__.__name__ |
22 raise TypeError('Must provide at least one Geometry to initialize %s.' % self.__class__.__name__) |
23 |
23 |
24 if len(args) == 1: |
24 if len(args) == 1: |
25 # If only one geometry provided or a list of geometries is provided |
25 # If only one geometry provided or a list of geometries is provided |
26 # in the first argument. |
26 # in the first argument. |
27 if isinstance(args[0], (tuple, list)): |
27 if isinstance(args[0], (tuple, list)): |