pysmartdatamodels code example

from pysmartdatamodels import pysmartdatamodels as sdm
subject = "dataModel.Weather"
dataModel = "WeatherForecast"
attribute = "precipitation"
print(sdm.load_all_datamodels())
print(len(sdm.load_all_attributes())) # there is more than 19.000 to get all listed
print(sdm.list_all_datamodels())
print(sdm.list_all_subjects())
print(sdm.datamodels_subject("dataModel.Weather"))
print(sdm.description_attribute(subject, dataModel, attribute))
print(sdm.datatype_attribute(subject, dataModel, attribute))
print(sdm.model_attribute(subject, dataModel, attribute))
print(sdm.units_attribute(subject, dataModel, attribute))
print(sdm.attributes_datamodel(subject, dataModel))
print(sdm.subject_repolink(subject))
print(sdm.datamodel_repolink(dataModel))
print(sdm.print_datamodel(subject, dataModel, ",", [ "property", "type", "dataModel", "repoName", "description", "typeNGSI", "modelTags", "format", "units", "model", ]))
sdm.update_data()

Comments are closed.