---
title: TVContentItem
framework: tvservices
role: symbol
role_heading: Class
path: tvservices/tvcontentitem
---

# TVContentItem

An object that describes either a piece of content or a container for other content items.

## Declaration

```swift
class TVContentItem
```

## Overview

Overview The exact details of what a content item is are dependent on your app. For example, a content item might be a piece of media or it might provide access to news or other content available to your app. To create a description of a piece of content, create a content identifier object and then use this object to initialize a new TVContentItem object. Then, set any other properties that are appropriate for the object you are creating. Most of the properties are optional, and many properties apply only to certain kinds of content. Inspect an existing TVContentItem object to retrieve the media and playback properties, such as the duration of the content or when the content was last played.

## Topics

### Initializing a Content Item

- [init(contentIdentifier:)](tvservices/tvcontentitem/init(contentidentifier:).md)
- [init(coder:)](tvservices/tvcontentitem/init(coder:).md)

### Reading a Content Item’s Identifier

- [contentIdentifier](tvservices/tvcontentitem/contentidentifier.md)

### Inspecting the General Display Properties

- [badgeCount](tvservices/tvcontentitem/badgecount.md)
- [title](tvservices/tvcontentitem/title.md)
- [topShelfItems](tvservices/tvcontentitem/topshelfitems.md)

### Accessing Image Resources

- [imageURL](tvservices/tvcontentitem/imageurl.md)
- [imageURL(forTraits:)](tvservices/tvcontentitem/imageurl(fortraits:).md)
- [setImageURL(_:forTraits:)](tvservices/tvcontentitem/setimageurl(_:fortraits:).md)
- [TVContentItemImageTrait](tvservices/tvcontentitemimagetrait.md)

### Inspecting the Content Properties

- [creationDate](tvservices/tvcontentitem/creationdate.md)
- [duration](tvservices/tvcontentitem/duration.md)
- [expirationDate](tvservices/tvcontentitem/expirationdate.md)
- [imageShape](tvservices/tvcontentitem/imageshape.md)
- [TVContentItemImageShape](tvservices/tvcontentitemimageshape.md)

### Inspecting the Playback Properties

- [currentPosition](tvservices/tvcontentitem/currentposition.md)
- [hasPlayedToEnd](tvservices/tvcontentitem/hasplayedtoend.md)
- [lastAccessedDate](tvservices/tvcontentitem/lastaccesseddate.md)

### Inspecting the Application Launch Properties

- [displayURL](tvservices/tvcontentitem/displayurl.md)
- [playURL](tvservices/tvcontentitem/playurl.md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSCoding](foundation/nscoding.md)
- [NSCopying](foundation/nscopying.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)
- [NSSecureCoding](foundation/nssecurecoding.md)

## See Also

### Content

- [TVContentIdentifier](tvservices/tvcontentidentifier.md)
- [TVTopShelfImageSize(shape:style:)](tvservices/tvtopshelfimagesize(shape:style:).md)
