<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreVideo",
  "identifier" : "/documentation/CoreVideo/CVAttachmentContainer/attachedMode(of:)-p6ms",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Core Video"
    ],
    "preciseIdentifier" : "s:9CoreVideo21CVAttachmentContainerV12attachedMode2ofSo0cF0VSgSS_tF"
  },
  "title" : "attachedMode(of:)"
}
-->

# attachedMode(of:)

Returns the propagation mode of a stored attachment you identify by its raw key string, without retrieving the value.

```
func attachedMode(of key: String) -> CVAttachmentMode?
```

## Parameters

`key`

The raw string that identifies the attachment.

## Return Value

The propagation mode of the attachment, or `nil` if the key isn’t attached.

## Discussion

Use this method to check for the presence of a specific key without converting its value.

This overload takes the key as a string, which is how you reach an attachment whose key isn’t declared as a property of the key definitions type, such as a custom key your app attaches. To pass a declared key, use its [`rawValue`](/documentation/CoreVideo/CVAttachmentKeyDefinition/rawValue).

---

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)