Class SchemaOrgPropertyValue
- Namespace
- Dynamicweb.Ecommerce.ProductCatalog.SchemaOrg
- Assembly
- Dynamicweb.Ecommerce.dll
Represents a Schema.org PropertyValue (https://schema.org/PropertyValue) used for JSON-LD generation.
Used for the product characteristics written as 'additionalProperty', i.e. dimensions, materials or certifications.
Properties with a null value are omitted from the serialized JSON-LD output.
public sealed class SchemaOrgPropertyValue
- Inheritance
-
SchemaOrgPropertyValue
- Inherited Members
Remarks
Sealed on purpose: ToJsonLd(SchemaOrgProduct?) only makes the root model polymorphic, and this type is reachable solely as a property of SchemaOrgProduct, which the serializer writes by its declared type - a derived model's additional properties would be dropped from the output.
Properties
Name
The name of the characteristic, i.e. 'Material' or 'Screen size'.
[JsonPropertyName("name")]
public string? Name { get; set; }
Property Value
PropertyId
An identifier of the characteristic, i.e. a standard code for the property or a site specific identifier.
[JsonPropertyName("propertyID")]
public string? PropertyId { get; set; }
Property Value
Type
The Schema.org type. Defaults to 'PropertyValue'.
[JsonPropertyName("@type")]
public string Type { get; set; }
Property Value
UnitCode
The unit of measurement of a numeric value as a UN/CEFACT Common Code, i.e. 'KGM' or 'CMT'.
[JsonPropertyName("unitCode")]
public string? UnitCode { get; set; }
Property Value
UnitText
The unit of measurement of a numeric value as a free text string, i.e. 'kg' or 'cm'.
[JsonPropertyName("unitText")]
public string? UnitText { get; set; }
Property Value
Value
[JsonPropertyName("value")]
public object? Value { get; set; }