---
title: CLKTimeTextProvider
framework: clockkit
role: symbol
role_heading: Class
path: clockkit/clktimetextprovider
---

# CLKTimeTextProvider

A formatted time value.

## Declaration

```swift
class CLKTimeTextProvider
```

## Mentioned in

Creating a timeline entry

## Overview

Overview This provider supports time values in either the 24-hour or 12-hour format and takes into account the user’s region and locale settings. As needed, the provider automatically shortens the string to fit the available space. When formatting the time, the time text provider drops the morning/evening indicator if it can’t fit the entire time value. For example, a provider configured to display the time 10:09AM in the English-US locale would remove elements as follows until it encountered a string that fit the available space: 10:09AM 10:09

## Topics

### Creating a Text Provider

- [init(date:)](clockkit/clktimetextprovider/init(date:).md)
- [init(date:timeZone:)](clockkit/clktimetextprovider/init(date:timezone:).md)

### Getting the Time Information

- [date](clockkit/clktimetextprovider/date.md)
- [timeZone](clockkit/clktimetextprovider/timezone.md)

## Relationships

### Inherits From

- [CLKTextProvider](clockkit/clktextprovider.md)

### Conforms To

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

## See Also

### Text providers

- [CLKSimpleTextProvider](clockkit/clksimpletextprovider.md)
- [CLKDateTextProvider](clockkit/clkdatetextprovider.md)
- [CLKRelativeDateTextProvider](clockkit/clkrelativedatetextprovider.md)
- [CLKTimeIntervalTextProvider](clockkit/clktimeintervaltextprovider.md)
- [CLKTextProvider](clockkit/clktextprovider.md)
