def __init__(self, latitude, longitude, **attributes): """Contruct a Bridges object. latitude a vector (tuple, list, ...) of latitude values longitude a vector (tuple, list, ...) of longitude values attributes a dictionary of bridge attributes """ Sites.__init__(self, latitude, longitude, **attributes)
def __init__(self, latitude, longitude, vulnerability_set, **attributes): """Create an object holding all Structures data for user defined vulnerability curves """ # inherit setup from Sites, add building parameters Sites.__init__(self, latitude, longitude, **attributes) self.vulnerability_set = vulnerability_set # Validate that the curves match this set self.validate_vulnerability_set()
def __init__(self, latitude, longitude, building_parameters, **attributes): """Create an object holding all Structures data. Inherits from Sites which handles lat, lon and attributes. Structures adds the 'building_parameters' attribute which must be handled specially. Compare this with the handling of 'extra' classification data in the Bridges class. TODO: make extra data here be handled in a similar way as in Bridges? """ # inherit setup from Sites, add building parameters Sites.__init__(self, latitude, longitude, **attributes) self.building_parameters = building_parameters