json-ld
json-ld copied to clipboard
Restructure context types and add AggregateOffer
- Create new auto inherit structure for context attributes ($structure). Attributes in the $structure property are now automatically merged with all parent classes
- The setProperty() function has been renamed to makeProperty() and the actual setting of properties is now down inside the fill() function. This makes for easier unit testing in the future.
- The makeProperty() is also able to handle nested contexts better:
- If the $value contains @type, it will create a contact based on that type
- $property can now contain an array of classes defining what types of nexted context may be used for that attribute of the main context
- If $value hold and array of contexts, it will automatically make contexts for those. This was done in several context with a setter, these are now all obsolete and therefore removed
- The Music related contexts have be reorganised and the mutual attributes have been moved to MusicAbstractContext
- Restructure existing contexts and make the match the hierarchy of schema.org
- Add PHPUnit config for code coverage
- Add Json extension to the list of required packages
- Add AggregateOffer
Solving #70, #68, #63, #49 and #27 And probably also #62,
This also covers pull requests #67 and #64 making those obsolete