Skip to content

Instantly share code, notes, and snippets.

@Avilocap
Last active July 14, 2019 11:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Avilocap/152f1af8aaf67760d42291f9e3f2893e to your computer and use it in GitHub Desktop.
Save Avilocap/152f1af8aaf67760d42291f9e3f2893e to your computer and use it in GitHub Desktop.
Fichero Python - Leer un JSON con Python - Daviddelatorre.me
import json
f = open("Entities.json", "r")
content = f.read()
jsondecoded = json.loads(content)
for entity in jsondecoded["Classes"]:
print("Entidad " + entity["Name"] + ". Sus propiedades son: ")
for entityProperty in entity["Properties"]:
print("Propiedad " + entityProperty["Name"] + " de tipo " + entityProperty["Type"])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment