RatedContentDescription
RatedContentDescription
RatedContentDescription
RatedContentDescription
Class
Definition
Contains information about a piece of content. An app creates a RatedContentDescription object, for each piece of content to be used in the GetRestrictionLevelAsync and RequestContentAccessAsync methods.
public : sealed class RatedContentDescription : IRatedContentDescriptionpublic sealed class RatedContentDescription : IRatedContentDescriptionPublic NotInheritable Class RatedContentDescription Implements IRatedContentDescription// You can use this class in JavaScript.
- Attributes
| Device family |
Windows 10 (introduced v10.0.10240.0)
|
| API contract |
Windows.Foundation.UniversalApiContract (introduced v1)
|
Remarks
If a piece of content doesn't have a 3rd-party rating, nor a Store age rating, the app must pass NULL as the rating.
Constructors
RatedContentDescription(String, String, RatedContentCategory) RatedContentDescription(String, String, RatedContentCategory) RatedContentDescription(String, String, RatedContentCategory) RatedContentDescription(String, String, RatedContentCategory)
Initializes a new instance of the RatedContentDescription class.
public : RatedContentDescription(PlatForm::String id, PlatForm::String title, RatedContentCategory category)public RatedContentDescription(String id, String title, RatedContentCategory category)Public Sub New(id As String, title As String, category As RatedContentCategory)// You can use this method in JavaScript.
- id
- PlatForm::String String String String
The ID of the content, as specified by the app developer.
- title
- PlatForm::String String String String
The title of the content.
Specifies the type of a piece of content, defined by RatedContentCategory.
Remarks
Returns E_INVALIDARG, if an invalid value is provided.
Properties
Category Category Category Category
Specifies the type of a piece of content, defined by RatedContentCategory.
public : RatedContentCategory Category { get; set; }public RatedContentCategory Category { get; set; }Public ReadWrite Property Category As RatedContentCategory// You can use this property in JavaScript.
Specifies the type of a piece of content, defined by RatedContentCategory.
Remarks
Returns E_INVALIDARG, if an invalid value is provided.
Id Id Id Id
The unique content ID of a piece of content, in the app's content catalog.
public : PlatForm::String Id { get; set; }public string Id { get; set; }Public ReadWrite Property Id As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The ID of the content as a string.
Remarks
The ID must be a length between 1 and 100 characters, and can't be empty or contain only spaces.
Returns E_INVALIDARG, if an invalid value is provided.
Image Image Image Image
The thumbnail image associated with the content.
public : IRandomAccessStreamReference Image { get; set; }public IRandomAccessStreamReference Image { get; set; }Public ReadWrite Property Image As IRandomAccessStreamReference// You can use this property in JavaScript.
- Value
- IRandomAccessStreamReference IRandomAccessStreamReference IRandomAccessStreamReference IRandomAccessStreamReference
An image associated with the content.
Remarks
Accepted image formats are JPEG, BMP, and PNG.
Ratings Ratings Ratings Ratings
Provides all existing third-party and Windows Store age ratings for a piece of content.
public : IVector<string> Ratings { get; set; }public IList<string> Ratings { get; set; }Public ReadWrite Property Ratings As IList<string>// You can use this property in JavaScript.
- Value
- IVector<PlatForm::String> IList<string> IList<string> IList<string>
Specifies the age rating, for a piece of content.
Remarks
If a piece of content doesn’t have neither a third-party rating nor a Store age rating, the app must pass NULL as the rating. If NULL rating is provided, the RequestContentAccessAsync method will display a Content blocked by Family Safety dialog, with options to request a parental override.
Family Safety uses the ContentRestrictionBrowsePolicy.GeographicRegion and RatedContentDescription.Category properties, to determine the appropriate rating system for a piece of content. If contain a rating value in this rating system, then it’s used as the content rating. If don’t contain value in this rating system, the Store age rating value is used. If it’s not available, the content is considered Not rated, for the Family Safety content settings region, and RequestContentAccessAsync method will display a Content blocked by Family Safety dialog, with options to request a parental override. For more info, see Using content ratings.
- See Also
Title Title Title Title
The display title of a piece of content.
public : PlatForm::String Title { get; set; }public string Title { get; set; }Public ReadWrite Property Title As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The title of the content as a string. Read/Write.
Remarks
The ID must be a length between 1 and 100 characters, and can't be empty or contain only spaces.
Returns E_INVALIDARG, if an invalid value is provided.