@@ -24,146 +24,146 @@ |
||
24 | 24 | */ |
25 | 25 | class FindAction extends MetaJsonLd implements FindActionInterface, ActionInterface, ThingInterface |
26 | 26 | { |
27 | - use FindActionTrait; |
|
28 | - use ActionTrait; |
|
29 | - use ThingTrait; |
|
30 | - |
|
31 | - /** |
|
32 | - * The Schema.org Type Name |
|
33 | - * |
|
34 | - * @var string |
|
35 | - */ |
|
36 | - public static string $schemaTypeName = 'FindAction'; |
|
37 | - |
|
38 | - /** |
|
39 | - * The Schema.org Type Scope |
|
40 | - * |
|
41 | - * @var string |
|
42 | - */ |
|
43 | - public static string $schemaTypeScope = 'https://schema.org/FindAction'; |
|
44 | - |
|
45 | - /** |
|
46 | - * The Schema.org Type Extends |
|
47 | - * |
|
48 | - * @var string |
|
49 | - */ |
|
50 | - public static string $schemaTypeExtends = 'Action'; |
|
51 | - |
|
52 | - /** |
|
53 | - * The Schema.org Type Description |
|
54 | - * |
|
55 | - * @var string |
|
56 | - */ |
|
57 | - public static string $schemaTypeDescription = 'The act of finding an object.\n\nRelated actions:\n\n* [[SearchAction]]: FindAction is generally lead by a SearchAction, but not necessarily.'; |
|
58 | - |
|
59 | - |
|
60 | - /** |
|
61 | - * @inheritdoc |
|
62 | - */ |
|
63 | - public function getSchemaPropertyNames(): array |
|
64 | - { |
|
65 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
66 | - } |
|
67 | - |
|
68 | - |
|
69 | - /** |
|
70 | - * @inheritdoc |
|
71 | - */ |
|
72 | - public function getSchemaPropertyExpectedTypes(): array |
|
73 | - { |
|
74 | - return [ |
|
75 | - 'actionStatus' => ['ActionStatusType'], |
|
76 | - 'additionalType' => ['URL'], |
|
77 | - 'agent' => ['Organization', 'Person'], |
|
78 | - 'alternateName' => ['Text'], |
|
79 | - 'description' => ['Text'], |
|
80 | - 'disambiguatingDescription' => ['Text'], |
|
81 | - 'endTime' => ['DateTime', 'Time'], |
|
82 | - 'error' => ['Thing'], |
|
83 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
84 | - 'image' => ['URL', 'ImageObject'], |
|
85 | - 'instrument' => ['Thing'], |
|
86 | - 'location' => ['Place', 'Text', 'VirtualLocation', 'PostalAddress'], |
|
87 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
88 | - 'name' => ['Text'], |
|
89 | - 'object' => ['Thing'], |
|
90 | - 'participant' => ['Organization', 'Person'], |
|
91 | - 'potentialAction' => ['Action'], |
|
92 | - 'provider' => ['Organization', 'Person'], |
|
93 | - 'result' => ['Thing'], |
|
94 | - 'sameAs' => ['URL'], |
|
95 | - 'startTime' => ['Time', 'DateTime'], |
|
96 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
97 | - 'target' => ['URL', 'EntryPoint'], |
|
98 | - 'url' => ['URL'] |
|
99 | - ]; |
|
100 | - } |
|
101 | - |
|
102 | - |
|
103 | - /** |
|
104 | - * @inheritdoc |
|
105 | - */ |
|
106 | - public function getSchemaPropertyDescriptions(): array |
|
107 | - { |
|
108 | - return [ |
|
109 | - 'actionStatus' => 'Indicates the current disposition of the Action.', |
|
110 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
111 | - 'agent' => 'The direct performer or driver of the action (animate or inanimate). E.g. *John* wrote a book.', |
|
112 | - 'alternateName' => 'An alias for the item.', |
|
113 | - 'description' => 'A description of the item.', |
|
114 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
115 | - 'endTime' => 'The endTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to end. For actions that span a period of time, when the action was performed. E.g. John wrote a book from January to *December*. For media, including audio and video, it\'s the time offset of the end of a clip within a larger file. Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.', |
|
116 | - 'error' => 'For failed actions, more information on the cause of the failure.', |
|
117 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
118 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
119 | - 'instrument' => 'The object that helped the agent perform the action. E.g. John wrote a book with *a pen*.', |
|
120 | - 'location' => 'The location of, for example, where an event is happening, where an organization is located, or where an action takes place.', |
|
121 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
122 | - 'name' => 'The name of the item.', |
|
123 | - 'object' => 'The object upon which the action is carried out, whose state is kept intact or changed. Also known as the semantic roles patient, affected or undergoer (which change their state) or theme (which doesn\'t). E.g. John read *a book*.', |
|
124 | - 'participant' => 'Other co-agents that participated in the action indirectly. E.g. John wrote a book with *Steve*.', |
|
125 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
126 | - 'provider' => 'The service provider, service operator, or service performer; the goods producer. Another party (a seller) may offer those services or goods on behalf of the provider. A provider may also serve as the seller.', |
|
127 | - 'result' => 'The result produced in the action. E.g. John wrote *a book*.', |
|
128 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
129 | - 'startTime' => 'The startTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to start. For actions that span a period of time, when the action was performed. E.g. John wrote a book from *January* to December. For media, including audio and video, it\'s the time offset of the start of a clip within a larger file. Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.', |
|
130 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
131 | - 'target' => 'Indicates a target EntryPoint, or url, for an Action.', |
|
132 | - 'url' => 'URL of the item.' |
|
133 | - ]; |
|
134 | - } |
|
135 | - |
|
136 | - |
|
137 | - /** |
|
138 | - * @inheritdoc |
|
139 | - */ |
|
140 | - public function getGoogleRequiredSchema(): array |
|
141 | - { |
|
142 | - return ['description', 'name']; |
|
143 | - } |
|
144 | - |
|
145 | - |
|
146 | - /** |
|
147 | - * @inheritdoc |
|
148 | - */ |
|
149 | - public function getGoogleRecommendedSchema(): array |
|
150 | - { |
|
151 | - return ['image', 'url']; |
|
152 | - } |
|
153 | - |
|
154 | - |
|
155 | - /** |
|
156 | - * @inheritdoc |
|
157 | - */ |
|
158 | - public function defineRules(): array |
|
159 | - { |
|
160 | - $rules = parent::defineRules(); |
|
161 | - $rules = array_merge($rules, [ |
|
162 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
163 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
164 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
165 | - ]); |
|
166 | - |
|
167 | - return $rules; |
|
168 | - } |
|
27 | + use FindActionTrait; |
|
28 | + use ActionTrait; |
|
29 | + use ThingTrait; |
|
30 | + |
|
31 | + /** |
|
32 | + * The Schema.org Type Name |
|
33 | + * |
|
34 | + * @var string |
|
35 | + */ |
|
36 | + public static string $schemaTypeName = 'FindAction'; |
|
37 | + |
|
38 | + /** |
|
39 | + * The Schema.org Type Scope |
|
40 | + * |
|
41 | + * @var string |
|
42 | + */ |
|
43 | + public static string $schemaTypeScope = 'https://schema.org/FindAction'; |
|
44 | + |
|
45 | + /** |
|
46 | + * The Schema.org Type Extends |
|
47 | + * |
|
48 | + * @var string |
|
49 | + */ |
|
50 | + public static string $schemaTypeExtends = 'Action'; |
|
51 | + |
|
52 | + /** |
|
53 | + * The Schema.org Type Description |
|
54 | + * |
|
55 | + * @var string |
|
56 | + */ |
|
57 | + public static string $schemaTypeDescription = 'The act of finding an object.\n\nRelated actions:\n\n* [[SearchAction]]: FindAction is generally lead by a SearchAction, but not necessarily.'; |
|
58 | + |
|
59 | + |
|
60 | + /** |
|
61 | + * @inheritdoc |
|
62 | + */ |
|
63 | + public function getSchemaPropertyNames(): array |
|
64 | + { |
|
65 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
66 | + } |
|
67 | + |
|
68 | + |
|
69 | + /** |
|
70 | + * @inheritdoc |
|
71 | + */ |
|
72 | + public function getSchemaPropertyExpectedTypes(): array |
|
73 | + { |
|
74 | + return [ |
|
75 | + 'actionStatus' => ['ActionStatusType'], |
|
76 | + 'additionalType' => ['URL'], |
|
77 | + 'agent' => ['Organization', 'Person'], |
|
78 | + 'alternateName' => ['Text'], |
|
79 | + 'description' => ['Text'], |
|
80 | + 'disambiguatingDescription' => ['Text'], |
|
81 | + 'endTime' => ['DateTime', 'Time'], |
|
82 | + 'error' => ['Thing'], |
|
83 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
84 | + 'image' => ['URL', 'ImageObject'], |
|
85 | + 'instrument' => ['Thing'], |
|
86 | + 'location' => ['Place', 'Text', 'VirtualLocation', 'PostalAddress'], |
|
87 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
88 | + 'name' => ['Text'], |
|
89 | + 'object' => ['Thing'], |
|
90 | + 'participant' => ['Organization', 'Person'], |
|
91 | + 'potentialAction' => ['Action'], |
|
92 | + 'provider' => ['Organization', 'Person'], |
|
93 | + 'result' => ['Thing'], |
|
94 | + 'sameAs' => ['URL'], |
|
95 | + 'startTime' => ['Time', 'DateTime'], |
|
96 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
97 | + 'target' => ['URL', 'EntryPoint'], |
|
98 | + 'url' => ['URL'] |
|
99 | + ]; |
|
100 | + } |
|
101 | + |
|
102 | + |
|
103 | + /** |
|
104 | + * @inheritdoc |
|
105 | + */ |
|
106 | + public function getSchemaPropertyDescriptions(): array |
|
107 | + { |
|
108 | + return [ |
|
109 | + 'actionStatus' => 'Indicates the current disposition of the Action.', |
|
110 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
111 | + 'agent' => 'The direct performer or driver of the action (animate or inanimate). E.g. *John* wrote a book.', |
|
112 | + 'alternateName' => 'An alias for the item.', |
|
113 | + 'description' => 'A description of the item.', |
|
114 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
115 | + 'endTime' => 'The endTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to end. For actions that span a period of time, when the action was performed. E.g. John wrote a book from January to *December*. For media, including audio and video, it\'s the time offset of the end of a clip within a larger file. Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.', |
|
116 | + 'error' => 'For failed actions, more information on the cause of the failure.', |
|
117 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
118 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
119 | + 'instrument' => 'The object that helped the agent perform the action. E.g. John wrote a book with *a pen*.', |
|
120 | + 'location' => 'The location of, for example, where an event is happening, where an organization is located, or where an action takes place.', |
|
121 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
122 | + 'name' => 'The name of the item.', |
|
123 | + 'object' => 'The object upon which the action is carried out, whose state is kept intact or changed. Also known as the semantic roles patient, affected or undergoer (which change their state) or theme (which doesn\'t). E.g. John read *a book*.', |
|
124 | + 'participant' => 'Other co-agents that participated in the action indirectly. E.g. John wrote a book with *Steve*.', |
|
125 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
126 | + 'provider' => 'The service provider, service operator, or service performer; the goods producer. Another party (a seller) may offer those services or goods on behalf of the provider. A provider may also serve as the seller.', |
|
127 | + 'result' => 'The result produced in the action. E.g. John wrote *a book*.', |
|
128 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
129 | + 'startTime' => 'The startTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to start. For actions that span a period of time, when the action was performed. E.g. John wrote a book from *January* to December. For media, including audio and video, it\'s the time offset of the start of a clip within a larger file. Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.', |
|
130 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
131 | + 'target' => 'Indicates a target EntryPoint, or url, for an Action.', |
|
132 | + 'url' => 'URL of the item.' |
|
133 | + ]; |
|
134 | + } |
|
135 | + |
|
136 | + |
|
137 | + /** |
|
138 | + * @inheritdoc |
|
139 | + */ |
|
140 | + public function getGoogleRequiredSchema(): array |
|
141 | + { |
|
142 | + return ['description', 'name']; |
|
143 | + } |
|
144 | + |
|
145 | + |
|
146 | + /** |
|
147 | + * @inheritdoc |
|
148 | + */ |
|
149 | + public function getGoogleRecommendedSchema(): array |
|
150 | + { |
|
151 | + return ['image', 'url']; |
|
152 | + } |
|
153 | + |
|
154 | + |
|
155 | + /** |
|
156 | + * @inheritdoc |
|
157 | + */ |
|
158 | + public function defineRules(): array |
|
159 | + { |
|
160 | + $rules = parent::defineRules(); |
|
161 | + $rules = array_merge($rules, [ |
|
162 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
163 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
164 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
165 | + ]); |
|
166 | + |
|
167 | + return $rules; |
|
168 | + } |
|
169 | 169 | } |
@@ -25,205 +25,205 @@ |
||
25 | 25 | */ |
26 | 26 | class UserLikes extends MetaJsonLd implements UserLikesInterface, UserInteractionInterface, EventInterface, ThingInterface |
27 | 27 | { |
28 | - use UserLikesTrait; |
|
29 | - use UserInteractionTrait; |
|
30 | - use EventTrait; |
|
31 | - use ThingTrait; |
|
32 | - |
|
33 | - /** |
|
34 | - * The Schema.org Type Name |
|
35 | - * |
|
36 | - * @var string |
|
37 | - */ |
|
38 | - public static string $schemaTypeName = 'UserLikes'; |
|
39 | - |
|
40 | - /** |
|
41 | - * The Schema.org Type Scope |
|
42 | - * |
|
43 | - * @var string |
|
44 | - */ |
|
45 | - public static string $schemaTypeScope = 'https://schema.org/UserLikes'; |
|
46 | - |
|
47 | - /** |
|
48 | - * The Schema.org Type Extends |
|
49 | - * |
|
50 | - * @var string |
|
51 | - */ |
|
52 | - public static string $schemaTypeExtends = 'UserInteraction'; |
|
53 | - |
|
54 | - /** |
|
55 | - * The Schema.org Type Description |
|
56 | - * |
|
57 | - * @var string |
|
58 | - */ |
|
59 | - public static string $schemaTypeDescription = 'UserInteraction and its subtypes is an old way of talking about users interacting with pages. It is generally better to use [[Action]]-based vocabulary, alongside types such as [[Comment]].'; |
|
60 | - |
|
61 | - |
|
62 | - /** |
|
63 | - * @inheritdoc |
|
64 | - */ |
|
65 | - public function getSchemaPropertyNames(): array |
|
66 | - { |
|
67 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
68 | - } |
|
69 | - |
|
70 | - |
|
71 | - /** |
|
72 | - * @inheritdoc |
|
73 | - */ |
|
74 | - public function getSchemaPropertyExpectedTypes(): array |
|
75 | - { |
|
76 | - return [ |
|
77 | - 'about' => ['Thing'], |
|
78 | - 'actor' => ['Person'], |
|
79 | - 'additionalType' => ['URL'], |
|
80 | - 'aggregateRating' => ['AggregateRating'], |
|
81 | - 'alternateName' => ['Text'], |
|
82 | - 'attendee' => ['Organization', 'Person'], |
|
83 | - 'attendees' => ['Organization', 'Person'], |
|
84 | - 'audience' => ['Audience'], |
|
85 | - 'composer' => ['Organization', 'Person'], |
|
86 | - 'contributor' => ['Organization', 'Person'], |
|
87 | - 'description' => ['Text'], |
|
88 | - 'director' => ['Person'], |
|
89 | - 'disambiguatingDescription' => ['Text'], |
|
90 | - 'doorTime' => ['Time', 'DateTime'], |
|
91 | - 'duration' => ['Duration'], |
|
92 | - 'endDate' => ['DateTime', 'Date'], |
|
93 | - 'eventAttendanceMode' => ['EventAttendanceModeEnumeration'], |
|
94 | - 'eventSchedule' => ['Schedule'], |
|
95 | - 'eventStatus' => ['EventStatusType'], |
|
96 | - 'funder' => ['Organization', 'Person'], |
|
97 | - 'funding' => ['Grant'], |
|
98 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
99 | - 'image' => ['URL', 'ImageObject'], |
|
100 | - 'inLanguage' => ['Text', 'Language'], |
|
101 | - 'isAccessibleForFree' => ['Boolean'], |
|
102 | - 'keywords' => ['URL', 'DefinedTerm', 'Text'], |
|
103 | - 'location' => ['Place', 'Text', 'VirtualLocation', 'PostalAddress'], |
|
104 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
105 | - 'maximumAttendeeCapacity' => ['Integer'], |
|
106 | - 'maximumPhysicalAttendeeCapacity' => ['Integer'], |
|
107 | - 'maximumVirtualAttendeeCapacity' => ['Integer'], |
|
108 | - 'name' => ['Text'], |
|
109 | - 'offers' => ['Demand', 'Offer'], |
|
110 | - 'organizer' => ['Organization', 'Person'], |
|
111 | - 'performer' => ['Person', 'Organization'], |
|
112 | - 'performers' => ['Person', 'Organization'], |
|
113 | - 'potentialAction' => ['Action'], |
|
114 | - 'previousStartDate' => ['Date'], |
|
115 | - 'recordedIn' => ['CreativeWork'], |
|
116 | - 'remainingAttendeeCapacity' => ['Integer'], |
|
117 | - 'review' => ['Review'], |
|
118 | - 'sameAs' => ['URL'], |
|
119 | - 'sponsor' => ['Organization', 'Person'], |
|
120 | - 'startDate' => ['DateTime', 'Date'], |
|
121 | - 'subEvent' => ['Event'], |
|
122 | - 'subEvents' => ['Event'], |
|
123 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
124 | - 'superEvent' => ['Event'], |
|
125 | - 'translator' => ['Organization', 'Person'], |
|
126 | - 'typicalAgeRange' => ['Text'], |
|
127 | - 'url' => ['URL'], |
|
128 | - 'workFeatured' => ['CreativeWork'], |
|
129 | - 'workPerformed' => ['CreativeWork'] |
|
130 | - ]; |
|
131 | - } |
|
132 | - |
|
133 | - |
|
134 | - /** |
|
135 | - * @inheritdoc |
|
136 | - */ |
|
137 | - public function getSchemaPropertyDescriptions(): array |
|
138 | - { |
|
139 | - return [ |
|
140 | - 'about' => 'The subject matter of the content.', |
|
141 | - 'actor' => 'An actor, e.g. in TV, radio, movie, video games etc., or in an event. Actors can be associated with individual items or with a series, episode, clip.', |
|
142 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
143 | - 'aggregateRating' => 'The overall rating, based on a collection of reviews or ratings, of the item.', |
|
144 | - 'alternateName' => 'An alias for the item.', |
|
145 | - 'attendee' => 'A person or organization attending the event.', |
|
146 | - 'attendees' => 'A person attending the event.', |
|
147 | - 'audience' => 'An intended audience, i.e. a group for whom something was created.', |
|
148 | - 'composer' => 'The person or organization who wrote a composition, or who is the composer of a work performed at some event.', |
|
149 | - 'contributor' => 'A secondary contributor to the CreativeWork or Event.', |
|
150 | - 'description' => 'A description of the item.', |
|
151 | - 'director' => 'A director of e.g. TV, radio, movie, video gaming etc. content, or of an event. Directors can be associated with individual items or with a series, episode, clip.', |
|
152 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
153 | - 'doorTime' => 'The time admission will commence.', |
|
154 | - 'duration' => 'The duration of the item (movie, audio recording, event, etc.) in [ISO 8601 date format](http://en.wikipedia.org/wiki/ISO_8601).', |
|
155 | - 'endDate' => 'The end date and time of the item (in [ISO 8601 date format](http://en.wikipedia.org/wiki/ISO_8601)).', |
|
156 | - 'eventAttendanceMode' => 'The eventAttendanceMode of an event indicates whether it occurs online, offline, or a mix.', |
|
157 | - 'eventSchedule' => 'Associates an [[Event]] with a [[Schedule]]. There are circumstances where it is preferable to share a schedule for a series of repeating events rather than data on the individual events themselves. For example, a website or application might prefer to publish a schedule for a weekly gym class rather than provide data on every event. A schedule could be processed by applications to add forthcoming events to a calendar. An [[Event]] that is associated with a [[Schedule]] using this property should not have [[startDate]] or [[endDate]] properties. These are instead defined within the associated [[Schedule]], this avoids any ambiguity for clients using the data. The property might have repeated values to specify different schedules, e.g. for different months or seasons.', |
|
158 | - 'eventStatus' => 'An eventStatus of an event represents its status; particularly useful when an event is cancelled or rescheduled.', |
|
159 | - 'funder' => 'A person or organization that supports (sponsors) something through some kind of financial contribution.', |
|
160 | - 'funding' => 'A [[Grant]] that directly or indirectly provide funding or sponsorship for this item. See also [[ownershipFundingInfo]].', |
|
161 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
162 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
163 | - 'inLanguage' => 'The language of the content or performance or used in an action. Please use one of the language codes from the [IETF BCP 47 standard](http://tools.ietf.org/html/bcp47). See also [[availableLanguage]].', |
|
164 | - 'isAccessibleForFree' => 'A flag to signal that the item, event, or place is accessible for free.', |
|
165 | - 'keywords' => 'Keywords or tags used to describe some item. Multiple textual entries in a keywords list are typically delimited by commas, or by repeating the property.', |
|
166 | - 'location' => 'The location of, for example, where an event is happening, where an organization is located, or where an action takes place.', |
|
167 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
168 | - 'maximumAttendeeCapacity' => 'The total number of individuals that may attend an event or venue.', |
|
169 | - 'maximumPhysicalAttendeeCapacity' => 'The maximum physical attendee capacity of an [[Event]] whose [[eventAttendanceMode]] is [[OfflineEventAttendanceMode]] (or the offline aspects, in the case of a [[MixedEventAttendanceMode]]). ', |
|
170 | - 'maximumVirtualAttendeeCapacity' => 'The maximum physical attendee capacity of an [[Event]] whose [[eventAttendanceMode]] is [[OnlineEventAttendanceMode]] (or the online aspects, in the case of a [[MixedEventAttendanceMode]]). ', |
|
171 | - 'name' => 'The name of the item.', |
|
172 | - 'offers' => 'An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event. Use [[businessFunction]] to indicate the kind of transaction offered, i.e. sell, lease, etc. This property can also be used to describe a [[Demand]]. While this property is listed as expected on a number of common types, it can be used in others. In that case, using a second type, such as Product or a subtype of Product, can clarify the nature of the offer. ', |
|
173 | - 'organizer' => 'An organizer of an Event.', |
|
174 | - 'performer' => 'A performer at the event—for example, a presenter, musician, musical group or actor.', |
|
175 | - 'performers' => 'The main performer or performers of the event—for example, a presenter, musician, or actor.', |
|
176 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
177 | - 'previousStartDate' => 'Used in conjunction with eventStatus for rescheduled or cancelled events. This property contains the previously scheduled start date. For rescheduled events, the startDate property should be used for the newly scheduled start date. In the (rare) case of an event that has been postponed and rescheduled multiple times, this field may be repeated.', |
|
178 | - 'recordedIn' => 'The CreativeWork that captured all or part of this Event.', |
|
179 | - 'remainingAttendeeCapacity' => 'The number of attendee places for an event that remain unallocated.', |
|
180 | - 'review' => 'A review of the item.', |
|
181 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
182 | - 'sponsor' => 'A person or organization that supports a thing through a pledge, promise, or financial contribution. E.g. a sponsor of a Medical Study or a corporate sponsor of an event.', |
|
183 | - 'startDate' => 'The start date and time of the item (in [ISO 8601 date format](http://en.wikipedia.org/wiki/ISO_8601)).', |
|
184 | - 'subEvent' => 'An Event that is part of this event. For example, a conference event includes many presentations, each of which is a subEvent of the conference.', |
|
185 | - 'subEvents' => 'Events that are a part of this event. For example, a conference event includes many presentations, each subEvents of the conference.', |
|
186 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
187 | - 'superEvent' => 'An event that this event is a part of. For example, a collection of individual music performances might each have a music festival as their superEvent.', |
|
188 | - 'translator' => 'Organization or person who adapts a creative work to different languages, regional differences and technical requirements of a target market, or that translates during some event.', |
|
189 | - 'typicalAgeRange' => 'The typical expected age range, e.g. \'7-9\', \'11-\'.', |
|
190 | - 'url' => 'URL of the item.', |
|
191 | - 'workFeatured' => 'A work featured in some event, e.g. exhibited in an ExhibitionEvent. Specific subproperties are available for workPerformed (e.g. a play), or a workPresented (a Movie at a ScreeningEvent).', |
|
192 | - 'workPerformed' => 'A work performed in some event, for example a play performed in a TheaterEvent.' |
|
193 | - ]; |
|
194 | - } |
|
195 | - |
|
196 | - |
|
197 | - /** |
|
198 | - * @inheritdoc |
|
199 | - */ |
|
200 | - public function getGoogleRequiredSchema(): array |
|
201 | - { |
|
202 | - return ['description', 'name']; |
|
203 | - } |
|
204 | - |
|
205 | - |
|
206 | - /** |
|
207 | - * @inheritdoc |
|
208 | - */ |
|
209 | - public function getGoogleRecommendedSchema(): array |
|
210 | - { |
|
211 | - return ['image', 'url']; |
|
212 | - } |
|
213 | - |
|
214 | - |
|
215 | - /** |
|
216 | - * @inheritdoc |
|
217 | - */ |
|
218 | - public function defineRules(): array |
|
219 | - { |
|
220 | - $rules = parent::defineRules(); |
|
221 | - $rules = array_merge($rules, [ |
|
222 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
223 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
224 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
225 | - ]); |
|
226 | - |
|
227 | - return $rules; |
|
228 | - } |
|
28 | + use UserLikesTrait; |
|
29 | + use UserInteractionTrait; |
|
30 | + use EventTrait; |
|
31 | + use ThingTrait; |
|
32 | + |
|
33 | + /** |
|
34 | + * The Schema.org Type Name |
|
35 | + * |
|
36 | + * @var string |
|
37 | + */ |
|
38 | + public static string $schemaTypeName = 'UserLikes'; |
|
39 | + |
|
40 | + /** |
|
41 | + * The Schema.org Type Scope |
|
42 | + * |
|
43 | + * @var string |
|
44 | + */ |
|
45 | + public static string $schemaTypeScope = 'https://schema.org/UserLikes'; |
|
46 | + |
|
47 | + /** |
|
48 | + * The Schema.org Type Extends |
|
49 | + * |
|
50 | + * @var string |
|
51 | + */ |
|
52 | + public static string $schemaTypeExtends = 'UserInteraction'; |
|
53 | + |
|
54 | + /** |
|
55 | + * The Schema.org Type Description |
|
56 | + * |
|
57 | + * @var string |
|
58 | + */ |
|
59 | + public static string $schemaTypeDescription = 'UserInteraction and its subtypes is an old way of talking about users interacting with pages. It is generally better to use [[Action]]-based vocabulary, alongside types such as [[Comment]].'; |
|
60 | + |
|
61 | + |
|
62 | + /** |
|
63 | + * @inheritdoc |
|
64 | + */ |
|
65 | + public function getSchemaPropertyNames(): array |
|
66 | + { |
|
67 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
68 | + } |
|
69 | + |
|
70 | + |
|
71 | + /** |
|
72 | + * @inheritdoc |
|
73 | + */ |
|
74 | + public function getSchemaPropertyExpectedTypes(): array |
|
75 | + { |
|
76 | + return [ |
|
77 | + 'about' => ['Thing'], |
|
78 | + 'actor' => ['Person'], |
|
79 | + 'additionalType' => ['URL'], |
|
80 | + 'aggregateRating' => ['AggregateRating'], |
|
81 | + 'alternateName' => ['Text'], |
|
82 | + 'attendee' => ['Organization', 'Person'], |
|
83 | + 'attendees' => ['Organization', 'Person'], |
|
84 | + 'audience' => ['Audience'], |
|
85 | + 'composer' => ['Organization', 'Person'], |
|
86 | + 'contributor' => ['Organization', 'Person'], |
|
87 | + 'description' => ['Text'], |
|
88 | + 'director' => ['Person'], |
|
89 | + 'disambiguatingDescription' => ['Text'], |
|
90 | + 'doorTime' => ['Time', 'DateTime'], |
|
91 | + 'duration' => ['Duration'], |
|
92 | + 'endDate' => ['DateTime', 'Date'], |
|
93 | + 'eventAttendanceMode' => ['EventAttendanceModeEnumeration'], |
|
94 | + 'eventSchedule' => ['Schedule'], |
|
95 | + 'eventStatus' => ['EventStatusType'], |
|
96 | + 'funder' => ['Organization', 'Person'], |
|
97 | + 'funding' => ['Grant'], |
|
98 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
99 | + 'image' => ['URL', 'ImageObject'], |
|
100 | + 'inLanguage' => ['Text', 'Language'], |
|
101 | + 'isAccessibleForFree' => ['Boolean'], |
|
102 | + 'keywords' => ['URL', 'DefinedTerm', 'Text'], |
|
103 | + 'location' => ['Place', 'Text', 'VirtualLocation', 'PostalAddress'], |
|
104 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
105 | + 'maximumAttendeeCapacity' => ['Integer'], |
|
106 | + 'maximumPhysicalAttendeeCapacity' => ['Integer'], |
|
107 | + 'maximumVirtualAttendeeCapacity' => ['Integer'], |
|
108 | + 'name' => ['Text'], |
|
109 | + 'offers' => ['Demand', 'Offer'], |
|
110 | + 'organizer' => ['Organization', 'Person'], |
|
111 | + 'performer' => ['Person', 'Organization'], |
|
112 | + 'performers' => ['Person', 'Organization'], |
|
113 | + 'potentialAction' => ['Action'], |
|
114 | + 'previousStartDate' => ['Date'], |
|
115 | + 'recordedIn' => ['CreativeWork'], |
|
116 | + 'remainingAttendeeCapacity' => ['Integer'], |
|
117 | + 'review' => ['Review'], |
|
118 | + 'sameAs' => ['URL'], |
|
119 | + 'sponsor' => ['Organization', 'Person'], |
|
120 | + 'startDate' => ['DateTime', 'Date'], |
|
121 | + 'subEvent' => ['Event'], |
|
122 | + 'subEvents' => ['Event'], |
|
123 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
124 | + 'superEvent' => ['Event'], |
|
125 | + 'translator' => ['Organization', 'Person'], |
|
126 | + 'typicalAgeRange' => ['Text'], |
|
127 | + 'url' => ['URL'], |
|
128 | + 'workFeatured' => ['CreativeWork'], |
|
129 | + 'workPerformed' => ['CreativeWork'] |
|
130 | + ]; |
|
131 | + } |
|
132 | + |
|
133 | + |
|
134 | + /** |
|
135 | + * @inheritdoc |
|
136 | + */ |
|
137 | + public function getSchemaPropertyDescriptions(): array |
|
138 | + { |
|
139 | + return [ |
|
140 | + 'about' => 'The subject matter of the content.', |
|
141 | + 'actor' => 'An actor, e.g. in TV, radio, movie, video games etc., or in an event. Actors can be associated with individual items or with a series, episode, clip.', |
|
142 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
143 | + 'aggregateRating' => 'The overall rating, based on a collection of reviews or ratings, of the item.', |
|
144 | + 'alternateName' => 'An alias for the item.', |
|
145 | + 'attendee' => 'A person or organization attending the event.', |
|
146 | + 'attendees' => 'A person attending the event.', |
|
147 | + 'audience' => 'An intended audience, i.e. a group for whom something was created.', |
|
148 | + 'composer' => 'The person or organization who wrote a composition, or who is the composer of a work performed at some event.', |
|
149 | + 'contributor' => 'A secondary contributor to the CreativeWork or Event.', |
|
150 | + 'description' => 'A description of the item.', |
|
151 | + 'director' => 'A director of e.g. TV, radio, movie, video gaming etc. content, or of an event. Directors can be associated with individual items or with a series, episode, clip.', |
|
152 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
153 | + 'doorTime' => 'The time admission will commence.', |
|
154 | + 'duration' => 'The duration of the item (movie, audio recording, event, etc.) in [ISO 8601 date format](http://en.wikipedia.org/wiki/ISO_8601).', |
|
155 | + 'endDate' => 'The end date and time of the item (in [ISO 8601 date format](http://en.wikipedia.org/wiki/ISO_8601)).', |
|
156 | + 'eventAttendanceMode' => 'The eventAttendanceMode of an event indicates whether it occurs online, offline, or a mix.', |
|
157 | + 'eventSchedule' => 'Associates an [[Event]] with a [[Schedule]]. There are circumstances where it is preferable to share a schedule for a series of repeating events rather than data on the individual events themselves. For example, a website or application might prefer to publish a schedule for a weekly gym class rather than provide data on every event. A schedule could be processed by applications to add forthcoming events to a calendar. An [[Event]] that is associated with a [[Schedule]] using this property should not have [[startDate]] or [[endDate]] properties. These are instead defined within the associated [[Schedule]], this avoids any ambiguity for clients using the data. The property might have repeated values to specify different schedules, e.g. for different months or seasons.', |
|
158 | + 'eventStatus' => 'An eventStatus of an event represents its status; particularly useful when an event is cancelled or rescheduled.', |
|
159 | + 'funder' => 'A person or organization that supports (sponsors) something through some kind of financial contribution.', |
|
160 | + 'funding' => 'A [[Grant]] that directly or indirectly provide funding or sponsorship for this item. See also [[ownershipFundingInfo]].', |
|
161 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
162 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
163 | + 'inLanguage' => 'The language of the content or performance or used in an action. Please use one of the language codes from the [IETF BCP 47 standard](http://tools.ietf.org/html/bcp47). See also [[availableLanguage]].', |
|
164 | + 'isAccessibleForFree' => 'A flag to signal that the item, event, or place is accessible for free.', |
|
165 | + 'keywords' => 'Keywords or tags used to describe some item. Multiple textual entries in a keywords list are typically delimited by commas, or by repeating the property.', |
|
166 | + 'location' => 'The location of, for example, where an event is happening, where an organization is located, or where an action takes place.', |
|
167 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
168 | + 'maximumAttendeeCapacity' => 'The total number of individuals that may attend an event or venue.', |
|
169 | + 'maximumPhysicalAttendeeCapacity' => 'The maximum physical attendee capacity of an [[Event]] whose [[eventAttendanceMode]] is [[OfflineEventAttendanceMode]] (or the offline aspects, in the case of a [[MixedEventAttendanceMode]]). ', |
|
170 | + 'maximumVirtualAttendeeCapacity' => 'The maximum physical attendee capacity of an [[Event]] whose [[eventAttendanceMode]] is [[OnlineEventAttendanceMode]] (or the online aspects, in the case of a [[MixedEventAttendanceMode]]). ', |
|
171 | + 'name' => 'The name of the item.', |
|
172 | + 'offers' => 'An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event. Use [[businessFunction]] to indicate the kind of transaction offered, i.e. sell, lease, etc. This property can also be used to describe a [[Demand]]. While this property is listed as expected on a number of common types, it can be used in others. In that case, using a second type, such as Product or a subtype of Product, can clarify the nature of the offer. ', |
|
173 | + 'organizer' => 'An organizer of an Event.', |
|
174 | + 'performer' => 'A performer at the event—for example, a presenter, musician, musical group or actor.', |
|
175 | + 'performers' => 'The main performer or performers of the event—for example, a presenter, musician, or actor.', |
|
176 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
177 | + 'previousStartDate' => 'Used in conjunction with eventStatus for rescheduled or cancelled events. This property contains the previously scheduled start date. For rescheduled events, the startDate property should be used for the newly scheduled start date. In the (rare) case of an event that has been postponed and rescheduled multiple times, this field may be repeated.', |
|
178 | + 'recordedIn' => 'The CreativeWork that captured all or part of this Event.', |
|
179 | + 'remainingAttendeeCapacity' => 'The number of attendee places for an event that remain unallocated.', |
|
180 | + 'review' => 'A review of the item.', |
|
181 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
182 | + 'sponsor' => 'A person or organization that supports a thing through a pledge, promise, or financial contribution. E.g. a sponsor of a Medical Study or a corporate sponsor of an event.', |
|
183 | + 'startDate' => 'The start date and time of the item (in [ISO 8601 date format](http://en.wikipedia.org/wiki/ISO_8601)).', |
|
184 | + 'subEvent' => 'An Event that is part of this event. For example, a conference event includes many presentations, each of which is a subEvent of the conference.', |
|
185 | + 'subEvents' => 'Events that are a part of this event. For example, a conference event includes many presentations, each subEvents of the conference.', |
|
186 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
187 | + 'superEvent' => 'An event that this event is a part of. For example, a collection of individual music performances might each have a music festival as their superEvent.', |
|
188 | + 'translator' => 'Organization or person who adapts a creative work to different languages, regional differences and technical requirements of a target market, or that translates during some event.', |
|
189 | + 'typicalAgeRange' => 'The typical expected age range, e.g. \'7-9\', \'11-\'.', |
|
190 | + 'url' => 'URL of the item.', |
|
191 | + 'workFeatured' => 'A work featured in some event, e.g. exhibited in an ExhibitionEvent. Specific subproperties are available for workPerformed (e.g. a play), or a workPresented (a Movie at a ScreeningEvent).', |
|
192 | + 'workPerformed' => 'A work performed in some event, for example a play performed in a TheaterEvent.' |
|
193 | + ]; |
|
194 | + } |
|
195 | + |
|
196 | + |
|
197 | + /** |
|
198 | + * @inheritdoc |
|
199 | + */ |
|
200 | + public function getGoogleRequiredSchema(): array |
|
201 | + { |
|
202 | + return ['description', 'name']; |
|
203 | + } |
|
204 | + |
|
205 | + |
|
206 | + /** |
|
207 | + * @inheritdoc |
|
208 | + */ |
|
209 | + public function getGoogleRecommendedSchema(): array |
|
210 | + { |
|
211 | + return ['image', 'url']; |
|
212 | + } |
|
213 | + |
|
214 | + |
|
215 | + /** |
|
216 | + * @inheritdoc |
|
217 | + */ |
|
218 | + public function defineRules(): array |
|
219 | + { |
|
220 | + $rules = parent::defineRules(); |
|
221 | + $rules = array_merge($rules, [ |
|
222 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
223 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
224 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
225 | + ]); |
|
226 | + |
|
227 | + return $rules; |
|
228 | + } |
|
229 | 229 | } |
@@ -30,151 +30,151 @@ |
||
30 | 30 | */ |
31 | 31 | class MedicalObservationalStudy extends MetaJsonLd implements MedicalObservationalStudyInterface, MedicalStudyInterface, MedicalEntityInterface, ThingInterface |
32 | 32 | { |
33 | - use MedicalObservationalStudyTrait; |
|
34 | - use MedicalStudyTrait; |
|
35 | - use MedicalEntityTrait; |
|
36 | - use ThingTrait; |
|
37 | - |
|
38 | - /** |
|
39 | - * The Schema.org Type Name |
|
40 | - * |
|
41 | - * @var string |
|
42 | - */ |
|
43 | - public static string $schemaTypeName = 'MedicalObservationalStudy'; |
|
44 | - |
|
45 | - /** |
|
46 | - * The Schema.org Type Scope |
|
47 | - * |
|
48 | - * @var string |
|
49 | - */ |
|
50 | - public static string $schemaTypeScope = 'https://schema.org/MedicalObservationalStudy'; |
|
51 | - |
|
52 | - /** |
|
53 | - * The Schema.org Type Extends |
|
54 | - * |
|
55 | - * @var string |
|
56 | - */ |
|
57 | - public static string $schemaTypeExtends = 'MedicalStudy'; |
|
58 | - |
|
59 | - /** |
|
60 | - * The Schema.org Type Description |
|
61 | - * |
|
62 | - * @var string |
|
63 | - */ |
|
64 | - public static string $schemaTypeDescription = 'An observational study is a type of medical study that attempts to infer the possible effect of a treatment through observation of a cohort of subjects over a period of time. In an observational study, the assignment of subjects into treatment groups versus control groups is outside the control of the investigator. This is in contrast with controlled studies, such as the randomized controlled trials represented by MedicalTrial, where each subject is randomly assigned to a treatment group or a control group before the start of the treatment.'; |
|
65 | - |
|
66 | - |
|
67 | - /** |
|
68 | - * @inheritdoc |
|
69 | - */ |
|
70 | - public function getSchemaPropertyNames(): array |
|
71 | - { |
|
72 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
73 | - } |
|
74 | - |
|
75 | - |
|
76 | - /** |
|
77 | - * @inheritdoc |
|
78 | - */ |
|
79 | - public function getSchemaPropertyExpectedTypes(): array |
|
80 | - { |
|
81 | - return [ |
|
82 | - 'additionalType' => ['URL'], |
|
83 | - 'alternateName' => ['Text'], |
|
84 | - 'code' => ['MedicalCode'], |
|
85 | - 'description' => ['Text'], |
|
86 | - 'disambiguatingDescription' => ['Text'], |
|
87 | - 'funding' => ['Grant'], |
|
88 | - 'guideline' => ['MedicalGuideline'], |
|
89 | - 'healthCondition' => ['MedicalCondition'], |
|
90 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
91 | - 'image' => ['URL', 'ImageObject'], |
|
92 | - 'legalStatus' => ['Text', 'DrugLegalStatus', 'MedicalEnumeration'], |
|
93 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
94 | - 'medicineSystem' => ['MedicineSystem'], |
|
95 | - 'name' => ['Text'], |
|
96 | - 'potentialAction' => ['Action'], |
|
97 | - 'recognizingAuthority' => ['Organization'], |
|
98 | - 'relevantSpecialty' => ['MedicalSpecialty'], |
|
99 | - 'sameAs' => ['URL'], |
|
100 | - 'sponsor' => ['Organization', 'Person'], |
|
101 | - 'status' => ['MedicalStudyStatus', 'Text', 'EventStatusType'], |
|
102 | - 'study' => ['MedicalStudy'], |
|
103 | - 'studyDesign' => ['MedicalObservationalStudyDesign'], |
|
104 | - 'studyLocation' => ['AdministrativeArea'], |
|
105 | - 'studySubject' => ['MedicalEntity'], |
|
106 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
107 | - 'url' => ['URL'] |
|
108 | - ]; |
|
109 | - } |
|
110 | - |
|
111 | - |
|
112 | - /** |
|
113 | - * @inheritdoc |
|
114 | - */ |
|
115 | - public function getSchemaPropertyDescriptions(): array |
|
116 | - { |
|
117 | - return [ |
|
118 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
119 | - 'alternateName' => 'An alias for the item.', |
|
120 | - 'code' => 'A medical code for the entity, taken from a controlled vocabulary or ontology such as ICD-9, DiseasesDB, MeSH, SNOMED-CT, RxNorm, etc.', |
|
121 | - 'description' => 'A description of the item.', |
|
122 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
123 | - 'funding' => 'A [[Grant]] that directly or indirectly provide funding or sponsorship for this item. See also [[ownershipFundingInfo]].', |
|
124 | - 'guideline' => 'A medical guideline related to this entity.', |
|
125 | - 'healthCondition' => 'Specifying the health condition(s) of a patient, medical study, or other target audience.', |
|
126 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
127 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
128 | - 'legalStatus' => 'The drug or supplement\'s legal status, including any controlled substance schedules that apply.', |
|
129 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
130 | - 'medicineSystem' => 'The system of medicine that includes this MedicalEntity, for example \'evidence-based\', \'homeopathic\', \'chiropractic\', etc.', |
|
131 | - 'name' => 'The name of the item.', |
|
132 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
133 | - 'recognizingAuthority' => 'If applicable, the organization that officially recognizes this entity as part of its endorsed system of medicine.', |
|
134 | - 'relevantSpecialty' => 'If applicable, a medical specialty in which this entity is relevant.', |
|
135 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
136 | - 'sponsor' => 'A person or organization that supports a thing through a pledge, promise, or financial contribution. E.g. a sponsor of a Medical Study or a corporate sponsor of an event.', |
|
137 | - 'status' => 'The status of the study (enumerated).', |
|
138 | - 'study' => 'A medical study or trial related to this entity.', |
|
139 | - 'studyDesign' => 'Specifics about the observational study design (enumerated).', |
|
140 | - 'studyLocation' => 'The location in which the study is taking/took place.', |
|
141 | - 'studySubject' => 'A subject of the study, i.e. one of the medical conditions, therapies, devices, drugs, etc. investigated by the study.', |
|
142 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
143 | - 'url' => 'URL of the item.' |
|
144 | - ]; |
|
145 | - } |
|
146 | - |
|
147 | - |
|
148 | - /** |
|
149 | - * @inheritdoc |
|
150 | - */ |
|
151 | - public function getGoogleRequiredSchema(): array |
|
152 | - { |
|
153 | - return ['description', 'name']; |
|
154 | - } |
|
155 | - |
|
156 | - |
|
157 | - /** |
|
158 | - * @inheritdoc |
|
159 | - */ |
|
160 | - public function getGoogleRecommendedSchema(): array |
|
161 | - { |
|
162 | - return ['image', 'url']; |
|
163 | - } |
|
164 | - |
|
165 | - |
|
166 | - /** |
|
167 | - * @inheritdoc |
|
168 | - */ |
|
169 | - public function defineRules(): array |
|
170 | - { |
|
171 | - $rules = parent::defineRules(); |
|
172 | - $rules = array_merge($rules, [ |
|
173 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
174 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
175 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
176 | - ]); |
|
177 | - |
|
178 | - return $rules; |
|
179 | - } |
|
33 | + use MedicalObservationalStudyTrait; |
|
34 | + use MedicalStudyTrait; |
|
35 | + use MedicalEntityTrait; |
|
36 | + use ThingTrait; |
|
37 | + |
|
38 | + /** |
|
39 | + * The Schema.org Type Name |
|
40 | + * |
|
41 | + * @var string |
|
42 | + */ |
|
43 | + public static string $schemaTypeName = 'MedicalObservationalStudy'; |
|
44 | + |
|
45 | + /** |
|
46 | + * The Schema.org Type Scope |
|
47 | + * |
|
48 | + * @var string |
|
49 | + */ |
|
50 | + public static string $schemaTypeScope = 'https://schema.org/MedicalObservationalStudy'; |
|
51 | + |
|
52 | + /** |
|
53 | + * The Schema.org Type Extends |
|
54 | + * |
|
55 | + * @var string |
|
56 | + */ |
|
57 | + public static string $schemaTypeExtends = 'MedicalStudy'; |
|
58 | + |
|
59 | + /** |
|
60 | + * The Schema.org Type Description |
|
61 | + * |
|
62 | + * @var string |
|
63 | + */ |
|
64 | + public static string $schemaTypeDescription = 'An observational study is a type of medical study that attempts to infer the possible effect of a treatment through observation of a cohort of subjects over a period of time. In an observational study, the assignment of subjects into treatment groups versus control groups is outside the control of the investigator. This is in contrast with controlled studies, such as the randomized controlled trials represented by MedicalTrial, where each subject is randomly assigned to a treatment group or a control group before the start of the treatment.'; |
|
65 | + |
|
66 | + |
|
67 | + /** |
|
68 | + * @inheritdoc |
|
69 | + */ |
|
70 | + public function getSchemaPropertyNames(): array |
|
71 | + { |
|
72 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
73 | + } |
|
74 | + |
|
75 | + |
|
76 | + /** |
|
77 | + * @inheritdoc |
|
78 | + */ |
|
79 | + public function getSchemaPropertyExpectedTypes(): array |
|
80 | + { |
|
81 | + return [ |
|
82 | + 'additionalType' => ['URL'], |
|
83 | + 'alternateName' => ['Text'], |
|
84 | + 'code' => ['MedicalCode'], |
|
85 | + 'description' => ['Text'], |
|
86 | + 'disambiguatingDescription' => ['Text'], |
|
87 | + 'funding' => ['Grant'], |
|
88 | + 'guideline' => ['MedicalGuideline'], |
|
89 | + 'healthCondition' => ['MedicalCondition'], |
|
90 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
91 | + 'image' => ['URL', 'ImageObject'], |
|
92 | + 'legalStatus' => ['Text', 'DrugLegalStatus', 'MedicalEnumeration'], |
|
93 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
94 | + 'medicineSystem' => ['MedicineSystem'], |
|
95 | + 'name' => ['Text'], |
|
96 | + 'potentialAction' => ['Action'], |
|
97 | + 'recognizingAuthority' => ['Organization'], |
|
98 | + 'relevantSpecialty' => ['MedicalSpecialty'], |
|
99 | + 'sameAs' => ['URL'], |
|
100 | + 'sponsor' => ['Organization', 'Person'], |
|
101 | + 'status' => ['MedicalStudyStatus', 'Text', 'EventStatusType'], |
|
102 | + 'study' => ['MedicalStudy'], |
|
103 | + 'studyDesign' => ['MedicalObservationalStudyDesign'], |
|
104 | + 'studyLocation' => ['AdministrativeArea'], |
|
105 | + 'studySubject' => ['MedicalEntity'], |
|
106 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
107 | + 'url' => ['URL'] |
|
108 | + ]; |
|
109 | + } |
|
110 | + |
|
111 | + |
|
112 | + /** |
|
113 | + * @inheritdoc |
|
114 | + */ |
|
115 | + public function getSchemaPropertyDescriptions(): array |
|
116 | + { |
|
117 | + return [ |
|
118 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
119 | + 'alternateName' => 'An alias for the item.', |
|
120 | + 'code' => 'A medical code for the entity, taken from a controlled vocabulary or ontology such as ICD-9, DiseasesDB, MeSH, SNOMED-CT, RxNorm, etc.', |
|
121 | + 'description' => 'A description of the item.', |
|
122 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
123 | + 'funding' => 'A [[Grant]] that directly or indirectly provide funding or sponsorship for this item. See also [[ownershipFundingInfo]].', |
|
124 | + 'guideline' => 'A medical guideline related to this entity.', |
|
125 | + 'healthCondition' => 'Specifying the health condition(s) of a patient, medical study, or other target audience.', |
|
126 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
127 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
128 | + 'legalStatus' => 'The drug or supplement\'s legal status, including any controlled substance schedules that apply.', |
|
129 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
130 | + 'medicineSystem' => 'The system of medicine that includes this MedicalEntity, for example \'evidence-based\', \'homeopathic\', \'chiropractic\', etc.', |
|
131 | + 'name' => 'The name of the item.', |
|
132 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
133 | + 'recognizingAuthority' => 'If applicable, the organization that officially recognizes this entity as part of its endorsed system of medicine.', |
|
134 | + 'relevantSpecialty' => 'If applicable, a medical specialty in which this entity is relevant.', |
|
135 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
136 | + 'sponsor' => 'A person or organization that supports a thing through a pledge, promise, or financial contribution. E.g. a sponsor of a Medical Study or a corporate sponsor of an event.', |
|
137 | + 'status' => 'The status of the study (enumerated).', |
|
138 | + 'study' => 'A medical study or trial related to this entity.', |
|
139 | + 'studyDesign' => 'Specifics about the observational study design (enumerated).', |
|
140 | + 'studyLocation' => 'The location in which the study is taking/took place.', |
|
141 | + 'studySubject' => 'A subject of the study, i.e. one of the medical conditions, therapies, devices, drugs, etc. investigated by the study.', |
|
142 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
143 | + 'url' => 'URL of the item.' |
|
144 | + ]; |
|
145 | + } |
|
146 | + |
|
147 | + |
|
148 | + /** |
|
149 | + * @inheritdoc |
|
150 | + */ |
|
151 | + public function getGoogleRequiredSchema(): array |
|
152 | + { |
|
153 | + return ['description', 'name']; |
|
154 | + } |
|
155 | + |
|
156 | + |
|
157 | + /** |
|
158 | + * @inheritdoc |
|
159 | + */ |
|
160 | + public function getGoogleRecommendedSchema(): array |
|
161 | + { |
|
162 | + return ['image', 'url']; |
|
163 | + } |
|
164 | + |
|
165 | + |
|
166 | + /** |
|
167 | + * @inheritdoc |
|
168 | + */ |
|
169 | + public function defineRules(): array |
|
170 | + { |
|
171 | + $rules = parent::defineRules(); |
|
172 | + $rules = array_merge($rules, [ |
|
173 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
174 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
175 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
176 | + ]); |
|
177 | + |
|
178 | + return $rules; |
|
179 | + } |
|
180 | 180 | } |
@@ -23,126 +23,126 @@ |
||
23 | 23 | */ |
24 | 24 | class ParkingMap extends MetaJsonLd implements ParkingMapInterface, MapCategoryTypeInterface, EnumerationInterface, IntangibleInterface, ThingInterface |
25 | 25 | { |
26 | - use ParkingMapTrait; |
|
27 | - use MapCategoryTypeTrait; |
|
28 | - use EnumerationTrait; |
|
29 | - use IntangibleTrait; |
|
30 | - use ThingTrait; |
|
31 | - |
|
32 | - /** |
|
33 | - * The Schema.org Type Name |
|
34 | - * |
|
35 | - * @var string |
|
36 | - */ |
|
37 | - public static string $schemaTypeName = 'ParkingMap'; |
|
38 | - |
|
39 | - /** |
|
40 | - * The Schema.org Type Scope |
|
41 | - * |
|
42 | - * @var string |
|
43 | - */ |
|
44 | - public static string $schemaTypeScope = 'https://schema.org/ParkingMap'; |
|
45 | - |
|
46 | - /** |
|
47 | - * The Schema.org Type Extends |
|
48 | - * |
|
49 | - * @var string |
|
50 | - */ |
|
51 | - public static string $schemaTypeExtends = 'MapCategoryType'; |
|
52 | - |
|
53 | - /** |
|
54 | - * The Schema.org Type Description |
|
55 | - * |
|
56 | - * @var string |
|
57 | - */ |
|
58 | - public static string $schemaTypeDescription = 'A parking map.'; |
|
59 | - |
|
60 | - |
|
61 | - /** |
|
62 | - * @inheritdoc |
|
63 | - */ |
|
64 | - public function getSchemaPropertyNames(): array |
|
65 | - { |
|
66 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
67 | - } |
|
68 | - |
|
69 | - |
|
70 | - /** |
|
71 | - * @inheritdoc |
|
72 | - */ |
|
73 | - public function getSchemaPropertyExpectedTypes(): array |
|
74 | - { |
|
75 | - return [ |
|
76 | - 'additionalType' => ['URL'], |
|
77 | - 'alternateName' => ['Text'], |
|
78 | - 'description' => ['Text'], |
|
79 | - 'disambiguatingDescription' => ['Text'], |
|
80 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
81 | - 'image' => ['URL', 'ImageObject'], |
|
82 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
83 | - 'name' => ['Text'], |
|
84 | - 'potentialAction' => ['Action'], |
|
85 | - 'sameAs' => ['URL'], |
|
86 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
87 | - 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
88 | - 'url' => ['URL'] |
|
89 | - ]; |
|
90 | - } |
|
91 | - |
|
92 | - |
|
93 | - /** |
|
94 | - * @inheritdoc |
|
95 | - */ |
|
96 | - public function getSchemaPropertyDescriptions(): array |
|
97 | - { |
|
98 | - return [ |
|
99 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
100 | - 'alternateName' => 'An alias for the item.', |
|
101 | - 'description' => 'A description of the item.', |
|
102 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
103 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
104 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
105 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
106 | - 'name' => 'The name of the item.', |
|
107 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
108 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
109 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
110 | - 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
111 | - 'url' => 'URL of the item.' |
|
112 | - ]; |
|
113 | - } |
|
114 | - |
|
115 | - |
|
116 | - /** |
|
117 | - * @inheritdoc |
|
118 | - */ |
|
119 | - public function getGoogleRequiredSchema(): array |
|
120 | - { |
|
121 | - return ['description', 'name']; |
|
122 | - } |
|
123 | - |
|
124 | - |
|
125 | - /** |
|
126 | - * @inheritdoc |
|
127 | - */ |
|
128 | - public function getGoogleRecommendedSchema(): array |
|
129 | - { |
|
130 | - return ['image', 'url']; |
|
131 | - } |
|
132 | - |
|
133 | - |
|
134 | - /** |
|
135 | - * @inheritdoc |
|
136 | - */ |
|
137 | - public function defineRules(): array |
|
138 | - { |
|
139 | - $rules = parent::defineRules(); |
|
140 | - $rules = array_merge($rules, [ |
|
141 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
142 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
143 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
144 | - ]); |
|
145 | - |
|
146 | - return $rules; |
|
147 | - } |
|
26 | + use ParkingMapTrait; |
|
27 | + use MapCategoryTypeTrait; |
|
28 | + use EnumerationTrait; |
|
29 | + use IntangibleTrait; |
|
30 | + use ThingTrait; |
|
31 | + |
|
32 | + /** |
|
33 | + * The Schema.org Type Name |
|
34 | + * |
|
35 | + * @var string |
|
36 | + */ |
|
37 | + public static string $schemaTypeName = 'ParkingMap'; |
|
38 | + |
|
39 | + /** |
|
40 | + * The Schema.org Type Scope |
|
41 | + * |
|
42 | + * @var string |
|
43 | + */ |
|
44 | + public static string $schemaTypeScope = 'https://schema.org/ParkingMap'; |
|
45 | + |
|
46 | + /** |
|
47 | + * The Schema.org Type Extends |
|
48 | + * |
|
49 | + * @var string |
|
50 | + */ |
|
51 | + public static string $schemaTypeExtends = 'MapCategoryType'; |
|
52 | + |
|
53 | + /** |
|
54 | + * The Schema.org Type Description |
|
55 | + * |
|
56 | + * @var string |
|
57 | + */ |
|
58 | + public static string $schemaTypeDescription = 'A parking map.'; |
|
59 | + |
|
60 | + |
|
61 | + /** |
|
62 | + * @inheritdoc |
|
63 | + */ |
|
64 | + public function getSchemaPropertyNames(): array |
|
65 | + { |
|
66 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
67 | + } |
|
68 | + |
|
69 | + |
|
70 | + /** |
|
71 | + * @inheritdoc |
|
72 | + */ |
|
73 | + public function getSchemaPropertyExpectedTypes(): array |
|
74 | + { |
|
75 | + return [ |
|
76 | + 'additionalType' => ['URL'], |
|
77 | + 'alternateName' => ['Text'], |
|
78 | + 'description' => ['Text'], |
|
79 | + 'disambiguatingDescription' => ['Text'], |
|
80 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
81 | + 'image' => ['URL', 'ImageObject'], |
|
82 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
83 | + 'name' => ['Text'], |
|
84 | + 'potentialAction' => ['Action'], |
|
85 | + 'sameAs' => ['URL'], |
|
86 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
87 | + 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
88 | + 'url' => ['URL'] |
|
89 | + ]; |
|
90 | + } |
|
91 | + |
|
92 | + |
|
93 | + /** |
|
94 | + * @inheritdoc |
|
95 | + */ |
|
96 | + public function getSchemaPropertyDescriptions(): array |
|
97 | + { |
|
98 | + return [ |
|
99 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
100 | + 'alternateName' => 'An alias for the item.', |
|
101 | + 'description' => 'A description of the item.', |
|
102 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
103 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
104 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
105 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
106 | + 'name' => 'The name of the item.', |
|
107 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
108 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
109 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
110 | + 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
111 | + 'url' => 'URL of the item.' |
|
112 | + ]; |
|
113 | + } |
|
114 | + |
|
115 | + |
|
116 | + /** |
|
117 | + * @inheritdoc |
|
118 | + */ |
|
119 | + public function getGoogleRequiredSchema(): array |
|
120 | + { |
|
121 | + return ['description', 'name']; |
|
122 | + } |
|
123 | + |
|
124 | + |
|
125 | + /** |
|
126 | + * @inheritdoc |
|
127 | + */ |
|
128 | + public function getGoogleRecommendedSchema(): array |
|
129 | + { |
|
130 | + return ['image', 'url']; |
|
131 | + } |
|
132 | + |
|
133 | + |
|
134 | + /** |
|
135 | + * @inheritdoc |
|
136 | + */ |
|
137 | + public function defineRules(): array |
|
138 | + { |
|
139 | + $rules = parent::defineRules(); |
|
140 | + $rules = array_merge($rules, [ |
|
141 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
142 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
143 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
144 | + ]); |
|
145 | + |
|
146 | + return $rules; |
|
147 | + } |
|
148 | 148 | } |
@@ -25,128 +25,128 @@ |
||
25 | 25 | */ |
26 | 26 | class Urologic extends MetaJsonLd implements UrologicInterface, MedicalSpecialtyInterface, SpecialtyInterface, EnumerationInterface, IntangibleInterface, ThingInterface, MedicalEnumerationInterface |
27 | 27 | { |
28 | - use UrologicTrait; |
|
29 | - use MedicalSpecialtyTrait; |
|
30 | - use SpecialtyTrait; |
|
31 | - use EnumerationTrait; |
|
32 | - use IntangibleTrait; |
|
33 | - use ThingTrait; |
|
34 | - use MedicalEnumerationTrait; |
|
35 | - |
|
36 | - /** |
|
37 | - * The Schema.org Type Name |
|
38 | - * |
|
39 | - * @var string |
|
40 | - */ |
|
41 | - public static string $schemaTypeName = 'Urologic'; |
|
42 | - |
|
43 | - /** |
|
44 | - * The Schema.org Type Scope |
|
45 | - * |
|
46 | - * @var string |
|
47 | - */ |
|
48 | - public static string $schemaTypeScope = 'https://schema.org/Urologic'; |
|
49 | - |
|
50 | - /** |
|
51 | - * The Schema.org Type Extends |
|
52 | - * |
|
53 | - * @var string |
|
54 | - */ |
|
55 | - public static string $schemaTypeExtends = 'MedicalSpecialty'; |
|
56 | - |
|
57 | - /** |
|
58 | - * The Schema.org Type Description |
|
59 | - * |
|
60 | - * @var string |
|
61 | - */ |
|
62 | - public static string $schemaTypeDescription = 'A specific branch of medical science that is concerned with the diagnosis and treatment of diseases pertaining to the urinary tract and the urogenital system.'; |
|
63 | - |
|
64 | - |
|
65 | - /** |
|
66 | - * @inheritdoc |
|
67 | - */ |
|
68 | - public function getSchemaPropertyNames(): array |
|
69 | - { |
|
70 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
71 | - } |
|
72 | - |
|
73 | - |
|
74 | - /** |
|
75 | - * @inheritdoc |
|
76 | - */ |
|
77 | - public function getSchemaPropertyExpectedTypes(): array |
|
78 | - { |
|
79 | - return [ |
|
80 | - 'additionalType' => ['URL'], |
|
81 | - 'alternateName' => ['Text'], |
|
82 | - 'description' => ['Text'], |
|
83 | - 'disambiguatingDescription' => ['Text'], |
|
84 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
85 | - 'image' => ['URL', 'ImageObject'], |
|
86 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
87 | - 'name' => ['Text'], |
|
88 | - 'potentialAction' => ['Action'], |
|
89 | - 'sameAs' => ['URL'], |
|
90 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
91 | - 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
92 | - 'url' => ['URL'] |
|
93 | - ]; |
|
94 | - } |
|
95 | - |
|
96 | - |
|
97 | - /** |
|
98 | - * @inheritdoc |
|
99 | - */ |
|
100 | - public function getSchemaPropertyDescriptions(): array |
|
101 | - { |
|
102 | - return [ |
|
103 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
104 | - 'alternateName' => 'An alias for the item.', |
|
105 | - 'description' => 'A description of the item.', |
|
106 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
107 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
108 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
109 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
110 | - 'name' => 'The name of the item.', |
|
111 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
112 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
113 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
114 | - 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
115 | - 'url' => 'URL of the item.' |
|
116 | - ]; |
|
117 | - } |
|
118 | - |
|
119 | - |
|
120 | - /** |
|
121 | - * @inheritdoc |
|
122 | - */ |
|
123 | - public function getGoogleRequiredSchema(): array |
|
124 | - { |
|
125 | - return ['description', 'name']; |
|
126 | - } |
|
127 | - |
|
128 | - |
|
129 | - /** |
|
130 | - * @inheritdoc |
|
131 | - */ |
|
132 | - public function getGoogleRecommendedSchema(): array |
|
133 | - { |
|
134 | - return ['image', 'url']; |
|
135 | - } |
|
136 | - |
|
137 | - |
|
138 | - /** |
|
139 | - * @inheritdoc |
|
140 | - */ |
|
141 | - public function defineRules(): array |
|
142 | - { |
|
143 | - $rules = parent::defineRules(); |
|
144 | - $rules = array_merge($rules, [ |
|
145 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
146 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
147 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
148 | - ]); |
|
149 | - |
|
150 | - return $rules; |
|
151 | - } |
|
28 | + use UrologicTrait; |
|
29 | + use MedicalSpecialtyTrait; |
|
30 | + use SpecialtyTrait; |
|
31 | + use EnumerationTrait; |
|
32 | + use IntangibleTrait; |
|
33 | + use ThingTrait; |
|
34 | + use MedicalEnumerationTrait; |
|
35 | + |
|
36 | + /** |
|
37 | + * The Schema.org Type Name |
|
38 | + * |
|
39 | + * @var string |
|
40 | + */ |
|
41 | + public static string $schemaTypeName = 'Urologic'; |
|
42 | + |
|
43 | + /** |
|
44 | + * The Schema.org Type Scope |
|
45 | + * |
|
46 | + * @var string |
|
47 | + */ |
|
48 | + public static string $schemaTypeScope = 'https://schema.org/Urologic'; |
|
49 | + |
|
50 | + /** |
|
51 | + * The Schema.org Type Extends |
|
52 | + * |
|
53 | + * @var string |
|
54 | + */ |
|
55 | + public static string $schemaTypeExtends = 'MedicalSpecialty'; |
|
56 | + |
|
57 | + /** |
|
58 | + * The Schema.org Type Description |
|
59 | + * |
|
60 | + * @var string |
|
61 | + */ |
|
62 | + public static string $schemaTypeDescription = 'A specific branch of medical science that is concerned with the diagnosis and treatment of diseases pertaining to the urinary tract and the urogenital system.'; |
|
63 | + |
|
64 | + |
|
65 | + /** |
|
66 | + * @inheritdoc |
|
67 | + */ |
|
68 | + public function getSchemaPropertyNames(): array |
|
69 | + { |
|
70 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
71 | + } |
|
72 | + |
|
73 | + |
|
74 | + /** |
|
75 | + * @inheritdoc |
|
76 | + */ |
|
77 | + public function getSchemaPropertyExpectedTypes(): array |
|
78 | + { |
|
79 | + return [ |
|
80 | + 'additionalType' => ['URL'], |
|
81 | + 'alternateName' => ['Text'], |
|
82 | + 'description' => ['Text'], |
|
83 | + 'disambiguatingDescription' => ['Text'], |
|
84 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
85 | + 'image' => ['URL', 'ImageObject'], |
|
86 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
87 | + 'name' => ['Text'], |
|
88 | + 'potentialAction' => ['Action'], |
|
89 | + 'sameAs' => ['URL'], |
|
90 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
91 | + 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
92 | + 'url' => ['URL'] |
|
93 | + ]; |
|
94 | + } |
|
95 | + |
|
96 | + |
|
97 | + /** |
|
98 | + * @inheritdoc |
|
99 | + */ |
|
100 | + public function getSchemaPropertyDescriptions(): array |
|
101 | + { |
|
102 | + return [ |
|
103 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
104 | + 'alternateName' => 'An alias for the item.', |
|
105 | + 'description' => 'A description of the item.', |
|
106 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
107 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
108 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
109 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
110 | + 'name' => 'The name of the item.', |
|
111 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
112 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
113 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
114 | + 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
115 | + 'url' => 'URL of the item.' |
|
116 | + ]; |
|
117 | + } |
|
118 | + |
|
119 | + |
|
120 | + /** |
|
121 | + * @inheritdoc |
|
122 | + */ |
|
123 | + public function getGoogleRequiredSchema(): array |
|
124 | + { |
|
125 | + return ['description', 'name']; |
|
126 | + } |
|
127 | + |
|
128 | + |
|
129 | + /** |
|
130 | + * @inheritdoc |
|
131 | + */ |
|
132 | + public function getGoogleRecommendedSchema(): array |
|
133 | + { |
|
134 | + return ['image', 'url']; |
|
135 | + } |
|
136 | + |
|
137 | + |
|
138 | + /** |
|
139 | + * @inheritdoc |
|
140 | + */ |
|
141 | + public function defineRules(): array |
|
142 | + { |
|
143 | + $rules = parent::defineRules(); |
|
144 | + $rules = array_merge($rules, [ |
|
145 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
146 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
147 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
148 | + ]); |
|
149 | + |
|
150 | + return $rules; |
|
151 | + } |
|
152 | 152 | } |
@@ -23,127 +23,127 @@ |
||
23 | 23 | */ |
24 | 24 | class Nonprofit501c23 extends MetaJsonLd implements Nonprofit501c23Interface, USNonprofitTypeInterface, NonprofitTypeInterface, EnumerationInterface, IntangibleInterface, ThingInterface |
25 | 25 | { |
26 | - use Nonprofit501c23Trait; |
|
27 | - use USNonprofitTypeTrait; |
|
28 | - use NonprofitTypeTrait; |
|
29 | - use EnumerationTrait; |
|
30 | - use IntangibleTrait; |
|
31 | - use ThingTrait; |
|
32 | - |
|
33 | - /** |
|
34 | - * The Schema.org Type Name |
|
35 | - * |
|
36 | - * @var string |
|
37 | - */ |
|
38 | - public static string $schemaTypeName = 'Nonprofit501c23'; |
|
39 | - |
|
40 | - /** |
|
41 | - * The Schema.org Type Scope |
|
42 | - * |
|
43 | - * @var string |
|
44 | - */ |
|
45 | - public static string $schemaTypeScope = 'https://schema.org/Nonprofit501c23'; |
|
46 | - |
|
47 | - /** |
|
48 | - * The Schema.org Type Extends |
|
49 | - * |
|
50 | - * @var string |
|
51 | - */ |
|
52 | - public static string $schemaTypeExtends = 'USNonprofitType'; |
|
53 | - |
|
54 | - /** |
|
55 | - * The Schema.org Type Description |
|
56 | - * |
|
57 | - * @var string |
|
58 | - */ |
|
59 | - public static string $schemaTypeDescription = 'Nonprofit501c23: Non-profit type referring to Veterans Organizations.'; |
|
60 | - |
|
61 | - |
|
62 | - /** |
|
63 | - * @inheritdoc |
|
64 | - */ |
|
65 | - public function getSchemaPropertyNames(): array |
|
66 | - { |
|
67 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
68 | - } |
|
69 | - |
|
70 | - |
|
71 | - /** |
|
72 | - * @inheritdoc |
|
73 | - */ |
|
74 | - public function getSchemaPropertyExpectedTypes(): array |
|
75 | - { |
|
76 | - return [ |
|
77 | - 'additionalType' => ['URL'], |
|
78 | - 'alternateName' => ['Text'], |
|
79 | - 'description' => ['Text'], |
|
80 | - 'disambiguatingDescription' => ['Text'], |
|
81 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
82 | - 'image' => ['URL', 'ImageObject'], |
|
83 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
84 | - 'name' => ['Text'], |
|
85 | - 'potentialAction' => ['Action'], |
|
86 | - 'sameAs' => ['URL'], |
|
87 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
88 | - 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
89 | - 'url' => ['URL'] |
|
90 | - ]; |
|
91 | - } |
|
92 | - |
|
93 | - |
|
94 | - /** |
|
95 | - * @inheritdoc |
|
96 | - */ |
|
97 | - public function getSchemaPropertyDescriptions(): array |
|
98 | - { |
|
99 | - return [ |
|
100 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
101 | - 'alternateName' => 'An alias for the item.', |
|
102 | - 'description' => 'A description of the item.', |
|
103 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
104 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
105 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
106 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
107 | - 'name' => 'The name of the item.', |
|
108 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
109 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
110 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
111 | - 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
112 | - 'url' => 'URL of the item.' |
|
113 | - ]; |
|
114 | - } |
|
115 | - |
|
116 | - |
|
117 | - /** |
|
118 | - * @inheritdoc |
|
119 | - */ |
|
120 | - public function getGoogleRequiredSchema(): array |
|
121 | - { |
|
122 | - return ['description', 'name']; |
|
123 | - } |
|
124 | - |
|
125 | - |
|
126 | - /** |
|
127 | - * @inheritdoc |
|
128 | - */ |
|
129 | - public function getGoogleRecommendedSchema(): array |
|
130 | - { |
|
131 | - return ['image', 'url']; |
|
132 | - } |
|
133 | - |
|
134 | - |
|
135 | - /** |
|
136 | - * @inheritdoc |
|
137 | - */ |
|
138 | - public function defineRules(): array |
|
139 | - { |
|
140 | - $rules = parent::defineRules(); |
|
141 | - $rules = array_merge($rules, [ |
|
142 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
143 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
144 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
145 | - ]); |
|
146 | - |
|
147 | - return $rules; |
|
148 | - } |
|
26 | + use Nonprofit501c23Trait; |
|
27 | + use USNonprofitTypeTrait; |
|
28 | + use NonprofitTypeTrait; |
|
29 | + use EnumerationTrait; |
|
30 | + use IntangibleTrait; |
|
31 | + use ThingTrait; |
|
32 | + |
|
33 | + /** |
|
34 | + * The Schema.org Type Name |
|
35 | + * |
|
36 | + * @var string |
|
37 | + */ |
|
38 | + public static string $schemaTypeName = 'Nonprofit501c23'; |
|
39 | + |
|
40 | + /** |
|
41 | + * The Schema.org Type Scope |
|
42 | + * |
|
43 | + * @var string |
|
44 | + */ |
|
45 | + public static string $schemaTypeScope = 'https://schema.org/Nonprofit501c23'; |
|
46 | + |
|
47 | + /** |
|
48 | + * The Schema.org Type Extends |
|
49 | + * |
|
50 | + * @var string |
|
51 | + */ |
|
52 | + public static string $schemaTypeExtends = 'USNonprofitType'; |
|
53 | + |
|
54 | + /** |
|
55 | + * The Schema.org Type Description |
|
56 | + * |
|
57 | + * @var string |
|
58 | + */ |
|
59 | + public static string $schemaTypeDescription = 'Nonprofit501c23: Non-profit type referring to Veterans Organizations.'; |
|
60 | + |
|
61 | + |
|
62 | + /** |
|
63 | + * @inheritdoc |
|
64 | + */ |
|
65 | + public function getSchemaPropertyNames(): array |
|
66 | + { |
|
67 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
68 | + } |
|
69 | + |
|
70 | + |
|
71 | + /** |
|
72 | + * @inheritdoc |
|
73 | + */ |
|
74 | + public function getSchemaPropertyExpectedTypes(): array |
|
75 | + { |
|
76 | + return [ |
|
77 | + 'additionalType' => ['URL'], |
|
78 | + 'alternateName' => ['Text'], |
|
79 | + 'description' => ['Text'], |
|
80 | + 'disambiguatingDescription' => ['Text'], |
|
81 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
82 | + 'image' => ['URL', 'ImageObject'], |
|
83 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
84 | + 'name' => ['Text'], |
|
85 | + 'potentialAction' => ['Action'], |
|
86 | + 'sameAs' => ['URL'], |
|
87 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
88 | + 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
89 | + 'url' => ['URL'] |
|
90 | + ]; |
|
91 | + } |
|
92 | + |
|
93 | + |
|
94 | + /** |
|
95 | + * @inheritdoc |
|
96 | + */ |
|
97 | + public function getSchemaPropertyDescriptions(): array |
|
98 | + { |
|
99 | + return [ |
|
100 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
101 | + 'alternateName' => 'An alias for the item.', |
|
102 | + 'description' => 'A description of the item.', |
|
103 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
104 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
105 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
106 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
107 | + 'name' => 'The name of the item.', |
|
108 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
109 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
110 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
111 | + 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
112 | + 'url' => 'URL of the item.' |
|
113 | + ]; |
|
114 | + } |
|
115 | + |
|
116 | + |
|
117 | + /** |
|
118 | + * @inheritdoc |
|
119 | + */ |
|
120 | + public function getGoogleRequiredSchema(): array |
|
121 | + { |
|
122 | + return ['description', 'name']; |
|
123 | + } |
|
124 | + |
|
125 | + |
|
126 | + /** |
|
127 | + * @inheritdoc |
|
128 | + */ |
|
129 | + public function getGoogleRecommendedSchema(): array |
|
130 | + { |
|
131 | + return ['image', 'url']; |
|
132 | + } |
|
133 | + |
|
134 | + |
|
135 | + /** |
|
136 | + * @inheritdoc |
|
137 | + */ |
|
138 | + public function defineRules(): array |
|
139 | + { |
|
140 | + $rules = parent::defineRules(); |
|
141 | + $rules = array_merge($rules, [ |
|
142 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
143 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
144 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
145 | + ]); |
|
146 | + |
|
147 | + return $rules; |
|
148 | + } |
|
149 | 149 | } |
@@ -23,126 +23,126 @@ |
||
23 | 23 | */ |
24 | 24 | class ReadPermission extends MetaJsonLd implements ReadPermissionInterface, DigitalDocumentPermissionTypeInterface, EnumerationInterface, IntangibleInterface, ThingInterface |
25 | 25 | { |
26 | - use ReadPermissionTrait; |
|
27 | - use DigitalDocumentPermissionTypeTrait; |
|
28 | - use EnumerationTrait; |
|
29 | - use IntangibleTrait; |
|
30 | - use ThingTrait; |
|
31 | - |
|
32 | - /** |
|
33 | - * The Schema.org Type Name |
|
34 | - * |
|
35 | - * @var string |
|
36 | - */ |
|
37 | - public static string $schemaTypeName = 'ReadPermission'; |
|
38 | - |
|
39 | - /** |
|
40 | - * The Schema.org Type Scope |
|
41 | - * |
|
42 | - * @var string |
|
43 | - */ |
|
44 | - public static string $schemaTypeScope = 'https://schema.org/ReadPermission'; |
|
45 | - |
|
46 | - /** |
|
47 | - * The Schema.org Type Extends |
|
48 | - * |
|
49 | - * @var string |
|
50 | - */ |
|
51 | - public static string $schemaTypeExtends = 'DigitalDocumentPermissionType'; |
|
52 | - |
|
53 | - /** |
|
54 | - * The Schema.org Type Description |
|
55 | - * |
|
56 | - * @var string |
|
57 | - */ |
|
58 | - public static string $schemaTypeDescription = 'Permission to read or view the document.'; |
|
59 | - |
|
60 | - |
|
61 | - /** |
|
62 | - * @inheritdoc |
|
63 | - */ |
|
64 | - public function getSchemaPropertyNames(): array |
|
65 | - { |
|
66 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
67 | - } |
|
68 | - |
|
69 | - |
|
70 | - /** |
|
71 | - * @inheritdoc |
|
72 | - */ |
|
73 | - public function getSchemaPropertyExpectedTypes(): array |
|
74 | - { |
|
75 | - return [ |
|
76 | - 'additionalType' => ['URL'], |
|
77 | - 'alternateName' => ['Text'], |
|
78 | - 'description' => ['Text'], |
|
79 | - 'disambiguatingDescription' => ['Text'], |
|
80 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
81 | - 'image' => ['URL', 'ImageObject'], |
|
82 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
83 | - 'name' => ['Text'], |
|
84 | - 'potentialAction' => ['Action'], |
|
85 | - 'sameAs' => ['URL'], |
|
86 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
87 | - 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
88 | - 'url' => ['URL'] |
|
89 | - ]; |
|
90 | - } |
|
91 | - |
|
92 | - |
|
93 | - /** |
|
94 | - * @inheritdoc |
|
95 | - */ |
|
96 | - public function getSchemaPropertyDescriptions(): array |
|
97 | - { |
|
98 | - return [ |
|
99 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
100 | - 'alternateName' => 'An alias for the item.', |
|
101 | - 'description' => 'A description of the item.', |
|
102 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
103 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
104 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
105 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
106 | - 'name' => 'The name of the item.', |
|
107 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
108 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
109 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
110 | - 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
111 | - 'url' => 'URL of the item.' |
|
112 | - ]; |
|
113 | - } |
|
114 | - |
|
115 | - |
|
116 | - /** |
|
117 | - * @inheritdoc |
|
118 | - */ |
|
119 | - public function getGoogleRequiredSchema(): array |
|
120 | - { |
|
121 | - return ['description', 'name']; |
|
122 | - } |
|
123 | - |
|
124 | - |
|
125 | - /** |
|
126 | - * @inheritdoc |
|
127 | - */ |
|
128 | - public function getGoogleRecommendedSchema(): array |
|
129 | - { |
|
130 | - return ['image', 'url']; |
|
131 | - } |
|
132 | - |
|
133 | - |
|
134 | - /** |
|
135 | - * @inheritdoc |
|
136 | - */ |
|
137 | - public function defineRules(): array |
|
138 | - { |
|
139 | - $rules = parent::defineRules(); |
|
140 | - $rules = array_merge($rules, [ |
|
141 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
142 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
143 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
144 | - ]); |
|
145 | - |
|
146 | - return $rules; |
|
147 | - } |
|
26 | + use ReadPermissionTrait; |
|
27 | + use DigitalDocumentPermissionTypeTrait; |
|
28 | + use EnumerationTrait; |
|
29 | + use IntangibleTrait; |
|
30 | + use ThingTrait; |
|
31 | + |
|
32 | + /** |
|
33 | + * The Schema.org Type Name |
|
34 | + * |
|
35 | + * @var string |
|
36 | + */ |
|
37 | + public static string $schemaTypeName = 'ReadPermission'; |
|
38 | + |
|
39 | + /** |
|
40 | + * The Schema.org Type Scope |
|
41 | + * |
|
42 | + * @var string |
|
43 | + */ |
|
44 | + public static string $schemaTypeScope = 'https://schema.org/ReadPermission'; |
|
45 | + |
|
46 | + /** |
|
47 | + * The Schema.org Type Extends |
|
48 | + * |
|
49 | + * @var string |
|
50 | + */ |
|
51 | + public static string $schemaTypeExtends = 'DigitalDocumentPermissionType'; |
|
52 | + |
|
53 | + /** |
|
54 | + * The Schema.org Type Description |
|
55 | + * |
|
56 | + * @var string |
|
57 | + */ |
|
58 | + public static string $schemaTypeDescription = 'Permission to read or view the document.'; |
|
59 | + |
|
60 | + |
|
61 | + /** |
|
62 | + * @inheritdoc |
|
63 | + */ |
|
64 | + public function getSchemaPropertyNames(): array |
|
65 | + { |
|
66 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
67 | + } |
|
68 | + |
|
69 | + |
|
70 | + /** |
|
71 | + * @inheritdoc |
|
72 | + */ |
|
73 | + public function getSchemaPropertyExpectedTypes(): array |
|
74 | + { |
|
75 | + return [ |
|
76 | + 'additionalType' => ['URL'], |
|
77 | + 'alternateName' => ['Text'], |
|
78 | + 'description' => ['Text'], |
|
79 | + 'disambiguatingDescription' => ['Text'], |
|
80 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
81 | + 'image' => ['URL', 'ImageObject'], |
|
82 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
83 | + 'name' => ['Text'], |
|
84 | + 'potentialAction' => ['Action'], |
|
85 | + 'sameAs' => ['URL'], |
|
86 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
87 | + 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
88 | + 'url' => ['URL'] |
|
89 | + ]; |
|
90 | + } |
|
91 | + |
|
92 | + |
|
93 | + /** |
|
94 | + * @inheritdoc |
|
95 | + */ |
|
96 | + public function getSchemaPropertyDescriptions(): array |
|
97 | + { |
|
98 | + return [ |
|
99 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
100 | + 'alternateName' => 'An alias for the item.', |
|
101 | + 'description' => 'A description of the item.', |
|
102 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
103 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
104 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
105 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
106 | + 'name' => 'The name of the item.', |
|
107 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
108 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
109 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
110 | + 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
111 | + 'url' => 'URL of the item.' |
|
112 | + ]; |
|
113 | + } |
|
114 | + |
|
115 | + |
|
116 | + /** |
|
117 | + * @inheritdoc |
|
118 | + */ |
|
119 | + public function getGoogleRequiredSchema(): array |
|
120 | + { |
|
121 | + return ['description', 'name']; |
|
122 | + } |
|
123 | + |
|
124 | + |
|
125 | + /** |
|
126 | + * @inheritdoc |
|
127 | + */ |
|
128 | + public function getGoogleRecommendedSchema(): array |
|
129 | + { |
|
130 | + return ['image', 'url']; |
|
131 | + } |
|
132 | + |
|
133 | + |
|
134 | + /** |
|
135 | + * @inheritdoc |
|
136 | + */ |
|
137 | + public function defineRules(): array |
|
138 | + { |
|
139 | + $rules = parent::defineRules(); |
|
140 | + $rules = array_merge($rules, [ |
|
141 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
142 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
143 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
144 | + ]); |
|
145 | + |
|
146 | + return $rules; |
|
147 | + } |
|
148 | 148 | } |
@@ -23,127 +23,127 @@ |
||
23 | 23 | */ |
24 | 24 | class Nonprofit501c24 extends MetaJsonLd implements Nonprofit501c24Interface, USNonprofitTypeInterface, NonprofitTypeInterface, EnumerationInterface, IntangibleInterface, ThingInterface |
25 | 25 | { |
26 | - use Nonprofit501c24Trait; |
|
27 | - use USNonprofitTypeTrait; |
|
28 | - use NonprofitTypeTrait; |
|
29 | - use EnumerationTrait; |
|
30 | - use IntangibleTrait; |
|
31 | - use ThingTrait; |
|
32 | - |
|
33 | - /** |
|
34 | - * The Schema.org Type Name |
|
35 | - * |
|
36 | - * @var string |
|
37 | - */ |
|
38 | - public static string $schemaTypeName = 'Nonprofit501c24'; |
|
39 | - |
|
40 | - /** |
|
41 | - * The Schema.org Type Scope |
|
42 | - * |
|
43 | - * @var string |
|
44 | - */ |
|
45 | - public static string $schemaTypeScope = 'https://schema.org/Nonprofit501c24'; |
|
46 | - |
|
47 | - /** |
|
48 | - * The Schema.org Type Extends |
|
49 | - * |
|
50 | - * @var string |
|
51 | - */ |
|
52 | - public static string $schemaTypeExtends = 'USNonprofitType'; |
|
53 | - |
|
54 | - /** |
|
55 | - * The Schema.org Type Description |
|
56 | - * |
|
57 | - * @var string |
|
58 | - */ |
|
59 | - public static string $schemaTypeDescription = 'Nonprofit501c24: Non-profit type referring to Section 4049 ERISA Trusts.'; |
|
60 | - |
|
61 | - |
|
62 | - /** |
|
63 | - * @inheritdoc |
|
64 | - */ |
|
65 | - public function getSchemaPropertyNames(): array |
|
66 | - { |
|
67 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
68 | - } |
|
69 | - |
|
70 | - |
|
71 | - /** |
|
72 | - * @inheritdoc |
|
73 | - */ |
|
74 | - public function getSchemaPropertyExpectedTypes(): array |
|
75 | - { |
|
76 | - return [ |
|
77 | - 'additionalType' => ['URL'], |
|
78 | - 'alternateName' => ['Text'], |
|
79 | - 'description' => ['Text'], |
|
80 | - 'disambiguatingDescription' => ['Text'], |
|
81 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
82 | - 'image' => ['URL', 'ImageObject'], |
|
83 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
84 | - 'name' => ['Text'], |
|
85 | - 'potentialAction' => ['Action'], |
|
86 | - 'sameAs' => ['URL'], |
|
87 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
88 | - 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
89 | - 'url' => ['URL'] |
|
90 | - ]; |
|
91 | - } |
|
92 | - |
|
93 | - |
|
94 | - /** |
|
95 | - * @inheritdoc |
|
96 | - */ |
|
97 | - public function getSchemaPropertyDescriptions(): array |
|
98 | - { |
|
99 | - return [ |
|
100 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
101 | - 'alternateName' => 'An alias for the item.', |
|
102 | - 'description' => 'A description of the item.', |
|
103 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
104 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
105 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
106 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
107 | - 'name' => 'The name of the item.', |
|
108 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
109 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
110 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
111 | - 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
112 | - 'url' => 'URL of the item.' |
|
113 | - ]; |
|
114 | - } |
|
115 | - |
|
116 | - |
|
117 | - /** |
|
118 | - * @inheritdoc |
|
119 | - */ |
|
120 | - public function getGoogleRequiredSchema(): array |
|
121 | - { |
|
122 | - return ['description', 'name']; |
|
123 | - } |
|
124 | - |
|
125 | - |
|
126 | - /** |
|
127 | - * @inheritdoc |
|
128 | - */ |
|
129 | - public function getGoogleRecommendedSchema(): array |
|
130 | - { |
|
131 | - return ['image', 'url']; |
|
132 | - } |
|
133 | - |
|
134 | - |
|
135 | - /** |
|
136 | - * @inheritdoc |
|
137 | - */ |
|
138 | - public function defineRules(): array |
|
139 | - { |
|
140 | - $rules = parent::defineRules(); |
|
141 | - $rules = array_merge($rules, [ |
|
142 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
143 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
144 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
145 | - ]); |
|
146 | - |
|
147 | - return $rules; |
|
148 | - } |
|
26 | + use Nonprofit501c24Trait; |
|
27 | + use USNonprofitTypeTrait; |
|
28 | + use NonprofitTypeTrait; |
|
29 | + use EnumerationTrait; |
|
30 | + use IntangibleTrait; |
|
31 | + use ThingTrait; |
|
32 | + |
|
33 | + /** |
|
34 | + * The Schema.org Type Name |
|
35 | + * |
|
36 | + * @var string |
|
37 | + */ |
|
38 | + public static string $schemaTypeName = 'Nonprofit501c24'; |
|
39 | + |
|
40 | + /** |
|
41 | + * The Schema.org Type Scope |
|
42 | + * |
|
43 | + * @var string |
|
44 | + */ |
|
45 | + public static string $schemaTypeScope = 'https://schema.org/Nonprofit501c24'; |
|
46 | + |
|
47 | + /** |
|
48 | + * The Schema.org Type Extends |
|
49 | + * |
|
50 | + * @var string |
|
51 | + */ |
|
52 | + public static string $schemaTypeExtends = 'USNonprofitType'; |
|
53 | + |
|
54 | + /** |
|
55 | + * The Schema.org Type Description |
|
56 | + * |
|
57 | + * @var string |
|
58 | + */ |
|
59 | + public static string $schemaTypeDescription = 'Nonprofit501c24: Non-profit type referring to Section 4049 ERISA Trusts.'; |
|
60 | + |
|
61 | + |
|
62 | + /** |
|
63 | + * @inheritdoc |
|
64 | + */ |
|
65 | + public function getSchemaPropertyNames(): array |
|
66 | + { |
|
67 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
68 | + } |
|
69 | + |
|
70 | + |
|
71 | + /** |
|
72 | + * @inheritdoc |
|
73 | + */ |
|
74 | + public function getSchemaPropertyExpectedTypes(): array |
|
75 | + { |
|
76 | + return [ |
|
77 | + 'additionalType' => ['URL'], |
|
78 | + 'alternateName' => ['Text'], |
|
79 | + 'description' => ['Text'], |
|
80 | + 'disambiguatingDescription' => ['Text'], |
|
81 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
82 | + 'image' => ['URL', 'ImageObject'], |
|
83 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
84 | + 'name' => ['Text'], |
|
85 | + 'potentialAction' => ['Action'], |
|
86 | + 'sameAs' => ['URL'], |
|
87 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
88 | + 'supersededBy' => ['Class', 'Property', 'Enumeration'], |
|
89 | + 'url' => ['URL'] |
|
90 | + ]; |
|
91 | + } |
|
92 | + |
|
93 | + |
|
94 | + /** |
|
95 | + * @inheritdoc |
|
96 | + */ |
|
97 | + public function getSchemaPropertyDescriptions(): array |
|
98 | + { |
|
99 | + return [ |
|
100 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
101 | + 'alternateName' => 'An alias for the item.', |
|
102 | + 'description' => 'A description of the item.', |
|
103 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
104 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
105 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
106 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
107 | + 'name' => 'The name of the item.', |
|
108 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
109 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
110 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
111 | + 'supersededBy' => 'Relates a term (i.e. a property, class or enumeration) to one that supersedes it.', |
|
112 | + 'url' => 'URL of the item.' |
|
113 | + ]; |
|
114 | + } |
|
115 | + |
|
116 | + |
|
117 | + /** |
|
118 | + * @inheritdoc |
|
119 | + */ |
|
120 | + public function getGoogleRequiredSchema(): array |
|
121 | + { |
|
122 | + return ['description', 'name']; |
|
123 | + } |
|
124 | + |
|
125 | + |
|
126 | + /** |
|
127 | + * @inheritdoc |
|
128 | + */ |
|
129 | + public function getGoogleRecommendedSchema(): array |
|
130 | + { |
|
131 | + return ['image', 'url']; |
|
132 | + } |
|
133 | + |
|
134 | + |
|
135 | + /** |
|
136 | + * @inheritdoc |
|
137 | + */ |
|
138 | + public function defineRules(): array |
|
139 | + { |
|
140 | + $rules = parent::defineRules(); |
|
141 | + $rules = array_merge($rules, [ |
|
142 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
143 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
144 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
145 | + ]); |
|
146 | + |
|
147 | + return $rules; |
|
148 | + } |
|
149 | 149 | } |
@@ -24,130 +24,130 @@ |
||
24 | 24 | */ |
25 | 25 | class Brand extends MetaJsonLd implements BrandInterface, IntangibleInterface, ThingInterface |
26 | 26 | { |
27 | - use BrandTrait; |
|
28 | - use IntangibleTrait; |
|
29 | - use ThingTrait; |
|
30 | - |
|
31 | - /** |
|
32 | - * The Schema.org Type Name |
|
33 | - * |
|
34 | - * @var string |
|
35 | - */ |
|
36 | - public static string $schemaTypeName = 'Brand'; |
|
37 | - |
|
38 | - /** |
|
39 | - * The Schema.org Type Scope |
|
40 | - * |
|
41 | - * @var string |
|
42 | - */ |
|
43 | - public static string $schemaTypeScope = 'https://schema.org/Brand'; |
|
44 | - |
|
45 | - /** |
|
46 | - * The Schema.org Type Extends |
|
47 | - * |
|
48 | - * @var string |
|
49 | - */ |
|
50 | - public static string $schemaTypeExtends = 'Intangible'; |
|
51 | - |
|
52 | - /** |
|
53 | - * The Schema.org Type Description |
|
54 | - * |
|
55 | - * @var string |
|
56 | - */ |
|
57 | - public static string $schemaTypeDescription = 'A brand is a name used by an organization or business person for labeling a product, product group, or similar.'; |
|
58 | - |
|
59 | - |
|
60 | - /** |
|
61 | - * @inheritdoc |
|
62 | - */ |
|
63 | - public function getSchemaPropertyNames(): array |
|
64 | - { |
|
65 | - return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
66 | - } |
|
67 | - |
|
68 | - |
|
69 | - /** |
|
70 | - * @inheritdoc |
|
71 | - */ |
|
72 | - public function getSchemaPropertyExpectedTypes(): array |
|
73 | - { |
|
74 | - return [ |
|
75 | - 'additionalType' => ['URL'], |
|
76 | - 'aggregateRating' => ['AggregateRating'], |
|
77 | - 'alternateName' => ['Text'], |
|
78 | - 'description' => ['Text'], |
|
79 | - 'disambiguatingDescription' => ['Text'], |
|
80 | - 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
81 | - 'image' => ['URL', 'ImageObject'], |
|
82 | - 'logo' => ['ImageObject', 'URL'], |
|
83 | - 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
84 | - 'name' => ['Text'], |
|
85 | - 'potentialAction' => ['Action'], |
|
86 | - 'review' => ['Review'], |
|
87 | - 'sameAs' => ['URL'], |
|
88 | - 'slogan' => ['Text'], |
|
89 | - 'subjectOf' => ['Event', 'CreativeWork'], |
|
90 | - 'url' => ['URL'] |
|
91 | - ]; |
|
92 | - } |
|
93 | - |
|
94 | - |
|
95 | - /** |
|
96 | - * @inheritdoc |
|
97 | - */ |
|
98 | - public function getSchemaPropertyDescriptions(): array |
|
99 | - { |
|
100 | - return [ |
|
101 | - 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
102 | - 'aggregateRating' => 'The overall rating, based on a collection of reviews or ratings, of the item.', |
|
103 | - 'alternateName' => 'An alias for the item.', |
|
104 | - 'description' => 'A description of the item.', |
|
105 | - 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
106 | - 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
107 | - 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
108 | - 'logo' => 'An associated logo.', |
|
109 | - 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
110 | - 'name' => 'The name of the item.', |
|
111 | - 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
112 | - 'review' => 'A review of the item.', |
|
113 | - 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
114 | - 'slogan' => 'A slogan or motto associated with the item.', |
|
115 | - 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
116 | - 'url' => 'URL of the item.' |
|
117 | - ]; |
|
118 | - } |
|
119 | - |
|
120 | - |
|
121 | - /** |
|
122 | - * @inheritdoc |
|
123 | - */ |
|
124 | - public function getGoogleRequiredSchema(): array |
|
125 | - { |
|
126 | - return ['description', 'name']; |
|
127 | - } |
|
128 | - |
|
129 | - |
|
130 | - /** |
|
131 | - * @inheritdoc |
|
132 | - */ |
|
133 | - public function getGoogleRecommendedSchema(): array |
|
134 | - { |
|
135 | - return ['image', 'url']; |
|
136 | - } |
|
137 | - |
|
138 | - |
|
139 | - /** |
|
140 | - * @inheritdoc |
|
141 | - */ |
|
142 | - public function defineRules(): array |
|
143 | - { |
|
144 | - $rules = parent::defineRules(); |
|
145 | - $rules = array_merge($rules, [ |
|
146 | - [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
147 | - [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
148 | - [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
149 | - ]); |
|
150 | - |
|
151 | - return $rules; |
|
152 | - } |
|
27 | + use BrandTrait; |
|
28 | + use IntangibleTrait; |
|
29 | + use ThingTrait; |
|
30 | + |
|
31 | + /** |
|
32 | + * The Schema.org Type Name |
|
33 | + * |
|
34 | + * @var string |
|
35 | + */ |
|
36 | + public static string $schemaTypeName = 'Brand'; |
|
37 | + |
|
38 | + /** |
|
39 | + * The Schema.org Type Scope |
|
40 | + * |
|
41 | + * @var string |
|
42 | + */ |
|
43 | + public static string $schemaTypeScope = 'https://schema.org/Brand'; |
|
44 | + |
|
45 | + /** |
|
46 | + * The Schema.org Type Extends |
|
47 | + * |
|
48 | + * @var string |
|
49 | + */ |
|
50 | + public static string $schemaTypeExtends = 'Intangible'; |
|
51 | + |
|
52 | + /** |
|
53 | + * The Schema.org Type Description |
|
54 | + * |
|
55 | + * @var string |
|
56 | + */ |
|
57 | + public static string $schemaTypeDescription = 'A brand is a name used by an organization or business person for labeling a product, product group, or similar.'; |
|
58 | + |
|
59 | + |
|
60 | + /** |
|
61 | + * @inheritdoc |
|
62 | + */ |
|
63 | + public function getSchemaPropertyNames(): array |
|
64 | + { |
|
65 | + return array_keys($this->getSchemaPropertyExpectedTypes()); |
|
66 | + } |
|
67 | + |
|
68 | + |
|
69 | + /** |
|
70 | + * @inheritdoc |
|
71 | + */ |
|
72 | + public function getSchemaPropertyExpectedTypes(): array |
|
73 | + { |
|
74 | + return [ |
|
75 | + 'additionalType' => ['URL'], |
|
76 | + 'aggregateRating' => ['AggregateRating'], |
|
77 | + 'alternateName' => ['Text'], |
|
78 | + 'description' => ['Text'], |
|
79 | + 'disambiguatingDescription' => ['Text'], |
|
80 | + 'identifier' => ['PropertyValue', 'URL', 'Text'], |
|
81 | + 'image' => ['URL', 'ImageObject'], |
|
82 | + 'logo' => ['ImageObject', 'URL'], |
|
83 | + 'mainEntityOfPage' => ['URL', 'CreativeWork'], |
|
84 | + 'name' => ['Text'], |
|
85 | + 'potentialAction' => ['Action'], |
|
86 | + 'review' => ['Review'], |
|
87 | + 'sameAs' => ['URL'], |
|
88 | + 'slogan' => ['Text'], |
|
89 | + 'subjectOf' => ['Event', 'CreativeWork'], |
|
90 | + 'url' => ['URL'] |
|
91 | + ]; |
|
92 | + } |
|
93 | + |
|
94 | + |
|
95 | + /** |
|
96 | + * @inheritdoc |
|
97 | + */ |
|
98 | + public function getSchemaPropertyDescriptions(): array |
|
99 | + { |
|
100 | + return [ |
|
101 | + 'additionalType' => 'An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. This is a relationship between something and a class that the thing is in. In RDFa syntax, it is better to use the native RDFa syntax - the \'typeof\' attribute - for multiple types. Schema.org tools may have only weaker understanding of extra types, in particular those defined externally.', |
|
102 | + 'aggregateRating' => 'The overall rating, based on a collection of reviews or ratings, of the item.', |
|
103 | + 'alternateName' => 'An alias for the item.', |
|
104 | + 'description' => 'A description of the item.', |
|
105 | + 'disambiguatingDescription' => 'A sub property of description. A short description of the item used to disambiguate from other, similar items. Information from other properties (in particular, name) may be necessary for the description to be useful for disambiguation.', |
|
106 | + 'identifier' => 'The identifier property represents any kind of identifier for any kind of [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides dedicated properties for representing many of these, either as textual strings or as URL (URI) links. See [background notes](/docs/datamodel.html#identifierBg) for more details. ', |
|
107 | + 'image' => 'An image of the item. This can be a [[URL]] or a fully described [[ImageObject]].', |
|
108 | + 'logo' => 'An associated logo.', |
|
109 | + 'mainEntityOfPage' => 'Indicates a page (or other CreativeWork) for which this thing is the main entity being described. See [background notes](/docs/datamodel.html#mainEntityBackground) for details.', |
|
110 | + 'name' => 'The name of the item.', |
|
111 | + 'potentialAction' => 'Indicates a potential Action, which describes an idealized action in which this thing would play an \'object\' role.', |
|
112 | + 'review' => 'A review of the item.', |
|
113 | + 'sameAs' => 'URL of a reference Web page that unambiguously indicates the item\'s identity. E.g. the URL of the item\'s Wikipedia page, Wikidata entry, or official website.', |
|
114 | + 'slogan' => 'A slogan or motto associated with the item.', |
|
115 | + 'subjectOf' => 'A CreativeWork or Event about this Thing.', |
|
116 | + 'url' => 'URL of the item.' |
|
117 | + ]; |
|
118 | + } |
|
119 | + |
|
120 | + |
|
121 | + /** |
|
122 | + * @inheritdoc |
|
123 | + */ |
|
124 | + public function getGoogleRequiredSchema(): array |
|
125 | + { |
|
126 | + return ['description', 'name']; |
|
127 | + } |
|
128 | + |
|
129 | + |
|
130 | + /** |
|
131 | + * @inheritdoc |
|
132 | + */ |
|
133 | + public function getGoogleRecommendedSchema(): array |
|
134 | + { |
|
135 | + return ['image', 'url']; |
|
136 | + } |
|
137 | + |
|
138 | + |
|
139 | + /** |
|
140 | + * @inheritdoc |
|
141 | + */ |
|
142 | + public function defineRules(): array |
|
143 | + { |
|
144 | + $rules = parent::defineRules(); |
|
145 | + $rules = array_merge($rules, [ |
|
146 | + [$this->getSchemaPropertyNames(), 'validateJsonSchema'], |
|
147 | + [$this->getGoogleRequiredSchema(), 'required', 'on' => ['google'], 'message' => 'This property is required by Google.'], |
|
148 | + [$this->getGoogleRecommendedSchema(), 'required', 'on' => ['google'], 'message' => 'This property is recommended by Google.'] |
|
149 | + ]); |
|
150 | + |
|
151 | + return $rules; |
|
152 | + } |
|
153 | 153 | } |