Class luya\web\jsonld\CreativeWork
Inheritance | luya\web\jsonld\CreativeWork » luya\web\jsonld\BaseThing » yii\base\BaseObject |
---|---|
Implements | luya\web\jsonld\CreativeWorkInterface, luya\web\jsonld\ThingInterface, yii\base\Arrayable, yii\base\Configurable |
Uses Traits | luya\web\jsonld\CreativeWorkTrait, luya\web\jsonld\ThingTrait, yii\base\ArrayableTrait |
Subclasses | luya\web\jsonld\Review |
Available since version | 1.0.1 |
Source Code | https://github.com/luyadev/luya/blob/master/core/web/jsonld/CreativeWork.php |
JsonLd - Creative Work
The most generic kind of creative work, including books, movies, photographs, software programs, etc.
See also http://schema.org/CreativeWork.
Public Properties
Public Methods
Method | Description | Defined By |
---|---|---|
__call() | Calls the named method which is not a class method. | yii\base\BaseObject |
__construct() | Constructor. | yii\base\BaseObject |
__get() | Returns the value of an object property. | yii\base\BaseObject |
__isset() | Checks if a property is set, i.e. defined and not null. | yii\base\BaseObject |
__set() | Sets value of an object property. | yii\base\BaseObject |
__unset() | Sets an object property to null. | yii\base\BaseObject |
canGetProperty() | Returns a value indicating whether a property can be read. | yii\base\BaseObject |
canSetProperty() | Returns a value indicating whether a property can be set. | yii\base\BaseObject |
className() | Returns the fully qualified name of this class. | yii\base\BaseObject |
extraFields() | Returns the list of fields that can be expanded further and returned by toArray(). | yii\base\ArrayableTrait |
fields() | Returns the list of fields that should be returned by default by toArray() when no specific fields are specified. | luya\web\jsonld\BaseThing |
getAbout() | luya\web\jsonld\CreativeWorkTrait | |
getAccessMode() | luya\web\jsonld\CreativeWorkTrait | |
getAccessModeSufficient() | luya\web\jsonld\CreativeWorkTrait | |
getAccessibilityAPI() | luya\web\jsonld\CreativeWorkTrait | |
getAccessibilityControl() | luya\web\jsonld\CreativeWorkTrait | |
getAccessibilityFeature() | luya\web\jsonld\CreativeWorkTrait | |
getAccessibilityHazard() | luya\web\jsonld\CreativeWorkTrait | |
getAccessibilitySummary() | luya\web\jsonld\CreativeWorkTrait | |
getAccountablePerson() | luya\web\jsonld\CreativeWorkTrait | |
getAdditionalType() | luya\web\jsonld\ThingTrait | |
getAlternateName() | luya\web\jsonld\ThingTrait | |
getAlternativeHeadline() | luya\web\jsonld\CreativeWorkTrait | |
getAssociatedMedia() | luya\web\jsonld\CreativeWorkTrait | |
getAuthor() | luya\web\jsonld\CreativeWorkTrait | |
getAward() | luya\web\jsonld\CreativeWorkTrait | |
getCharacter() | luya\web\jsonld\CreativeWorkTrait | |
getCitation() | luya\web\jsonld\CreativeWorkTrait | |
getComment() | luya\web\jsonld\CreativeWorkTrait | |
getCommentCount() | luya\web\jsonld\CreativeWorkTrait | |
getContentLocation() | luya\web\jsonld\CreativeWorkTrait | |
getContentRating() | luya\web\jsonld\CreativeWorkTrait | |
getContentReferenceTime() | luya\web\jsonld\CreativeWorkTrait | |
getContributor() | luya\web\jsonld\CreativeWorkTrait | |
getCopyrightHolder() | luya\web\jsonld\CreativeWorkTrait | |
getCopyrightYear() | luya\web\jsonld\CreativeWorkTrait | |
getCreator() | luya\web\jsonld\CreativeWorkTrait | |
getDateCreated() | luya\web\jsonld\CreativeWorkTrait | |
getDateModified() | luya\web\jsonld\CreativeWorkTrait | |
getDatePublished() | luya\web\jsonld\CreativeWorkTrait | |
getDescription() | luya\web\jsonld\ThingTrait | |
getDisambiguatingDescription() | luya\web\jsonld\ThingTrait | |
getDiscussionUrl() | luya\web\jsonld\CreativeWorkTrait | |
getEditor() | luya\web\jsonld\CreativeWorkTrait | |
getEducationalUse() | luya\web\jsonld\CreativeWorkTrait | |
getEncoding() | luya\web\jsonld\CreativeWorkTrait | |
getExampleOfWork() | luya\web\jsonld\CreativeWorkTrait | |
getExpires() | luya\web\jsonld\CreativeWorkTrait | |
getFileFormat() | luya\web\jsonld\CreativeWorkTrait | |
getFunder() | luya\web\jsonld\CreativeWorkTrait | |
getGenre() | luya\web\jsonld\CreativeWorkTrait | |
getHasPart() | luya\web\jsonld\CreativeWorkTrait | |
getHeadline() | luya\web\jsonld\CreativeWorkTrait | |
getIdentifier() | luya\web\jsonld\ThingTrait | |
getImage() | luya\web\jsonld\ThingTrait | |
getInteractivityType() | luya\web\jsonld\CreativeWorkTrait | |
getKeywords() | luya\web\jsonld\CreativeWorkTrait | |
getLearningResourceType() | luya\web\jsonld\CreativeWorkTrait | |
getLocationCreated() | luya\web\jsonld\CreativeWorkTrait | |
getMainEntity() | luya\web\jsonld\CreativeWorkTrait | |
getMainEntityOfPage() | luya\web\jsonld\ThingTrait | |
getMentions() | luya\web\jsonld\CreativeWorkTrait | |
getName() | luya\web\jsonld\ThingTrait | |
getOffers() | Get Offer | luya\web\jsonld\ThingTrait |
getPosition() | luya\web\jsonld\CreativeWorkTrait | |
getProducer() | luya\web\jsonld\CreativeWorkTrait | |
getProvider() | luya\web\jsonld\CreativeWorkTrait | |
getPublisher() | luya\web\jsonld\CreativeWorkTrait | |
getPublisherImprint() | luya\web\jsonld\CreativeWorkTrait | |
getPublishingPrinciples() | luya\web\jsonld\CreativeWorkTrait | |
getRecordedAt() | luya\web\jsonld\CreativeWorkTrait | |
getSameAs() | luya\web\jsonld\ThingTrait | |
getSchemaVersion() | luya\web\jsonld\CreativeWorkTrait | |
getSourceOrganization() | luya\web\jsonld\CreativeWorkTrait | |
getSpatialCoverage() | luya\web\jsonld\CreativeWorkTrait | |
getSponsor() | luya\web\jsonld\CreativeWorkTrait | |
getSubjectOf() | luya\web\jsonld\ThingTrait | |
getTemporalCoverage() | luya\web\jsonld\CreativeWorkTrait | |
getText() | luya\web\jsonld\CreativeWorkTrait | |
getThumbnailUrl() | luya\web\jsonld\CreativeWorkTrait | |
getTranslationOfWork() | luya\web\jsonld\CreativeWorkTrait | |
getTranslator() | luya\web\jsonld\CreativeWorkTrait | |
getTypicalAgeRange() | luya\web\jsonld\CreativeWorkTrait | |
getUrl() | luya\web\jsonld\ThingTrait | |
getVersion() | luya\web\jsonld\CreativeWorkTrait | |
getWorkExample() | luya\web\jsonld\CreativeWorkTrait | |
getWorkTranslation() | luya\web\jsonld\CreativeWorkTrait | |
getisPartOf() | luya\web\jsonld\CreativeWorkTrait | |
hasMethod() | Returns a value indicating whether a method is defined. | yii\base\BaseObject |
hasProperty() | Returns a value indicating whether a property is defined. | yii\base\BaseObject |
init() | Initializes the object. | yii\base\BaseObject |
isAccessibleForFree() | luya\web\jsonld\CreativeWorkTrait | |
isFamilyFriendly() | luya\web\jsonld\CreativeWorkTrait | |
resolveGetterMethods() | Find all getter methods. | luya\web\jsonld\BaseThing |
setAbout() | The subject matter of the content. | luya\web\jsonld\CreativeWorkTrait |
setAccessMode() | The human sensory perceptual system or cognitive faculty through which a person may process or perceive information. | luya\web\jsonld\CreativeWorkTrait |
setAccessModeSufficient() | A list of single or combined accessModes that are sufficient to understand all the intellectual content of a resource. | luya\web\jsonld\CreativeWorkTrait |
setAccessibilityAPI() | Indicates that the resource is compatible with the referenced accessibility API (WebSchemas wiki lists possible values). | luya\web\jsonld\CreativeWorkTrait |
setAccessibilityControl() | Identifies input methods that are sufficient to fully control the described resource (WebSchemas wiki lists possible values). | luya\web\jsonld\CreativeWorkTrait |
setAccessibilityFeature() | Content features of the resource, such as accessible media, alternatives and supported enhancements for accessibility (WebSchemas wiki lists possible values). | luya\web\jsonld\CreativeWorkTrait |
setAccessibilityHazard() | A characteristic of the described resource that is physiologically dangerous to some users. | luya\web\jsonld\CreativeWorkTrait |
setAccessibilitySummary() | A human-readable summary of specific accessibility features or deficiencies, consistent with the other accessibility metadata but expressing subtleties such as "short descriptions are present but long descriptions will be needed for non-visual users" or "short descriptions are present and no long descriptions are needed." | luya\web\jsonld\CreativeWorkTrait |
setAccountablePerson() | Specifies the Person that is legally accountable for the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setAdditionalType() | An additional type for the item, typically used for adding more specific types from external vocabularies in microdata syntax. | luya\web\jsonld\ThingTrait |
setAlternateName() | An alias for the item | luya\web\jsonld\ThingTrait |
setAlternativeHeadline() | A secondary title of the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setAssociatedMedia() | A media object that encodes this CreativeWork. This property is a synonym for encoding. | luya\web\jsonld\CreativeWorkTrait |
setAuthor() | The author of this content or rating. Please note that author is special in that HTML 5 provides a special mechanism for indicating authorship via the rel tag. That is equivalent to this and may be used interchangeably. | luya\web\jsonld\CreativeWorkTrait |
setAward() | An award won by or for this item. | luya\web\jsonld\CreativeWorkTrait |
setCharacter() | Fictional person connected with a creative work. | luya\web\jsonld\CreativeWorkTrait |
setCitation() | A citation or reference to another creative work, such as another publication, web page, scholarly article, etc. | luya\web\jsonld\CreativeWorkTrait |
setComment() | Comments, typically from users. | luya\web\jsonld\CreativeWorkTrait |
setCommentCount() | The number of comments this CreativeWork (e.g. Article, Question or Answer) has received. This is most applicable to works published in Web sites with commenting system; additional comments may exist elsewhere. | luya\web\jsonld\CreativeWorkTrait |
setContentLocation() | The location depicted or described in the content. For example, the location in a photograph or painting. | luya\web\jsonld\CreativeWorkTrait |
setContentRating() | Official rating of a piece of content—for example,'MPAA PG-13'. | luya\web\jsonld\CreativeWorkTrait |
setContentReferenceTime() | The specific time described by a creative work, for works (e.g. articles, video objects etc.) that emphasise a particular moment within an Event. | luya\web\jsonld\CreativeWorkTrait |
setContributor() | A secondary contributor to the CreativeWork or Event. | luya\web\jsonld\CreativeWorkTrait |
setCopyrightHolder() | The party holding the legal copyright to the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setCopyrightYear() | The year during which the claimed copyright for the CreativeWork was first asserted. | luya\web\jsonld\CreativeWorkTrait |
setCreator() | The creator/author of this CreativeWork. This is the same as the Author property for CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setDateCreated() | The date on which the CreativeWork was created or the item was added to a DataFeed. | luya\web\jsonld\CreativeWorkTrait |
setDateModified() | The date on which the CreativeWork was most recently modified or when the item's entry was modified within a DataFeed. | luya\web\jsonld\CreativeWorkTrait |
setDatePublished() | Date of first broadcast/publication. | luya\web\jsonld\CreativeWorkTrait |
setDescription() | A description of the item. | luya\web\jsonld\ThingTrait |
setDisambiguatingDescription() | A sub property of description. A short description of the item used to disambiguate from other, similar items. | luya\web\jsonld\ThingTrait |
setDiscussionUrl() | A link to the page containing the comments of the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setEditor() | Specifies the Person who edited the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setEducationalUse() | The purpose of a work in the context of education; for example, 'assignment', 'group work'. | luya\web\jsonld\CreativeWorkTrait |
setEncoding() | A media object that encodes this CreativeWork. This property is a synonym for associatedMedia. | luya\web\jsonld\CreativeWorkTrait |
setExampleOfWork() | A creative work that this work is an example/instance/realization/derivation of. | luya\web\jsonld\CreativeWorkTrait |
setExpires() | Date the content expires and is no longer useful or available. For example a VideoObject or NewsArticle whose availability or relevance is time-limited, or a ClaimReview fact check whose publisher wants to indicate that it may no longer be relevant (or helpful to highlight) after some date. | luya\web\jsonld\CreativeWorkTrait |
setFileFormat() | Media type, typically MIME format (see IANA site) of the content e.g. application/zip of a SoftwareApplication binary. In cases where a CreativeWork has several media type representations, 'encoding' can be used to indicate each MediaObject alongside particular fileFormat information. Unregistered or niche file formats can be indicated instead via the most appropriate URL, e.g. defining Web page or a Wikipedia entry. | luya\web\jsonld\CreativeWorkTrait |
setFunder() | A person or organization that supports (sponsors) something through some kind of financial contribution. | luya\web\jsonld\CreativeWorkTrait |
setGenre() | Genre of the creative work, broadcast channel or group. | luya\web\jsonld\CreativeWorkTrait |
setHasPart() | Indicates a CreativeWork that is (in some sense) a part of this CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setHeadline() | Headline of the article. | luya\web\jsonld\CreativeWorkTrait |
setIdentifier() | 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 for more details. | luya\web\jsonld\ThingTrait |
setImage() | An image of the item. | luya\web\jsonld\ThingTrait |
setInteractivityType() | The predominant mode of learning supported by the learning resource. | luya\web\jsonld\CreativeWorkTrait |
setIsAccessibleForFree() | A flag to signal that the item, event, or place is accessible for free. | luya\web\jsonld\CreativeWorkTrait |
setIsFamilyFriendly() | Indicates whether this content is family friendly. | luya\web\jsonld\CreativeWorkTrait |
setIsPartOf() | Indicates a CreativeWork that this CreativeWork is (in some sense) part of. | luya\web\jsonld\CreativeWorkTrait |
setKeywords() | Keywords or tags used to describe this content. | luya\web\jsonld\CreativeWorkTrait |
setLearningResourceType() | The predominant type or kind characterizing the learning resource. For example, 'presentation', 'handout'. | luya\web\jsonld\CreativeWorkTrait |
setLocationCreated() | The location where the CreativeWork was created, which may not be the same as the location depicted in the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setMainEntity() | Indicates the primary entity described in some page or other CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setMainEntityOfPage() | Indicates a page (or other CreativeWork) for which this thing is the main entity being described. | luya\web\jsonld\ThingTrait |
setMentions() | Indicates that the CreativeWork contains a reference to, but is not necessarily about a concept. | luya\web\jsonld\CreativeWorkTrait |
setName() | The name of the item. | luya\web\jsonld\ThingTrait |
setOffers() | Set Offer | luya\web\jsonld\ThingTrait |
setPosition() | The position of an item in a series or sequence of items. | luya\web\jsonld\CreativeWorkTrait |
setProducer() | The person or organization who produced the work (e.g. music album, movie, tv/radio series etc.). | luya\web\jsonld\CreativeWorkTrait |
setProvider() | 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. | luya\web\jsonld\CreativeWorkTrait |
setPublisher() | The publisher of the creative work. | luya\web\jsonld\CreativeWorkTrait |
setPublisherImprint() | The publishing division which published the comic. | luya\web\jsonld\CreativeWorkTrait |
setPublishingPrinciples() | The publishingPrinciples property indicates (typically via URL) a document describing the editorial principles of an Organization (or individual e.g. a Person writing a blog) that relate to their activities as a publisher, e.g. ethics or diversity policies. When applied to a CreativeWork (e.g. NewsArticle) the principles are those of the party primarily responsible for the creation of the CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setRecordedAt() | The Event where the CreativeWork was recorded. The CreativeWork may capture all or part of the event. | luya\web\jsonld\CreativeWorkTrait |
setSameAs() | URL of a reference Web page that unambiguously indicates the item's identity. | luya\web\jsonld\ThingTrait |
setSchemaVersion() | Indicates (by URL or string) a particular version of a schema used in some CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setSourceOrganization() | The Organization on whose behalf the creator was working. | luya\web\jsonld\CreativeWorkTrait |
setSpatialCoverage() | The spatialCoverage of a CreativeWork indicates the place(s) which are the focus of the content. | luya\web\jsonld\CreativeWorkTrait |
setSponsor() | A person or organization that supports a thing through a pledge, promise, or financial contribution. | luya\web\jsonld\CreativeWorkTrait |
setSubjectOf() | A CreativeWork or Event about this Thing. | luya\web\jsonld\ThingTrait |
setTemporalCoverage() | The temporalCoverage of a CreativeWork indicates the period that the content applies to, i.e. that it describes, either as a DateTime or as a textual string indicating a time period in ISO 8601 time interval format. In the case of a Dataset it will typically indicate the relevant time period in a precise notation (e.g. for a 2011 census dataset, the year 2011 would be written "2011/2012"). Other forms of content e.g. ScholarlyArticle, Book, TVSeries or TVEpisode may indicate their temporalCoverage in broader terms - textually or via well-known URL. Written works such as books may sometimes have precise temporal coverage too, e.g. a work set in 1939 - 1945 can be indicated in ISO 8601 interval format format via "1939/1945". | luya\web\jsonld\CreativeWorkTrait |
setText() | The textual content of this CreativeWork. | luya\web\jsonld\CreativeWorkTrait |
setThumbnailUrl() | A thumbnail image relevant to the Thing. | luya\web\jsonld\CreativeWorkTrait |
setTranslationOfWork() | The work that this work has been translated from. e.g. 物种起源 is a translationOf “On the Origin of Species” Inverse property: workTranslation. | luya\web\jsonld\CreativeWorkTrait |
setTranslator() | 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. | luya\web\jsonld\CreativeWorkTrait |
setTypicalAgeRange() | The typical expected age range, e.g. '7-9', '11-'. | luya\web\jsonld\CreativeWorkTrait |
setUrl() | URL of the item. | luya\web\jsonld\ThingTrait |
setVersion() | The version of the CreativeWork embodied by a specified resource. | luya\web\jsonld\CreativeWorkTrait |
setWorkExample() | Example/instance/realization/derivation of the concept of this creative work. | luya\web\jsonld\CreativeWorkTrait |
setWorkTranslation() | A work that is a translation of the content of this work. e.g. 西遊記 has an English workTranslation “Journey to the West”,a German workTranslation “Monkeys Pilgerfahrt” and a Vietnamese translation Tây du ký bình khảo. | luya\web\jsonld\CreativeWorkTrait |
toArray() | Converts the object into an array. | luya\web\jsonld\BaseThing |
typeDefintion() | Contains the jsonLd definton @type value if not null or false. | luya\web\jsonld\CreativeWork |
Protected Methods
Method | Description | Defined By |
---|---|---|
extractFieldsFor() | Extract nested fields from a fields collection for a given root field Nested fields are separated with dots (.). e.g: "item.id" The previous example would extract "id". | yii\base\ArrayableTrait |
extractRootFields() | Extracts the root field names from nested fields. | yii\base\ArrayableTrait |
resolveFields() | Determines which fields can be returned by toArray(). | yii\base\ArrayableTrait |
Method Details
Defined in: yii\base\BaseObject::__call()
Calls the named method which is not a class method.
Do not call this method directly as it is a PHP magic method that will be implicitly called when an unknown method is being invoked.
public mixed __call ( $name, $params ) | ||
$name | string |
The method name |
$params | array |
Method parameters |
return | mixed |
The method return value |
---|---|---|
throws | yii\base\UnknownMethodException |
when calling unknown method |
public function __call($name, $params)
{
throw new UnknownMethodException('Calling unknown method: ' . get_class($this) . "::$name()");
}
Defined in: yii\base\BaseObject::__construct()
Constructor.
The default implementation does two things:
- Initializes the object with the given configuration
$config
. - Call init().
If this method is overridden in a child class, it is recommended that
- the last parameter of the constructor is a configuration array, like
$config
here. - call the parent implementation at the end of the constructor.
public void __construct ( $config = [] ) | ||
$config | array |
Name-value pairs that will be used to initialize the object properties |
public function __construct($config = [])
{
if (!empty($config)) {
Yii::configure($this, $config);
}
$this->init();
}
Defined in: yii\base\BaseObject::__get()
Returns the value of an object property.
Do not call this method directly as it is a PHP magic method that
will be implicitly called when executing $value = $object->property;
.
See also __set().
public mixed __get ( $name ) | ||
$name | string |
The property name |
return | mixed |
The property value |
---|---|---|
throws | yii\base\UnknownPropertyException |
if the property is not defined |
throws | yii\base\InvalidCallException |
if the property is write-only |
public function __get($name)
{
$getter = 'get' . $name;
if (method_exists($this, $getter)) {
return $this->$getter();
} elseif (method_exists($this, 'set' . $name)) {
throw new InvalidCallException('Getting write-only property: ' . get_class($this) . '::' . $name);
}
throw new UnknownPropertyException('Getting unknown property: ' . get_class($this) . '::' . $name);
}
Defined in: yii\base\BaseObject::__isset()
Checks if a property is set, i.e. defined and not null.
Do not call this method directly as it is a PHP magic method that
will be implicitly called when executing isset($object->property)
.
Note that if the property is not defined, false will be returned.
public boolean __isset ( $name ) | ||
$name | string |
The property name or the event name |
return | boolean |
Whether the named property is set (not null). |
---|
public function __isset($name)
{
$getter = 'get' . $name;
if (method_exists($this, $getter)) {
return $this->$getter() !== null;
}
return false;
}
Defined in: yii\base\BaseObject::__set()
Sets value of an object property.
Do not call this method directly as it is a PHP magic method that
will be implicitly called when executing $object->property = $value;
.
See also __get().
public void __set ( $name, $value ) | ||
$name | string |
The property name or the event name |
$value | mixed |
The property value |
throws | yii\base\UnknownPropertyException |
if the property is not defined |
---|---|---|
throws | yii\base\InvalidCallException |
if the property is read-only |
public function __set($name, $value)
{
$setter = 'set' . $name;
if (method_exists($this, $setter)) {
$this->$setter($value);
} elseif (method_exists($this, 'get' . $name)) {
throw new InvalidCallException('Setting read-only property: ' . get_class($this) . '::' . $name);
} else {
throw new UnknownPropertyException('Setting unknown property: ' . get_class($this) . '::' . $name);
}
}
Defined in: yii\base\BaseObject::__unset()
Sets an object property to null.
Do not call this method directly as it is a PHP magic method that
will be implicitly called when executing unset($object->property)
.
Note that if the property is not defined, this method will do nothing. If the property is read-only, it will throw an exception.
public void __unset ( $name ) | ||
$name | string |
The property name |
throws | yii\base\InvalidCallException |
if the property is read only. |
---|
public function __unset($name)
{
$setter = 'set' . $name;
if (method_exists($this, $setter)) {
$this->$setter(null);
} elseif (method_exists($this, 'get' . $name)) {
throw new InvalidCallException('Unsetting read-only property: ' . get_class($this) . '::' . $name);
}
}
Defined in: yii\base\BaseObject::canGetProperty()
Returns a value indicating whether a property can be read.
A property is readable if:
- the class has a getter method associated with the specified name (in this case, property name is case-insensitive);
- the class has a member variable with the specified name (when
$checkVars
is true);
See also canSetProperty().
public boolean canGetProperty ( $name, $checkVars = true ) | ||
$name | string |
The property name |
$checkVars | boolean |
Whether to treat member variables as properties |
return | boolean |
Whether the property can be read |
---|
public function canGetProperty($name, $checkVars = true)
{
return method_exists($this, 'get' . $name) || $checkVars && property_exists($this, $name);
}
Defined in: yii\base\BaseObject::canSetProperty()
Returns a value indicating whether a property can be set.
A property is writable if:
- the class has a setter method associated with the specified name (in this case, property name is case-insensitive);
- the class has a member variable with the specified name (when
$checkVars
is true);
See also canGetProperty().
public boolean canSetProperty ( $name, $checkVars = true ) | ||
$name | string |
The property name |
$checkVars | boolean |
Whether to treat member variables as properties |
return | boolean |
Whether the property can be written |
---|
public function canSetProperty($name, $checkVars = true)
{
return method_exists($this, 'set' . $name) || $checkVars && property_exists($this, $name);
}
::class
instead.
Defined in: yii\base\BaseObject::className()
Returns the fully qualified name of this class.
public static string className ( ) | ||
return | string |
The fully qualified name of this class. |
---|
public static function className()
{
return get_called_class();
}
Defined in: yii\base\ArrayableTrait::extraFields()
Returns the list of fields that can be expanded further and returned by toArray().
This method is similar to fields() except that the list of fields returned by this method are not returned by default by toArray(). Only when field names to be expanded are explicitly specified when calling toArray(), will their values be exported.
The default implementation returns an empty array.
You may override this method to return a list of expandable fields based on some context information (e.g. the current application user).
See also:
public array extraFields ( ) | ||
return | array |
The list of expandable field names or field definitions. Please refer to fields() on the format of the return value. |
---|
public function extraFields()
{
return [];
}
Defined in: yii\base\ArrayableTrait::extractFieldsFor()
Extract nested fields from a fields collection for a given root field Nested fields are separated with dots (.). e.g: "item.id" The previous example would extract "id".
protected array extractFieldsFor ( array $fields, $rootField ) | ||
$fields | array |
The fields requested for extraction |
$rootField | string |
The root field for which we want to extract the nested fields |
return | array |
Nested fields extracted for the given field |
---|
protected function extractFieldsFor(array $fields, $rootField)
{
$result = [];
foreach ($fields as $field) {
if (0 === strpos($field, "{$rootField}.")) {
$result[] = preg_replace('/^' . preg_quote($rootField, '/') . '\./i', '', $field);
}
}
return array_unique($result);
}
Defined in: yii\base\ArrayableTrait::extractRootFields()
Extracts the root field names from nested fields.
Nested fields are separated with dots (.). e.g: "item.id" The previous example would extract "item".
protected array extractRootFields ( array $fields ) | ||
$fields | array |
The fields requested for extraction |
return | array |
Root fields extracted from the given nested fields |
---|
protected function extractRootFields(array $fields)
{
$result = [];
foreach ($fields as $field) {
$result[] = current(explode('.', $field, 2));
}
if (in_array('*', $result, true)) {
$result = [];
}
return array_unique($result);
}
Defined in: luya\web\jsonld\BaseThing::fields()
Returns the list of fields that should be returned by default by toArray() when no specific fields are specified.
A field is a named element in the returned array by toArray().
This method should return an array of field names or field definitions. If the former, the field name will be treated as an object property name whose value will be used as the field value. If the latter, the array key should be the field name while the array value should be the corresponding field definition which can be either an object property name or a PHP callable returning the corresponding field value. The signature of the callable should be:
function ($model, $field) {
// return field value
}
For example, the following code declares four fields:
email
: the field name is the same as the property nameemail
;firstName
andlastName
: the field names arefirstName
andlastName
, and their values are obtained from thefirst_name
andlast_name
properties;fullName
: the field name isfullName
. Its value is obtained by concatenatingfirst_name
andlast_name
.
return [
'email',
'firstName' => 'first_name',
'lastName' => 'last_name',
'fullName' => function ($model) {
return $model->first_name . ' ' . $model->last_name;
},
];
public array fields ( ) | ||
return | array |
The list of field names or field definitions. |
---|
public function fields()
{
return $this->resolveGetterMethods();
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getAbout()
public luya\web\jsonld\Thing getAbout ( ) |
public function getAbout()
{
return $this->_about;
}
public string getAccessMode ( ) |
public function getAccessMode()
{
return $this->_accessMode;
}
public string getAccessModeSufficient ( ) |
public function getAccessModeSufficient()
{
return $this->_accessModeSufficient;
}
public string getAccessibilityAPI ( ) |
public function getAccessibilityAPI()
{
return $this->_accessibilityAPI;
}
public string getAccessibilityControl ( ) |
public function getAccessibilityControl()
{
return $this->_accessibilityControl;
}
public string getAccessibilityFeature ( ) |
public function getAccessibilityFeature()
{
return $this->_accessibilityFeature;
}
public string getAccessibilityHazard ( ) |
public function getAccessibilityHazard()
{
return $this->_accessibilityHazard;
}
public string getAccessibilitySummary ( ) |
public function getAccessibilitySummary()
{
return $this->_accessibilitySummary;
}
public luya\web\jsonld\Person getAccountablePerson ( ) |
public function getAccountablePerson()
{
return $this->_accountablePerson;
}
Defined in: luya\web\jsonld\ThingTrait::getAdditionalType()
public string getAdditionalType ( ) |
public function getAdditionalType()
{
return $this->_additionalType;
}
Defined in: luya\web\jsonld\ThingTrait::getAlternateName()
public string getAlternateName ( ) |
public function getAlternateName()
{
return $this->_alternateName;
}
public string getAlternativeHeadline ( ) |
public function getAlternativeHeadline()
{
return $this->_alternativeHeadline;
}
public luya\web\jsonld\MediaObject getAssociatedMedia ( ) |
public function getAssociatedMedia()
{
return $this->_associatedMedia;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getAuthor()
public luya\web\jsonld\Organization|luya\web\jsonld\Person getAuthor ( ) |
public function getAuthor()
{
return $this->_author;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getAward()
public string getAward ( ) |
public function getAward()
{
return $this->_award;
}
public luya\web\jsonld\Person getCharacter ( ) |
public function getCharacter()
{
return $this->_character;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getCitation()
public luya\web\jsonld\CreativeWork getCitation ( ) |
public function getCitation()
{
return $this->_citation;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getComment()
public luya\web\jsonld\Comment getComment ( ) |
public function getComment()
{
return $this->_comment;
}
public integer getCommentCount ( ) |
public function getCommentCount()
{
return $this->_commentCount;
}
public luya\web\jsonld\Place getContentLocation ( ) |
public function getContentLocation()
{
return $this->_contentLocation;
}
public string getContentRating ( ) |
public function getContentRating()
{
return $this->_contentRating;
}
public string getContentReferenceTime ( ) |
public function getContentReferenceTime()
{
return $this->_contentReferenceTime;
}
public luya\web\jsonld\Organization|luya\web\jsonld\Person getContributor ( ) |
public function getContributor()
{
return $this->_contributor;
}
public luya\web\jsonld\Organization|luya\web\jsonld\Person getCopyrightHolder ( ) |
public function getCopyrightHolder()
{
return $this->_copyrightHolder;
}
public mixed getCopyrightYear ( ) |
public function getCopyrightYear()
{
return $this->_copyrightYear;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getCreator()
public luya\web\jsonld\Organization|luya\web\jsonld\Person getCreator ( ) |
public function getCreator()
{
return $this->_creator;
}
public string getDateCreated ( ) |
public function getDateCreated()
{
return $this->_dateCreated;
}
public string getDateModified ( ) |
public function getDateModified()
{
return $this->_dateModified;
}
public string getDatePublished ( ) |
public function getDatePublished()
{
return $this->_datePublished;
}
Defined in: luya\web\jsonld\ThingTrait::getDescription()
public string getDescription ( ) |
public function getDescription()
{
return $this->_description;
}
public string getDisambiguatingDescription ( ) |
public function getDisambiguatingDescription()
{
return $this->_disambiguatingDescription;
}
public string getDiscussionUrl ( ) |
public function getDiscussionUrl()
{
return $this->_discussionUrl;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getEditor()
public luya\web\jsonld\Person getEditor ( ) |
public function getEditor()
{
return $this->_editor;
}
public string getEducationalUse ( ) |
public function getEducationalUse()
{
return $this->_educationalUse;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getEncoding()
public luya\web\jsonld\MediaObject getEncoding ( ) |
public function getEncoding()
{
return $this->_encoding;
}
public luya\web\jsonld\CreativeWork getExampleOfWork ( ) |
public function getExampleOfWork()
{
return $this->_exampleOfWork;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getExpires()
public string getExpires ( ) |
public function getExpires()
{
return $this->_expires;
}
public \luya\web\jsonld\URL|string getFileFormat ( ) |
public function getFileFormat()
{
return $this->_fileFormat;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getFunder()
public luya\web\jsonld\Organization|luya\web\jsonld\Person getFunder ( ) |
public function getFunder()
{
return $this->_funder;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getGenre()
public \luya\web\jsonld\URL|string getGenre ( ) |
public function getGenre()
{
return $this->_genre;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getHasPart()
public luya\web\jsonld\CreativeWork getHasPart ( ) |
public function getHasPart()
{
return $this->_hasPart;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getHeadline()
public string getHeadline ( ) |
public function getHeadline()
{
return $this->_headline;
}
Defined in: luya\web\jsonld\ThingTrait::getIdentifier()
public luya\web\jsonld\PropertyValue getIdentifier ( ) |
public function getIdentifier()
{
return $this->_identifier;
}
Defined in: luya\web\jsonld\ThingTrait::getImage()
public luya\web\jsonld\ImageObject getImage ( ) |
public function getImage()
{
return $this->_image;
}
public string getInteractivityType ( ) |
public function getInteractivityType()
{
return $this->_interactivityType;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getKeywords()
public string getKeywords ( ) |
public function getKeywords()
{
return $this->_keywords;
}
public string getLearningResourceType ( ) |
public function getLearningResourceType()
{
return $this->_learningResourceType;
}
public luya\web\jsonld\Place getLocationCreated ( ) |
public function getLocationCreated()
{
return $this->_locationCreated;
}
public luya\web\jsonld\Thing getMainEntity ( ) |
public function getMainEntity()
{
return $this->_mainEntity;
}
public luya\web\jsonld\CreativeWork getMainEntityOfPage ( ) |
public function getMainEntityOfPage()
{
return $this->_mainEntityOfPage;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getMentions()
public luya\web\jsonld\Thing getMentions ( ) |
public function getMentions()
{
return $this->_mentions;
}
Defined in: luya\web\jsonld\ThingTrait::getName()
public string getName ( ) |
public function getName()
{
return $this->_name;
}
Defined in: luya\web\jsonld\ThingTrait::getOffers()
Get Offer
public luya\web\jsonld\Offer getOffers ( ) |
public function getOffers()
{
return $this->_offers;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getPosition()
public integer|string getPosition ( ) |
public function getPosition()
{
return $this->_position;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getProducer()
public luya\web\jsonld\Organization|luya\web\jsonld\Person getProducer ( ) |
public function getProducer()
{
return $this->_producer;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getProvider()
public luya\web\jsonld\Organization|luya\web\jsonld\Person getProvider ( ) |
public function getProvider()
{
return $this->_provider;
}
public luya\web\jsonld\Organization|luya\web\jsonld\Person getPublisher ( ) |
public function getPublisher()
{
return $this->_publisher;
}
public luya\web\jsonld\Organization getPublisherImprint ( ) |
public function getPublisherImprint()
{
return $this->_publisherImprint;
}
public luya\web\jsonld\CreativeWork|\luya\web\jsonld\URL getPublishingPrinciples ( ) |
public function getPublishingPrinciples()
{
return $this->_publishingPrinciples;
}
public luya\web\jsonld\Event getRecordedAt ( ) |
public function getRecordedAt()
{
return $this->_recordedAt;
}
Defined in: luya\web\jsonld\ThingTrait::getSameAs()
public string getSameAs ( ) |
public function getSameAs()
{
return $this->_sameAs;
}
public string getSchemaVersion ( ) |
public function getSchemaVersion()
{
return $this->_schemaVersion;
}
public luya\web\jsonld\Organization getSourceOrganization ( ) |
public function getSourceOrganization()
{
return $this->_sourceOrganization;
}
public luya\web\jsonld\Place getSpatialCoverage ( ) |
public function getSpatialCoverage()
{
return $this->_spatialCoverage;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getSponsor()
public luya\web\jsonld\Organization|luya\web\jsonld\Person getSponsor ( ) |
public function getSponsor()
{
return $this->_sponsor;
}
Defined in: luya\web\jsonld\ThingTrait::getSubjectOf()
public luya\web\jsonld\CreativeWork|luya\web\jsonld\Event getSubjectOf ( ) |
public function getSubjectOf()
{
return $this->_subjectOf;
}
public \luya\web\jsonld\DateTime|\luya\web\jsonld\URL|string getTemporalCoverage ( ) |
public function getTemporalCoverage()
{
return $this->_temporalCoverage;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getText()
public string getText ( ) |
public function getText()
{
return $this->_text;
}
public \luya\web\jsonld\URL getThumbnailUrl ( ) |
public function getThumbnailUrl()
{
return $this->_thumbnailUrl;
}
public luya\web\jsonld\CreativeWork getTranslationOfWork ( ) |
public function getTranslationOfWork()
{
return $this->_translationOfWork;
}
public luya\web\jsonld\Organization|luya\web\jsonld\Person getTranslator ( ) |
public function getTranslator()
{
return $this->_translator;
}
public string getTypicalAgeRange ( ) |
public function getTypicalAgeRange()
{
return $this->_typicalAgeRange;
}
Defined in: luya\web\jsonld\ThingTrait::getUrl()
public string getUrl ( ) |
public function getUrl()
{
return $this->_url;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getVersion()
public integer|string getVersion ( ) |
public function getVersion()
{
return $this->_version;
}
public luya\web\jsonld\CreativeWork getWorkExample ( ) |
public function getWorkExample()
{
return $this->_workExample;
}
public luya\web\jsonld\CreativeWork getWorkTranslation ( ) |
public function getWorkTranslation()
{
return $this->_workTranslation;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::getisPartOf()
public luya\web\jsonld\CreativeWork getisPartOf ( ) |
public function getisPartOf()
{
return $this->_isPartOf;
}
Defined in: yii\base\BaseObject::hasMethod()
Returns a value indicating whether a method is defined.
The default implementation is a call to php function method_exists()
.
You may override this method when you implemented the php magic method __call()
.
public boolean hasMethod ( $name ) | ||
$name | string |
The method name |
return | boolean |
Whether the method is defined |
---|
public function hasMethod($name)
{
return method_exists($this, $name);
}
Defined in: yii\base\BaseObject::hasProperty()
Returns a value indicating whether a property is defined.
A property is defined if:
- the class has a getter or setter method associated with the specified name (in this case, property name is case-insensitive);
- the class has a member variable with the specified name (when
$checkVars
is true);
See also:
public boolean hasProperty ( $name, $checkVars = true ) | ||
$name | string |
The property name |
$checkVars | boolean |
Whether to treat member variables as properties |
return | boolean |
Whether the property is defined |
---|
public function hasProperty($name, $checkVars = true)
{
return $this->canGetProperty($name, $checkVars) || $this->canSetProperty($name, false);
}
Defined in: yii\base\BaseObject::init()
Initializes the object.
This method is invoked at the end of the constructor after the object is initialized with the given configuration.
public void init ( ) |
public function init()
{
}
public boolean isAccessibleForFree ( ) |
public function isAccessibleForFree()
{
return $this->_isAccessibleForFree;
}
public boolean isFamilyFriendly ( ) |
public function isFamilyFriendly()
{
return $this->_isFamilyFriendly;
}
Defined in: yii\base\ArrayableTrait::resolveFields()
Determines which fields can be returned by toArray().
This method will first extract the root fields from the given fields. Then it will check the requested root fields against those declared in fields() and extraFields() to determine which fields can be returned.
protected array resolveFields ( array $fields, array $expand ) | ||
$fields | array |
The fields being requested for exporting |
$expand | array |
The additional fields being requested for exporting |
return | array |
The list of fields to be exported. The array keys are the field names, and the array values are the corresponding object property names or PHP callables returning the field values. |
---|
protected function resolveFields(array $fields, array $expand)
{
$fields = $this->extractRootFields($fields);
$expand = $this->extractRootFields($expand);
$result = [];
foreach ($this->fields() as $field => $definition) {
if (is_int($field)) {
$field = $definition;
}
if (empty($fields) || in_array($field, $fields, true)) {
$result[$field] = $definition;
}
}
if (empty($expand)) {
return $result;
}
foreach ($this->extraFields() as $field => $definition) {
if (is_int($field)) {
$field = $definition;
}
if (in_array($field, $expand, true)) {
$result[$field] = $definition;
}
}
return $result;
}
Defined in: luya\web\jsonld\BaseThing::resolveGetterMethods()
Find all getter methods.
public array resolveGetterMethods ( ) |
public function resolveGetterMethods()
{
$resolved = [];
$methods = get_class_methods($this);
if (!$methods) {
return [];
}
foreach ($methods as $method) {
if (StringHelper::startsWith($method, 'get', true)) {
$resolved[] = lcfirst(StringHelper::replaceFirst('get', '', $method));
}
}
asort($resolved);
return $resolved;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAbout()
The subject matter of the content.
Inverse property: subjectOf.
public static setAbout ( luya\web\jsonld\Thing $about ) | ||
$about | luya\web\jsonld\Thing |
public function setAbout(Thing $about)
{
$this->_about = $about;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessMode()
The human sensory perceptual system or cognitive faculty through which a person may process or perceive information.
Expected values include: auditory, tactile, textual, visual, colorDependent, chartOnVisual, chemOnVisual, diagramOnVisual, mathOnVisual, musicOnVisual, textOnVisual.
public static setAccessMode ( $accessMode ) | ||
$accessMode | string |
public function setAccessMode($accessMode)
{
$this->_accessMode = $accessMode;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessModeSufficient()
A list of single or combined accessModes that are sufficient to understand all the intellectual content of a resource.
Expected values include: auditory, tactile, textual, visual.
public static setAccessModeSufficient ( $accessModeSufficient ) | ||
$accessModeSufficient | string |
public function setAccessModeSufficient($accessModeSufficient)
{
$this->_accessModeSufficient = $accessModeSufficient;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessibilityAPI()
Indicates that the resource is compatible with the referenced accessibility API (WebSchemas wiki lists possible values).
public static setAccessibilityAPI ( $accessibilityAPI ) | ||
$accessibilityAPI | string |
public function setAccessibilityAPI($accessibilityAPI)
{
$this->_accessibilityAPI = $accessibilityAPI;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessibilityControl()
Identifies input methods that are sufficient to fully control the described resource (WebSchemas wiki lists possible values).
public static setAccessibilityControl ( $accessibilityControl ) | ||
$accessibilityControl | string |
public function setAccessibilityControl($accessibilityControl)
{
$this->_accessibilityControl = $accessibilityControl;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessibilityFeature()
Content features of the resource, such as accessible media, alternatives and supported enhancements for accessibility (WebSchemas wiki lists possible values).
public static setAccessibilityFeature ( $accessibilityFeature ) | ||
$accessibilityFeature | string |
public function setAccessibilityFeature($accessibilityFeature)
{
$this->_accessibilityFeature = $accessibilityFeature;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessibilityHazard()
A characteristic of the described resource that is physiologically dangerous to some users.
Related to WCAG 2.0 guideline 2.3 (WebSchemas wiki lists possible values).
public static setAccessibilityHazard ( $accessibilityHazard ) | ||
$accessibilityHazard | string |
public function setAccessibilityHazard($accessibilityHazard)
{
$this->_accessibilityHazard = $accessibilityHazard;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccessibilitySummary()
A human-readable summary of specific accessibility features or deficiencies, consistent with the other accessibility metadata but expressing subtleties such as "short descriptions are present but long descriptions will be needed for non-visual users" or "short descriptions are present and no long descriptions are needed."
public static setAccessibilitySummary ( $accessibilitySummary ) | ||
$accessibilitySummary | string |
public function setAccessibilitySummary($accessibilitySummary)
{
$this->_accessibilitySummary = $accessibilitySummary;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAccountablePerson()
Specifies the Person that is legally accountable for the CreativeWork.
public static setAccountablePerson ( luya\web\jsonld\Person $accountablePerson ) | ||
$accountablePerson | luya\web\jsonld\Person |
public function setAccountablePerson(Person $accountablePerson)
{
$this->_accountablePerson = $accountablePerson;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setAdditionalType()
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.
public static setAdditionalType ( luya\web\jsonld\UrlValue $additionalType ) | ||
$additionalType | string |
public function setAdditionalType(UrlValue $additionalType)
{
$this->_additionalType = $additionalType->getValue();
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setAlternateName()
An alias for the item
public static setAlternateName ( $alternateName ) | ||
$alternateName | string |
public function setAlternateName($alternateName)
{
$this->_alternateName = $alternateName;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAlternativeHeadline()
A secondary title of the CreativeWork.
public static setAlternativeHeadline ( $alternativeHeadline ) | ||
$alternativeHeadline | string |
public function setAlternativeHeadline($alternativeHeadline)
{
$this->_alternativeHeadline = $alternativeHeadline;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAssociatedMedia()
A media object that encodes this CreativeWork. This property is a synonym for encoding.
public static setAssociatedMedia ( luya\web\jsonld\MediaObject $associatedMedia ) | ||
$associatedMedia | luya\web\jsonld\MediaObject |
public function setAssociatedMedia(MediaObject $associatedMedia)
{
$this->_associatedMedia = $associatedMedia;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAuthor()
The author of this content or rating. Please note that author is special in that HTML 5 provides a special mechanism for indicating authorship via the rel tag. That is equivalent to this and may be used interchangeably.
public static setAuthor ( $author ) | ||
$author | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setAuthor($author)
{
ObjectHelper::isInstanceOf($author, [Organization::class, PersonInterface::class]);
$this->_author = $author;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setAward()
An award won by or for this item.
Supersedes awards.
public static setAward ( $award ) | ||
$award | string |
public function setAward($award)
{
$this->_award = $award;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setCharacter()
Fictional person connected with a creative work.
public static setCharacter ( luya\web\jsonld\Person $character ) | ||
$character | luya\web\jsonld\Person |
public function setCharacter(Person $character)
{
$this->_character = $character;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setCitation()
A citation or reference to another creative work, such as another publication, web page, scholarly article, etc.
public static setCitation ( luya\web\jsonld\CreativeWork $citation ) | ||
$citation | luya\web\jsonld\CreativeWork |
public function setCitation(CreativeWork $citation)
{
$this->_citation = $citation;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setComment()
Comments, typically from users.
public static setComment ( luya\web\jsonld\Comment $comment ) | ||
$comment | luya\web\jsonld\Comment |
public function setComment(Comment $comment)
{
$this->_comment = $comment;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setCommentCount()
The number of comments this CreativeWork (e.g. Article, Question or Answer) has received. This is most applicable to works published in Web sites with commenting system; additional comments may exist elsewhere.
public static setCommentCount ( $commentCount ) | ||
$commentCount | integer |
public function setCommentCount($commentCount)
{
$this->_commentCount = $commentCount;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setContentLocation()
The location depicted or described in the content. For example, the location in a photograph or painting.
public static setContentLocation ( luya\web\jsonld\Place $contentLocation ) | ||
$contentLocation | luya\web\jsonld\Place |
public function setContentLocation(Place $contentLocation)
{
$this->_contentLocation = $contentLocation;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setContentRating()
Official rating of a piece of content—for example,'MPAA PG-13'.
public static setContentRating ( $contentRating ) | ||
$contentRating | string |
public function setContentRating($contentRating)
{
$this->_contentRating = $contentRating;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setContentReferenceTime()
The specific time described by a creative work, for works (e.g. articles, video objects etc.) that emphasise a particular moment within an Event.
public static setContentReferenceTime ( luya\web\jsonld\DateTimeValue $contentReferenceTime ) | ||
$contentReferenceTime | luya\web\jsonld\DateTimeValue |
public function setContentReferenceTime(DateTimeValue $contentReferenceTime)
{
$this->_contentReferenceTime = $contentReferenceTime->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setContributor()
A secondary contributor to the CreativeWork or Event.
public static setContributor ( $contributor ) | ||
$contributor | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setContributor($contributor)
{
ObjectHelper::isInstanceOf($contributor, [Organization::class, PersonInterface::class]);
$this->_contributor = $contributor;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setCopyrightHolder()
The party holding the legal copyright to the CreativeWork.
public static setCopyrightHolder ( $copyrightHolder ) | ||
$copyrightHolder | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setCopyrightHolder($copyrightHolder)
{
ObjectHelper::isInstanceOf($copyrightHolder, [Organization::class, PersonInterface::class]);
$this->_copyrightHolder = $copyrightHolder;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setCopyrightYear()
The year during which the claimed copyright for the CreativeWork was first asserted.
public static setCopyrightYear ( $copyrightYear ) | ||
$copyrightYear | mixed |
public function setCopyrightYear($copyrightYear)
{
$this->_copyrightYear = $copyrightYear;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setCreator()
The creator/author of this CreativeWork. This is the same as the Author property for CreativeWork.
public static setCreator ( $creator ) | ||
$creator | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setCreator($creator)
{
ObjectHelper::isInstanceOf($creator, [Organization::class, PersonInterface::class]);
$this->_creator = $creator;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setDateCreated()
The date on which the CreativeWork was created or the item was added to a DataFeed.
public static setDateCreated ( luya\web\jsonld\DateTimeValue $dateCreated ) | ||
$dateCreated | luya\web\jsonld\DateTimeValue |
public function setDateCreated(DateTimeValue $dateCreated)
{
$this->_dateCreated = $dateCreated->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setDateModified()
The date on which the CreativeWork was most recently modified or when the item's entry was modified within a DataFeed.
public static setDateModified ( luya\web\jsonld\DateTimeValue $dateModified ) | ||
$dateModified | luya\web\jsonld\DateTimeValue |
public function setDateModified(DateTimeValue $dateModified)
{
$this->_dateModified = $dateModified->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setDatePublished()
Date of first broadcast/publication.
public static setDatePublished ( luya\web\jsonld\DateTimeValue $datePublished ) | ||
$datePublished | luya\web\jsonld\DateTimeValue |
public function setDatePublished(DateTimeValue $datePublished)
{
$this->_datePublished = $datePublished->getValue();
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setDescription()
A description of the item.
public static setDescription ( $description ) | ||
$description | string |
public function setDescription($description)
{
$this->_description = $description;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setDisambiguatingDescription()
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.
public static setDisambiguatingDescription ( $disambiguatingDescription ) | ||
$disambiguatingDescription | string |
public function setDisambiguatingDescription($disambiguatingDescription)
{
$this->_disambiguatingDescription = $disambiguatingDescription;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setDiscussionUrl()
A link to the page containing the comments of the CreativeWork.
public static setDiscussionUrl ( luya\web\jsonld\UrlValue $discussionUrl ) | ||
$discussionUrl | luya\web\jsonld\UrlValue |
public function setDiscussionUrl(UrlValue $discussionUrl)
{
$this->_discussionUrl = $discussionUrl->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setEditor()
Specifies the Person who edited the CreativeWork.
public void setEditor ( luya\web\jsonld\Person $editor ) | ||
$editor | luya\web\jsonld\Person |
public function setEditor(Person $editor)
{
$this->_editor = $editor;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setEducationalUse()
The purpose of a work in the context of education; for example, 'assignment', 'group work'.
public static setEducationalUse ( luya\web\jsonld\CreativeWork $educationalUse ) | ||
$educationalUse | string |
public function setEducationalUse(CreativeWork $educationalUse)
{
$this->_educationalUse = $educationalUse;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setEncoding()
A media object that encodes this CreativeWork. This property is a synonym for associatedMedia.
Supersedes encodings.
public static setEncoding ( luya\web\jsonld\MediaObject $encoding ) | ||
$encoding | luya\web\jsonld\MediaObject |
public function setEncoding(MediaObject $encoding)
{
$this->_encoding = $encoding;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setExampleOfWork()
A creative work that this work is an example/instance/realization/derivation of.
Inverse property: workExample.
public static setExampleOfWork ( luya\web\jsonld\CreativeWork $exampleOfWork ) | ||
$exampleOfWork | luya\web\jsonld\CreativeWork |
public function setExampleOfWork(CreativeWork $exampleOfWork)
{
$this->_exampleOfWork = $exampleOfWork;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setExpires()
Date the content expires and is no longer useful or available. For example a VideoObject or NewsArticle whose availability or relevance is time-limited, or a ClaimReview fact check whose publisher wants to indicate that it may no longer be relevant (or helpful to highlight) after some date.
public static setExpires ( luya\web\jsonld\DateValue $expires ) | ||
$expires | luya\web\jsonld\DateValue |
public function setExpires(DateValue $expires)
{
$this->_expires = $expires->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setFileFormat()
Media type, typically MIME format (see IANA site) of the content e.g. application/zip of a SoftwareApplication binary. In cases where a CreativeWork has several media type representations, 'encoding' can be used to indicate each MediaObject alongside particular fileFormat information. Unregistered or niche file formats can be indicated instead via the most appropriate URL, e.g. defining Web page or a Wikipedia entry.
public static setFileFormat ( $fileFormat ) | ||
$fileFormat | \luya\web\jsonld\URL|string |
public function setFileFormat($fileFormat)
{
$this->_fileFormat = $fileFormat;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setFunder()
A person or organization that supports (sponsors) something through some kind of financial contribution.
public static setFunder ( $funder ) | ||
$funder | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setFunder($funder)
{
ObjectHelper::isInstanceOf($funder, [Organization::class, PersonInterface::class]);
$this->_funder = $funder;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setGenre()
Genre of the creative work, broadcast channel or group.
public static setGenre ( $genre ) | ||
$genre | \luya\web\jsonld\URL|string |
public function setGenre($genre)
{
$this->_genre = $genre;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setHasPart()
Indicates a CreativeWork that is (in some sense) a part of this CreativeWork.
Inverse property: isPartOf.
public static setHasPart ( luya\web\jsonld\CreativeWork $hasPart ) | ||
$hasPart | luya\web\jsonld\CreativeWork |
public function setHasPart(CreativeWork $hasPart)
{
$this->_hasPart = $hasPart;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setHeadline()
Headline of the article.
public static setHeadline ( luya\web\jsonld\TextValue $headline ) | ||
$headline | luya\web\jsonld\TextValue |
public function setHeadline(TextValue $headline)
{
$this->_headline = $headline->truncate(100)->getValue();
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setIdentifier()
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 for more details.
public static setIdentifier ( luya\web\jsonld\PropertyValue $identifier ) | ||
$identifier | luya\web\jsonld\PropertyValue |
public function setIdentifier(PropertyValue $identifier)
{
$this->_identifier = $identifier;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setImage()
An image of the item.
This can be a URL or a fully described ImageObject.
public static setImage ( luya\web\jsonld\ImageObject $image ) | ||
$image | luya\web\jsonld\ImageObject |
public function setImage(ImageObject $image)
{
$this->_image = $image;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setInteractivityType()
The predominant mode of learning supported by the learning resource.
Acceptable values are 'active', 'expositive', or 'mixed'.
public static setInteractivityType ( $interactivityType ) | ||
$interactivityType | string |
public function setInteractivityType($interactivityType)
{
$this->_interactivityType = $interactivityType;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setIsAccessibleForFree()
A flag to signal that the item, event, or place is accessible for free.
Supersedes free.
public static setIsAccessibleForFree ( $isAccessibleForFree ) | ||
$isAccessibleForFree | boolean |
public function setIsAccessibleForFree($isAccessibleForFree)
{
$this->_isAccessibleForFree = $isAccessibleForFree;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setIsFamilyFriendly()
Indicates whether this content is family friendly.
public static setIsFamilyFriendly ( $isFamilyFriendly ) | ||
$isFamilyFriendly | boolean |
public function setIsFamilyFriendly($isFamilyFriendly)
{
$this->_isFamilyFriendly = $isFamilyFriendly;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setIsPartOf()
Indicates a CreativeWork that this CreativeWork is (in some sense) part of.
Inverse property: hasPart.
public static setIsPartOf ( luya\web\jsonld\CreativeWork $isPartOf ) | ||
$isPartOf | luya\web\jsonld\CreativeWork |
public function setIsPartOf(CreativeWork $isPartOf)
{
$this->_isPartOf = $isPartOf;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setKeywords()
Keywords or tags used to describe this content.
Multiple entries in a keywords list are typically delimited by commas.
public static setKeywords ( $keywords ) | ||
$keywords | string |
public function setKeywords($keywords)
{
$this->_keywords = $keywords;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setLearningResourceType()
The predominant type or kind characterizing the learning resource. For example, 'presentation', 'handout'.
public static setLearningResourceType ( $learningResourceType ) | ||
$learningResourceType | string |
public function setLearningResourceType($learningResourceType)
{
$this->_learningResourceType = $learningResourceType;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setLocationCreated()
The location where the CreativeWork was created, which may not be the same as the location depicted in the CreativeWork.
public static setLocationCreated ( luya\web\jsonld\Place $locationCreated ) | ||
$locationCreated | luya\web\jsonld\Place |
public function setLocationCreated(Place $locationCreated)
{
$this->_locationCreated = $locationCreated;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setMainEntity()
Indicates the primary entity described in some page or other CreativeWork.
Inverse property: mainEntityOfPage.
public static setMainEntity ( luya\web\jsonld\Thing $mainEntity ) | ||
$mainEntity | luya\web\jsonld\Thing |
public function setMainEntity(Thing $mainEntity)
{
$this->_mainEntity = $mainEntity;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setMainEntityOfPage()
Indicates a page (or other CreativeWork) for which this thing is the main entity being described.
Inverse property: mainEntity.
public static setMainEntityOfPage ( luya\web\jsonld\CreativeWork $mainEntityOfPage ) | ||
$mainEntityOfPage | luya\web\jsonld\CreativeWork |
public function setMainEntityOfPage(CreativeWork $mainEntityOfPage)
{
$this->_mainEntityOfPage = $mainEntityOfPage;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setMentions()
Indicates that the CreativeWork contains a reference to, but is not necessarily about a concept.
public static setMentions ( luya\web\jsonld\Thing $mentions ) | ||
$mentions | luya\web\jsonld\Thing |
public function setMentions(Thing $mentions)
{
$this->_mentions = $mentions;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setName()
The name of the item.
public static setName ( $name ) | ||
$name | string |
public function setName($name)
{
$this->_name = $name;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setOffers()
Set Offer
public static setOffers ( luya\web\jsonld\Offer $offers ) | ||
$offers |
public function setOffers(Offer $offers)
{
$this->_offers = $offers;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setPosition()
The position of an item in a series or sequence of items.
public static setPosition ( $position ) | ||
$position | integer|string |
public function setPosition($position)
{
$this->_position = $position;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setProducer()
The person or organization who produced the work (e.g. music album, movie, tv/radio series etc.).
public static setProducer ( $producer ) | ||
$producer | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setProducer($producer)
{
ObjectHelper::isInstanceOf($producer, [Organization::class, PersonInterface::class]);
$this->_producer = $producer;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setProvider()
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.
Supersedes carrier.
public static setProvider ( $provider ) | ||
$provider | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setProvider($provider)
{
ObjectHelper::isInstanceOf($provider, [Organization::class, PersonInterface::class]);
$this->_provider = $provider;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setPublisher()
The publisher of the creative work.
public static setPublisher ( $publisher ) | ||
$publisher | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setPublisher($publisher)
{
ObjectHelper::isInstanceOf($publisher, [Organization::class, Person::class]);
$this->_publisher = $publisher;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setPublisherImprint()
The publishing division which published the comic.
public static setPublisherImprint ( luya\web\jsonld\Organization $publisherImprint ) | ||
$publisherImprint | luya\web\jsonld\Organization |
public function setPublisherImprint(Organization $publisherImprint)
{
$this->_publisherImprint = $publisherImprint;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setPublishingPrinciples()
The publishingPrinciples property indicates (typically via URL) a document describing the editorial principles of an Organization (or individual e.g. a Person writing a blog) that relate to their activities as a publisher, e.g. ethics or diversity policies. When applied to a CreativeWork (e.g. NewsArticle) the principles are those of the party primarily responsible for the creation of the CreativeWork.
While such policies are most typically expressed in natural language, sometimes related information (e.g. indicating a funder) can be expressed using schema.org terminology.
public static setPublishingPrinciples ( luya\web\jsonld\CreativeWork $publishingPrinciples ) | ||
$publishingPrinciples | luya\web\jsonld\CreativeWork|\luya\web\jsonld\URL |
public function setPublishingPrinciples(CreativeWork $publishingPrinciples)
{
$this->_publishingPrinciples = $publishingPrinciples;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setRecordedAt()
The Event where the CreativeWork was recorded. The CreativeWork may capture all or part of the event.
Inverse property: recordedIn.
public static setRecordedAt ( luya\web\jsonld\Event $recordedAt ) | ||
$recordedAt | luya\web\jsonld\Event |
public function setRecordedAt(Event $recordedAt)
{
$this->_recordedAt = $recordedAt;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setSameAs()
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.
public static setSameAs ( luya\web\jsonld\UrlValue $sameAs ) | ||
$sameAs | luya\web\jsonld\UrlValue |
public function setSameAs(UrlValue $sameAs)
{
$this->_sameAs = $sameAs->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setSchemaVersion()
Indicates (by URL or string) a particular version of a schema used in some CreativeWork.
For example, a document could declare a schemaVersion using an URL such as http://schema.org/version/2.0/ if precise indication of schema version was required by some application.
public static setSchemaVersion ( luya\web\jsonld\UrlValue $schemaVersion ) | ||
$schemaVersion | luya\web\jsonld\UrlValue |
public function setSchemaVersion(UrlValue $schemaVersion)
{
$this->_schemaVersion = $schemaVersion->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setSourceOrganization()
The Organization on whose behalf the creator was working.
public static setSourceOrganization ( luya\web\jsonld\Organization $sourceOrganization ) | ||
$sourceOrganization | luya\web\jsonld\Organization |
public function setSourceOrganization(Organization $sourceOrganization)
{
$this->_sourceOrganization = $sourceOrganization;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setSpatialCoverage()
The spatialCoverage of a CreativeWork indicates the place(s) which are the focus of the content.
It is a subproperty of contentLocation intended primarily for more technical and detailed materials. For example with a Dataset, it indicates areas that the dataset describes: a dataset of New York weather would have spatialCoverage which was the place: the state of New York. Supersedes spatial.
public static setSpatialCoverage ( luya\web\jsonld\Place $spatialCoverage ) | ||
$spatialCoverage | luya\web\jsonld\Place |
public function setSpatialCoverage(Place $spatialCoverage)
{
$this->_spatialCoverage = $spatialCoverage;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setSponsor()
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.
public static setSponsor ( $sponsor ) | ||
$sponsor | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setSponsor($sponsor)
{
ObjectHelper::isInstanceOf($sponsor, [Organization::class, PersonInterface::class]);
$this->_sponsor = $sponsor;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setSubjectOf()
A CreativeWork or Event about this Thing.
Inverse property: about.
public static setSubjectOf ( $subjectOf ) | ||
$subjectOf | luya\web\jsonld\CreativeWork|luya\web\jsonld\Event |
public function setSubjectOf($subjectOf)
{
$this->_subjectOf = $subjectOf;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setTemporalCoverage()
The temporalCoverage of a CreativeWork indicates the period that the content applies to, i.e. that it describes, either as a DateTime or as a textual string indicating a time period in ISO 8601 time interval format. In the case of a Dataset it will typically indicate the relevant time period in a precise notation (e.g. for a 2011 census dataset, the year 2011 would be written "2011/2012"). Other forms of content e.g. ScholarlyArticle, Book, TVSeries or TVEpisode may indicate their temporalCoverage in broader terms - textually or via well-known URL. Written works such as books may sometimes have precise temporal coverage too, e.g. a work set in 1939 - 1945 can be indicated in ISO 8601 interval format format via "1939/1945".
Supersedes datasetTimeInterval, temporal.
public static setTemporalCoverage ( $temporalCoverage ) | ||
$temporalCoverage | \luya\web\jsonld\DateTime|\luya\web\jsonld\URL|string |
public function setTemporalCoverage($temporalCoverage)
{
$this->_temporalCoverage = $temporalCoverage;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setText()
The textual content of this CreativeWork.
public static setText ( $text ) | ||
$text | string |
public function setText($text)
{
$this->_text = $text;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setThumbnailUrl()
A thumbnail image relevant to the Thing.
public static setThumbnailUrl ( luya\web\jsonld\UrlValue $thumbnailUrl ) | ||
$thumbnailUrl | luya\web\jsonld\UrlValue |
public function setThumbnailUrl(UrlValue $thumbnailUrl)
{
$this->_thumbnailUrl = $thumbnailUrl;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setTranslationOfWork()
The work that this work has been translated from. e.g. 物种起源 is a translationOf “On the Origin of Species” Inverse property: workTranslation.
public static setTranslationOfWork ( luya\web\jsonld\CreativeWork $translationOfWork ) | ||
$translationOfWork | luya\web\jsonld\CreativeWork |
public function setTranslationOfWork(CreativeWork $translationOfWork)
{
$this->_translationOfWork = $translationOfWork;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setTranslator()
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.
public static setTranslator ( $translator ) | ||
$translator | luya\web\jsonld\Organization|luya\web\jsonld\Person |
public function setTranslator($translator)
{
ObjectHelper::isInstanceOf($translator, [Organization::class, PersonInterface::class]);
$this->_translator = $translator;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setTypicalAgeRange()
The typical expected age range, e.g. '7-9', '11-'.
public static setTypicalAgeRange ( $typicalAgeRange ) | ||
$typicalAgeRange | string |
public function setTypicalAgeRange($typicalAgeRange)
{
$this->_typicalAgeRange = $typicalAgeRange;
return $this;
}
Defined in: luya\web\jsonld\ThingTrait::setUrl()
URL of the item.
public static setUrl ( luya\web\jsonld\UrlValue $url ) | ||
$url | luya\web\jsonld\UrlValue |
public function setUrl(UrlValue $url)
{
$this->_url = $url->getValue();
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setVersion()
The version of the CreativeWork embodied by a specified resource.
public static setVersion ( $version ) | ||
$version | integer|string |
public function setVersion($version)
{
$this->_version = $version;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setWorkExample()
Example/instance/realization/derivation of the concept of this creative work.
eg. The paperback edition, first edition, or eBook. Inverse property: exampleOfWork.
public static setWorkExample ( luya\web\jsonld\CreativeWork $workExample ) | ||
$workExample | luya\web\jsonld\CreativeWork |
public function setWorkExample(CreativeWork $workExample)
{
$this->_workExample = $workExample;
return $this;
}
Defined in: luya\web\jsonld\CreativeWorkTrait::setWorkTranslation()
A work that is a translation of the content of this work. e.g. 西遊記 has an English workTranslation “Journey to the West”,a German workTranslation “Monkeys Pilgerfahrt” and a Vietnamese translation Tây du ký bình khảo.
Inverse property: translationOfWork.
public static setWorkTranslation ( luya\web\jsonld\CreativeWork $workTranslation ) | ||
$workTranslation | luya\web\jsonld\CreativeWork |
public function setWorkTranslation(CreativeWork $workTranslation)
{
$this->_workTranslation = $workTranslation;
return $this;
}
Defined in: luya\web\jsonld\BaseThing::toArray()
Converts the object into an array.
public array toArray ( array $fields = [], array $expand = [], $recursive = true ) | ||
$fields | array |
The fields that the output array should contain. Fields not specified in fields() will be ignored. If this parameter is empty, all fields as specified in fields() will be returned. |
$expand | array |
The additional fields that the output array should contain. Fields not specified in extraFields() will be ignored. If this parameter is empty, no extra fields will be returned. |
$recursive | boolean |
Whether to recursively return array representation of embedded objects. |
return | array |
The array representation of the object |
---|
public function toArray(array $fields = [], array $expand = [], $recursive = true)
{
$array = $this->removeEmptyValues($this->internalToArray($fields, $expand, $recursive));
if ($this->typeDefintion()) {
$array['@type'] = $this->typeDefintion();
}
return $array;
}
Contains the jsonLd definton @type value if not null or false.
public boolean|string typeDefintion ( ) | ||
return | boolean|string |
Generates the @type field. |
---|
public function typeDefintion()
{
return 'CreativeWork';
}