---
title: XCSourceEditorCommandInvocation
framework: XcodeKit
role: symbol
role_heading: Class
platforms: [macOS 10.12+]
path: xcodekit/xcsourceeditorcommandinvocation
---

# XCSourceEditorCommandInvocation

An object that identifies the command issued to your extension and provides the contents of the active source editor.

## Declaration

```swift
class XCSourceEditorCommandInvocation
```

## Topics

### Responding to Commands

- [buffer](xcodekit/xcsourceeditorcommandinvocation/buffer.md)
- [commandIdentifier](xcodekit/xcsourceeditorcommandinvocation/commandidentifier.md)

### Responding to Cancelled Commands

- [cancellationHandler](xcodekit/xcsourceeditorcommandinvocation/cancellationhandler.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)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Editor Commands

- [XCSourceEditorCommand](xcodekit/xcsourceeditorcommand.md)
