<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MusicUnderstanding",
  "identifier" : "/documentation/MusicUnderstanding/MusicUnderstandingSession/TimedValue",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Music Understanding",
      "MusicUnderstanding"
    ],
    "preciseIdentifier" : "s:18MusicUnderstanding0aB7SessionC10TimedValueV"
  },
  "title" : "MusicUnderstandingSession.TimedValue"
}
-->

# MusicUnderstandingSession.TimedValue

A structure that pairs a value with a time.

```
struct TimedValue<Value> where Value : Decodable, Value : Encodable, Value : Equatable, Value : Sendable
```

## Overview

The `TimedValue` pairs a value with a `CMTime` point — a measurement at a specific instant, as opposed to a span. Contrast: properties that hold constant over a span (key, pace) use RangedValue with a `CMTimeRange`; instantaneous measurements use `TimedValue` with a `CMTime`.

## Topics

### Getting the time

[`let time: CMTime`](/documentation/MusicUnderstanding/MusicUnderstandingSession/TimedValue/time)

The time at which the value applies.

### Getting the value

[`let value: Value`](/documentation/MusicUnderstanding/MusicUnderstandingSession/TimedValue/value)

The value associated with the time.

### Initializers

[`init(from: any Decoder) throws`](/documentation/MusicUnderstanding/MusicUnderstandingSession/TimedValue/init(from:))

Creates a timed value by decoding from the given decoder.

### Instance Methods

[`func encode(to: any Encoder) throws`](/documentation/MusicUnderstanding/MusicUnderstandingSession/TimedValue/encode(to:))

Encodes the timed value into the given encoder.

## Relationships

### Conforms To

[`Sendable`](/documentation/Swift/Sendable)

[`Equatable`](/documentation/Swift/Equatable)

[`Encodable`](/documentation/Swift/Encodable)

[`Decodable`](/documentation/Swift/Decodable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)