# ItemID

## Declaration

{% tabs %}
{% tab title="👔 ItemID" %}
```swift
// ⭐️ defined in Item.swift
public typealias ItemID = Int

public protocol Identifiable {
    /// A unique identifier that is used to describe items when
    /// sending and receiving commands.
    var id: ItemID { get }
}
```
{% endtab %}

{% tab title="👔 Identifier" %}
```swift
// internal enum (used as a namespace)
enum Identifier {
    static let undefined = -1
    static let world = 0
}
```
{% endtab %}

{% tab title="👥 相關" %}
* [identifiable](../../../swift/type/category/protocol/identifiable "mention")
{% endtab %}
{% endtabs %}

:arrow\_lower\_right: inherited by：[🅿️ Item](item)

## Instance Property

| 屬性     | 型別     | 說明 |
| ------ | ------ | -- |
| **id** | ItemID |    |
