Model of the Model View Controller
Contains the classes for the
Class: Hierarchy
Goal: Get the whole hierarchy of Schema.org
Public function to obtain one schema
Parameters: | thing – string, name of the schema to retrieve |
---|---|
Returns: | schema |
Public function to obtain the hierarchy
Returns: | hierarchy- list |
---|
Class: SchemaClass
Goal: Get the properties and property types of a schema
Class method used before dump to reduce the size of the pickle file
Method called by the SchemaClassGenerator after finishing
Parameters: | s_gen – the SchemaClassGenerator or nothing |
---|
Class method to get all parents of one schema used by Schema bot to create the hierarchy
Returns: | list of lists |
---|
Method called by SchemaView.show_schema_properties
Returns: | html |
---|
Tries to get Schema from file
Otherwise, tries to get it from Internet
Parameters: | b_immediate – Optional, if True will force join() on the Thread |
---|
Class: SchemaClassGenerator
Goal: Get the markup of a schema thread-safe. This class can be started concurrently by the Schema bot
Start the thread
Get the schema markup from the Internet
Call the SchemaClass back when done