-
-
Notifications
You must be signed in to change notification settings - Fork 624
Expand file tree
/
Copy pathAccessory.html
More file actions
84 lines (84 loc) · 107 KB
/
Accessory.html
File metadata and controls
84 lines (84 loc) · 107 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
<!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>Accessory | @homebridge/hap-nodejs</title><meta name="description" content="Documentation for @homebridge/hap-nodejs"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">@homebridge/hap-nodejs</a><div id="tsd-toolbar-links"></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="" aria-current="page">Accessory</a></li></ul><h1>Class Accessory</h1></div><section class="tsd-panel tsd-comment"><div class="tsd-comment tsd-typography"><p>Accessory is a virtual HomeKit device. It can publish an associated HAP server for iOS devices to communicate
with - or it can run behind another "Bridge" Accessory server.</p>
<p>Bridged Accessories in this implementation must have a UUID that is unique among all other Accessories that
are hosted by the Bridge. This UUID must be "stable" and unchanging, even when the server is restarted. This
is required so that the Bridge can provide consistent "Accessory IDs" (aid) and "Instance IDs" (iid) for all
Accessories, Services, and Characteristics for iOS clients to reference later.</p>
</div></section><section class="tsd-panel tsd-hierarchy" data-refl="115442"><h4>Hierarchy (<a href="../hierarchy.html#Accessory">View Summary</a>)</h4><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-signature-type">EventEmitter</span><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-hierarchy-target">Accessory</span><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><a href="Bridge.html" class="tsd-signature-type tsd-kind-class">Bridge</a></li></ul></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L354">lib/Accessory.ts:354</a></li><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L393">lib/Accessory.ts:393</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#_isbridge" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>_<wbr/>is<wbr/>Bridge</span></a>
<a href="#aid" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>aid</span></a>
<a href="#bridge" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>bridge?</span></a>
<a href="#bridged" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>bridged</span></a>
<a href="#bridgedaccessories" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>bridged<wbr/>Accessories</span></a>
<a href="#category" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>category</span></a>
<a href="#displayname" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>display<wbr/>Name</span></a>
<a href="#lastknownusername" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>last<wbr/>Known<wbr/>Username?</span></a>
<a href="#reachable" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>reachable</span></a>
<a href="#services" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>services</span></a>
<a href="#shouldpurgeunusedids" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>should<wbr/>Purge<wbr/>Unused<wbr/>I<wbr/>Ds</span></a>
<a href="#uuid" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>UUID</span></a>
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Methods</h3><div class="tsd-index-list"><a href="#addbridgedaccessories" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Bridged<wbr/>Accessories</span></a>
<a href="#addbridgedaccessory" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Bridged<wbr/>Accessory</span></a>
<a href="#addservice" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Service</span></a>
<a href="#configurecontroller" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>configure<wbr/>Controller</span></a>
<a href="#destroy" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>destroy</span></a>
<a href="#disableunusedidpurge" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>disable<wbr/>Unused<wbr/>ID<wbr/>Purge</span></a>
<a href="#emit" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>emit</span></a>
<a href="#enableunusedidpurge" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>enable<wbr/>Unused<wbr/>ID<wbr/>Purge</span></a>
<a href="#getprimaryaccessory" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Primary<wbr/>Accessory</span></a>
<a href="#getservice" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Service</span></a>
<a href="#getservicebyid" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Service<wbr/>By<wbr/>Id</span></a>
<a href="#on" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>on</span></a>
<a href="#publish" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish</span></a>
<a href="#purgeunusedids" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>purge<wbr/>Unused<wbr/>I<wbr/>Ds</span></a>
<a href="#removeallbridgedaccessories" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>All<wbr/>Bridged<wbr/>Accessories</span></a>
<a href="#removebridgedaccessories" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Bridged<wbr/>Accessories</span></a>
<a href="#removebridgedaccessory" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Bridged<wbr/>Accessory</span></a>
<a href="#removecontroller" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Controller</span></a>
<a href="#removeservice" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Service</span></a>
<a href="#setupuri" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>setup<wbr/>URI</span></a>
<a href="#unpublish" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>unpublish</span></a>
<a href="#cleanupaccessorydata" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>cleanup<wbr/>Accessory<wbr/>Data</span></a>
<a href="#deserialize" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>deserialize</span></a>
<a href="#serialize" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>serialize</span></a>
</div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructoraccessory"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">Accessory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">displayName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">UUID</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><a href="#constructoraccessory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">displayName</span>: <span class="tsd-signature-type">string</span></span></li><li><span><span class="tsd-kind-parameter">UUID</span>: <span class="tsd-signature-type">string</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L458">lib/Accessory.ts:458</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="_isbridge"><span>_<wbr/>is<wbr/>Bridge</span><a href="#_isbridge" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">_isBridge</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L401">lib/Accessory.ts:401</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="aid"><span>aid</span><a href="#aid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">aid</span><span class="tsd-signature-symbol">:</span> <a href="../types/Nullable.html" class="tsd-signature-type tsd-kind-type-alias">Nullable</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol"> = null</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L400">lib/Accessory.ts:400</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="bridge"><code class="tsd-tag">Optional</code><span>bridge</span><a href="#bridge" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">bridge</span><span class="tsd-signature-symbol">?:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L403">lib/Accessory.ts:403</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="bridged"><span>bridged</span><a href="#bridged" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">bridged</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L402">lib/Accessory.ts:402</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="bridgedaccessories"><span>bridged<wbr/>Accessories</span><a href="#bridgedaccessories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">bridgedAccessories</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> = []</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L404">lib/Accessory.ts:404</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="category"><span>category</span><a href="#category" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">category</span><span class="tsd-signature-symbol">:</span> <a href="../enums/Categories.html" class="tsd-signature-type tsd-kind-enum">Categories</a><span class="tsd-signature-symbol"> = Categories.OTHER</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L407">lib/Accessory.ts:407</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="displayname"><span>display<wbr/>Name</span><a href="#displayname" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">displayName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L458">lib/Accessory.ts:458</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="lastknownusername"><code class="tsd-tag">Optional</code><span>last<wbr/>Known<wbr/>Username</span><a href="#lastknownusername" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">lastKnownUsername</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L406">lib/Accessory.ts:406</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="reachable"><span>reachable</span><a href="#reachable" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">reachable</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = true</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L405">lib/Accessory.ts:405</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="services"><span>services</span><a href="#services" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">services</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> = []</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L408">lib/Accessory.ts:408</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="shouldpurgeunusedids"><span>should<wbr/>Purge<wbr/>Unused<wbr/>I<wbr/>Ds</span><a href="#shouldpurgeunusedids" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">shouldPurgeUnusedIDs</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = true</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L410">lib/Accessory.ts:410</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="uuid"><span>UUID</span><a href="#uuid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">UUID</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L458">lib/Accessory.ts:458</a></li></ul></aside></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Methods</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="addbridgedaccessories"><span>add<wbr/>Bridged<wbr/>Accessories</span><a href="#addbridgedaccessories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="addbridgedaccessories-1"><span class="tsd-kind-call-signature">addBridgedAccessories</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">accessories</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#addbridgedaccessories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">accessories</span>: <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">[]</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L662">lib/Accessory.ts:662</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="addbridgedaccessory"><span>add<wbr/>Bridged<wbr/>Accessory</span><a href="#addbridgedaccessory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="addbridgedaccessory-1"><span class="tsd-kind-call-signature">addBridgedAccessory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">accessory</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">deferUpdate</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><a href="#addbridgedaccessory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">accessory</span>: <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></span></li><li><span><span class="tsd-kind-parameter">deferUpdate</span>: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L625">lib/Accessory.ts:625</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="addservice"><span>add<wbr/>Service</span><a href="#addservice" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="addservice-1"><span class="tsd-kind-call-signature">addService</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">service</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><a href="#addservice-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Add the given service instance to the Accessory.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">service</span>: <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a></span><div class="tsd-comment tsd-typography"><p>A <a href="Service.html" class="tsd-kind-class">Service</a> instance.</p>
</div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a></h4><p>Returns the service instance passed to the method call.</p>
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L501">lib/Accessory.ts:501</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="addservice-2"><span class="tsd-kind-call-signature">addService</span><span class="tsd-signature-symbol"><</span><a class="tsd-signature-type tsd-kind-type-parameter" href="#addservices">S</a> <span class="tsd-signature-keyword">extends</span> <span class="tsd-signature-keyword">typeof</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">serviceConstructor</span><span class="tsd-signature-symbol">:</span> <a class="tsd-signature-type tsd-kind-type-parameter" href="#addservices">S</a><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-signature-symbol">...</span><span class="tsd-kind-parameter">constructorArgs</span><span class="tsd-signature-symbol">:</span> <a href="../types/ConstructorArgs.html" class="tsd-signature-type tsd-kind-type-alias">ConstructorArgs</a><span class="tsd-signature-symbol"><</span><a class="tsd-signature-type tsd-kind-type-parameter" href="#addservices">S</a><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><a href="#addservice-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds a given service by calling the provided <a href="Service.html" class="tsd-kind-class">Service</a> constructor with the provided constructor arguments.</p>
</div><section class="tsd-panel"><h4>Type Parameters</h4><ul class="tsd-type-parameter-list"><li><span id="addservices"><span class="tsd-kind-type-parameter">S</span> <span class="tsd-signature-keyword">extends</span> <span class="tsd-signature-keyword">typeof</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a></span></li></ul></section><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">serviceConstructor</span>: <a class="tsd-signature-type tsd-kind-type-parameter" href="#addservices">S</a></span><div class="tsd-comment tsd-typography"><p>A <a href="Service.html" class="tsd-kind-class">Service</a> service constructor (e.g. <a href="Service.html#switch" class="tsd-kind-property">Service.Switch</a>).</p>
</div></li><li><span><span class="tsd-signature-symbol">...</span><span class="tsd-kind-parameter">constructorArgs</span>: <a href="../types/ConstructorArgs.html" class="tsd-signature-type tsd-kind-type-alias">ConstructorArgs</a><span class="tsd-signature-symbol"><</span><a class="tsd-signature-type tsd-kind-type-parameter" href="#addservices">S</a><span class="tsd-signature-symbol">></span></span><div class="tsd-comment tsd-typography"><p>The arguments passed to the given constructor.</p>
</div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a></h4><p>Returns the constructed service instance.</p>
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L508">lib/Accessory.ts:508</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="configurecontroller"><span>configure<wbr/>Controller</span><a href="#configurecontroller" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="configurecontroller-1"><span class="tsd-kind-call-signature">configureController</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">controllerConstructor</span><span class="tsd-signature-symbol">:</span><br/> <span class="tsd-signature-symbol">|</span> <a href="../interfaces/Controller.html" class="tsd-signature-type tsd-kind-interface">Controller</a><span class="tsd-signature-symbol"><</span><a href="../interfaces/ControllerServiceMap.html" class="tsd-signature-type tsd-kind-interface">ControllerServiceMap</a><span class="tsd-signature-symbol">></span><br/> <span class="tsd-signature-symbol">|</span> <a href="../interfaces/ControllerConstructor.html" class="tsd-signature-type tsd-kind-interface">ControllerConstructor</a><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#configurecontroller-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>This method is used to set up a new Controller for this accessory. See <a href="../interfaces/Controller.html" class="tsd-kind-interface">Controller</a> for a more detailed
explanation what a Controller is and what it is capable of.</p>
<p>The controller can be passed as an instance of the class or as a constructor (without any necessary parameters)
for a new Controller.
Only one Controller of a given <a href="../types/ControllerIdentifier.html" class="tsd-kind-type-alias">ControllerIdentifier</a> can be configured for a given Accessory.</p>
<p>When called, it will be checked if there are any services and persistent data the Controller (for the given
<a href="../types/ControllerIdentifier.html" class="tsd-kind-type-alias">ControllerIdentifier</a>) can be restored from. Otherwise, the Controller will be created with new services.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">controllerConstructor</span>: <a href="../interfaces/Controller.html" class="tsd-signature-type tsd-kind-interface">Controller</a><span class="tsd-signature-symbol"><</span><a href="../interfaces/ControllerServiceMap.html" class="tsd-signature-type tsd-kind-interface">ControllerServiceMap</a><span class="tsd-signature-symbol">></span> <span class="tsd-signature-symbol">|</span> <a href="../interfaces/ControllerConstructor.html" class="tsd-signature-type tsd-kind-interface">ControllerConstructor</a></span><div class="tsd-comment tsd-typography"><p>The Controller instance or constructor to the Controller with no required arguments.</p>
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L740">lib/Accessory.ts:740</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="destroy"><span>destroy</span><a href="#destroy" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="destroy-1"><span class="tsd-kind-call-signature">destroy</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><a href="#destroy-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes this Accessory from the local network
Accessory object will no longer valid after invoking this method
Trying to invoke publish() on the object will result undefined behavior</p>
</div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1259">lib/Accessory.ts:1259</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="disableunusedidpurge"><span>disable<wbr/>Unused<wbr/>ID<wbr/>Purge</span><a href="#disableunusedidpurge" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="disableunusedidpurge-1"><span class="tsd-kind-call-signature">disableUnusedIDPurge</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#disableunusedidpurge-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1008">lib/Accessory.ts:1008</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="emit"><span>emit</span><a href="#emit" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-1"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"identify"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">paired</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">callback</span><span class="tsd-signature-symbol">:</span> <a href="../types/VoidCallback.html" class="tsd-signature-type tsd-kind-type-alias">VoidCallback</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"identify"</span></span></li><li><span><span class="tsd-kind-parameter">paired</span>: <span class="tsd-signature-type">boolean</span></span></li><li><span><span class="tsd-kind-parameter">callback</span>: <a href="../types/VoidCallback.html" class="tsd-signature-type tsd-kind-type-alias">VoidCallback</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L368">lib/Accessory.ts:368</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-2"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"listening"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">port</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">address</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"listening"</span></span></li><li><span><span class="tsd-kind-parameter">port</span>: <span class="tsd-signature-type">number</span></span></li><li><span><span class="tsd-kind-parameter">address</span>: <span class="tsd-signature-type">string</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L369">lib/Accessory.ts:369</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-3"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"advertised"</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"advertised"</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L370">lib/Accessory.ts:370</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-4"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"service-configurationChange"</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">change</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/ServiceConfigurationChange.html" class="tsd-signature-type tsd-kind-interface">ServiceConfigurationChange</a><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"service-configurationChange"</span></span></li><li><span><span class="tsd-kind-parameter">change</span>: <a href="../interfaces/ServiceConfigurationChange.html" class="tsd-signature-type tsd-kind-interface">ServiceConfigurationChange</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L372">lib/Accessory.ts:372</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-5"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"service-characteristic-change"</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">change</span><span class="tsd-signature-symbol">:</span> <a href="../types/AccessoryCharacteristicChange.html" class="tsd-signature-type tsd-kind-type-alias">AccessoryCharacteristicChange</a><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"service-characteristic-change"</span></span></li><li><span><span class="tsd-kind-parameter">change</span>: <a href="../types/AccessoryCharacteristicChange.html" class="tsd-signature-type tsd-kind-type-alias">AccessoryCharacteristicChange</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L373">lib/Accessory.ts:373</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-6"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"paired"</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-6" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"paired"</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L375">lib/Accessory.ts:375</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-7"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"unpaired"</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-7" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"unpaired"</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L376">lib/Accessory.ts:376</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="emit-8"><span class="tsd-kind-call-signature">emit</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"characteristic-warning"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">warning</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/CharacteristicWarning.html" class="tsd-signature-type tsd-kind-interface">CharacteristicWarning</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#emit-8" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"characteristic-warning"</span></span></li><li><span><span class="tsd-kind-parameter">warning</span>: <a href="../interfaces/CharacteristicWarning.html" class="tsd-signature-type tsd-kind-interface">CharacteristicWarning</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L378">lib/Accessory.ts:378</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="enableunusedidpurge"><span>enable<wbr/>Unused<wbr/>ID<wbr/>Purge</span><a href="#enableunusedidpurge" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="enableunusedidpurge-1"><span class="tsd-kind-call-signature">enableUnusedIDPurge</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#enableunusedidpurge-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1012">lib/Accessory.ts:1012</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getprimaryaccessory"><span>get<wbr/>Primary<wbr/>Accessory</span><a href="#getprimaryaccessory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getprimaryaccessory-1"><span class="tsd-kind-call-signature">getPrimaryAccessory</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><a href="#getprimaryaccessory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the bridging accessory if this accessory is bridged.
Otherwise, returns itself.</p>
</div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></h4><p>the primary accessory</p>
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L621">lib/Accessory.ts:621</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getservice"><span>get<wbr/>Service</span><a href="#getservice" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getservice-1"><span class="tsd-kind-call-signature">getService</span><span class="tsd-signature-symbol"><</span><a class="tsd-signature-type tsd-kind-type-parameter" href="#getservicet">T</a> <span class="tsd-signature-keyword">extends</span> <a href="../types/WithUUID.html" class="tsd-signature-type tsd-kind-type-alias">WithUUID</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-keyword">typeof</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <a class="tsd-signature-type tsd-kind-type-parameter" href="#getservicet">T</a><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">undefined</span><a href="#getservice-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><section class="tsd-panel"><h4>Type Parameters</h4><ul class="tsd-type-parameter-list"><li><span id="getservicet"><span class="tsd-kind-type-parameter">T</span> <span class="tsd-signature-keyword">extends</span> <a href="../types/WithUUID.html" class="tsd-signature-type tsd-kind-type-alias">WithUUID</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-keyword">typeof</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">></span></span></li></ul></section><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">name</span>: <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <a class="tsd-signature-type tsd-kind-type-parameter" href="#getservicet">T</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">undefined</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L585">lib/Accessory.ts:585</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getservicebyid"><span>get<wbr/>Service<wbr/>By<wbr/>Id</span><a href="#getservicebyid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getservicebyid-1"><span class="tsd-kind-call-signature">getServiceById</span><span class="tsd-signature-symbol"><</span><a class="tsd-signature-type tsd-kind-type-parameter" href="#getservicebyidt">T</a> <span class="tsd-signature-keyword">extends</span> <a href="../types/WithUUID.html" class="tsd-signature-type tsd-kind-type-alias">WithUUID</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-keyword">typeof</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">uuid</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <a class="tsd-signature-type tsd-kind-type-parameter" href="#getservicebyidt">T</a><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">subType</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">undefined</span><a href="#getservicebyid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><section class="tsd-panel"><h4>Type Parameters</h4><ul class="tsd-type-parameter-list"><li><span id="getservicebyidt"><span class="tsd-kind-type-parameter">T</span> <span class="tsd-signature-keyword">extends</span> <a href="../types/WithUUID.html" class="tsd-signature-type tsd-kind-type-alias">WithUUID</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-keyword">typeof</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">></span></span></li></ul></section><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">uuid</span>: <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <a class="tsd-signature-type tsd-kind-type-parameter" href="#getservicebyidt">T</a></span></li><li><span><span class="tsd-kind-parameter">subType</span>: <span class="tsd-signature-type">string</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">undefined</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L600">lib/Accessory.ts:600</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="on"><span>on</span><a href="#on" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="on-1"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"identify"</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">paired</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">callback</span><span class="tsd-signature-symbol">:</span> <a href="../types/VoidCallback.html" class="tsd-signature-type tsd-kind-type-alias">VoidCallback</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"identify"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">paired</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">callback</span><span class="tsd-signature-symbol">:</span> <a href="../types/VoidCallback.html" class="tsd-signature-type tsd-kind-type-alias">VoidCallback</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L355">lib/Accessory.ts:355</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-2"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"listening"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">port</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">address</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"listening"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">port</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">address</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L356">lib/Accessory.ts:356</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-3"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"advertised"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">()</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"advertised"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">()</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L357">lib/Accessory.ts:357</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-4"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"service-configurationChange"</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">change</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/ServiceConfigurationChange.html" class="tsd-signature-type tsd-kind-interface">ServiceConfigurationChange</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"service-configurationChange"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">change</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/ServiceConfigurationChange.html" class="tsd-signature-type tsd-kind-interface">ServiceConfigurationChange</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L359">lib/Accessory.ts:359</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-5"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"service-characteristic-change"</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">change</span><span class="tsd-signature-symbol">:</span> <a href="../types/AccessoryCharacteristicChange.html" class="tsd-signature-type tsd-kind-type-alias">AccessoryCharacteristicChange</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"service-characteristic-change"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">change</span><span class="tsd-signature-symbol">:</span> <a href="../types/AccessoryCharacteristicChange.html" class="tsd-signature-type tsd-kind-type-alias">AccessoryCharacteristicChange</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L360">lib/Accessory.ts:360</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-6"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"paired"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">()</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-6" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"paired"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">()</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L362">lib/Accessory.ts:362</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-7"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"unpaired"</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">()</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-7" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"unpaired"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">()</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L363">lib/Accessory.ts:363</a></li></ul></aside></div></li><li class=""><div class="tsd-signature tsd-anchor-link" id="on-8"><span class="tsd-kind-call-signature">on</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">event</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"characteristic-warning"</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">listener</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">warning</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/CharacteristicWarning.html" class="tsd-signature-type tsd-kind-interface">CharacteristicWarning</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">this</span><a href="#on-8" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">event</span>: <span class="tsd-signature-type">"characteristic-warning"</span></span></li><li><span><span class="tsd-kind-parameter">listener</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">warning</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/CharacteristicWarning.html" class="tsd-signature-type tsd-kind-interface">CharacteristicWarning</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">void</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">this</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L365">lib/Accessory.ts:365</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publish"><span>publish</span><a href="#publish" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publish-1"><span class="tsd-kind-call-signature">publish</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">info</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/PublishInfo.html" class="tsd-signature-type tsd-kind-interface">PublishInfo</a><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">allowInsecureRequest</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><a href="#publish-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Publishes this accessory on the local network for iOS clients to communicate with.</p>
<ul>
<li><code>info.username</code> - formatted as a MAC address, like <code>CC:22:3D:E3:CE:F6</code>, of this accessory.
Must be globally unique from all Accessories on your local network.</li>
<li><code>info.pincode</code> - the 8-digit pin code for clients to use when pairing this Accessory.
Must be formatted as a string like <code>031-45-154</code>.</li>
<li><code>info.category</code> - one of the values of the <code>Accessory.Category</code> enum, like <code>Accessory.Category.SWITCH</code>.
This is a hint to iOS clients about what "type" of Accessory this represents, so
that for instance an appropriate icon can be drawn for the user while adding a
new Accessory.</li>
</ul>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">info</span>: <a href="../interfaces/PublishInfo.html" class="tsd-signature-type tsd-kind-interface">PublishInfo</a></span><div class="tsd-comment tsd-typography"><p>Required info for publishing.</p>
</div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">allowInsecureRequest</span>: <span class="tsd-signature-type">boolean</span></span><div class="tsd-comment tsd-typography"><p>Will allow unencrypted and unauthenticated access to the http server</p>
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1099">lib/Accessory.ts:1099</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="purgeunusedids"><span>purge<wbr/>Unused<wbr/>I<wbr/>Ds</span><a href="#purgeunusedids" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="purgeunusedids-1"><span class="tsd-kind-call-signature">purgeUnusedIDs</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#purgeunusedids-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Manually purge the unused ids if you like, comes handy
when you have disabled auto purge, so you can do it manually</p>
</div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1020">lib/Accessory.ts:1020</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="removeallbridgedaccessories"><span>remove<wbr/>All<wbr/>Bridged<wbr/>Accessories</span><a href="#removeallbridgedaccessories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="removeallbridgedaccessories-1"><span class="tsd-kind-call-signature">removeAllBridgedAccessories</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#removeallbridgedaccessories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L696">lib/Accessory.ts:696</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="removebridgedaccessories"><span>remove<wbr/>Bridged<wbr/>Accessories</span><a href="#removebridgedaccessories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="removebridgedaccessories-1"><span class="tsd-kind-call-signature">removeBridgedAccessories</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">accessories</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#removebridgedaccessories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">accessories</span>: <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">[]</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L688">lib/Accessory.ts:688</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="removebridgedaccessory"><span>remove<wbr/>Bridged<wbr/>Accessory</span><a href="#removebridgedaccessory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="removebridgedaccessory-1"><span class="tsd-kind-call-signature">removeBridgedAccessory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">accessory</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">deferUpdate</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#removebridgedaccessory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">accessory</span>: <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></span></li><li><span><span class="tsd-kind-parameter">deferUpdate</span>: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L670">lib/Accessory.ts:670</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="removecontroller"><span>remove<wbr/>Controller</span><a href="#removecontroller" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="removecontroller-1"><span class="tsd-kind-call-signature">removeController</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">controller</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/Controller.html" class="tsd-signature-type tsd-kind-interface">Controller</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#removecontroller-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>This method will remove a given Controller from this accessory.
The controller object will be restored to its initial state.
This also means that any event handlers setup for the controller will be removed.</p>
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">controller</span>: <a href="../interfaces/Controller.html" class="tsd-signature-type tsd-kind-interface">Controller</a></span><div class="tsd-comment tsd-typography"><p>The controller which should be removed from the accessory.</p>
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L806">lib/Accessory.ts:806</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="removeservice"><span>remove<wbr/>Service</span><a href="#removeservice" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="removeservice-1"><span class="tsd-kind-call-signature">removeService</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">service</span><span class="tsd-signature-symbol">:</span> <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#removeservice-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">service</span>: <a href="Service.html" class="tsd-signature-type tsd-kind-class">Service</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L558">lib/Accessory.ts:558</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="setupuri"><span>setup<wbr/>URI</span><a href="#setupuri" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="setupuri-1"><span class="tsd-kind-call-signature">setupURI</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#setupuri-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L889">lib/Accessory.ts:889</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="unpublish"><span>unpublish</span><a href="#unpublish" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="unpublish-1"><span class="tsd-kind-call-signature">unpublish</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><a href="#unpublish-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1274">lib/Accessory.ts:1274</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="cleanupaccessorydata"><code class="tsd-tag">Static</code><span>cleanup<wbr/>Accessory<wbr/>Data</span><a href="#cleanupaccessorydata" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="cleanupaccessorydata-1"><span class="tsd-kind-call-signature">cleanupAccessoryData</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">username</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#cleanupaccessorydata-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">username</span>: <span class="tsd-signature-type">string</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L2081">lib/Accessory.ts:2081</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deserialize"><code class="tsd-tag">Static</code><span>deserialize</span><a href="#deserialize" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deserialize-1"><span class="tsd-kind-call-signature">deserialize</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">json</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/SerializedAccessory.html" class="tsd-signature-type tsd-kind-interface">SerializedAccessory</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><a href="#deserialize-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">json</span>: <a href="../interfaces/SerializedAccessory.html" class="tsd-signature-type tsd-kind-interface">SerializedAccessory</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L2034">lib/Accessory.ts:2034</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="serialize"><code class="tsd-tag">Static</code><span>serialize</span><a href="#serialize" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="serialize-1"><span class="tsd-kind-call-signature">serialize</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">accessory</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/SerializedAccessory.html" class="tsd-signature-type tsd-kind-interface">SerializedAccessory</a><a href="#serialize-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">accessory</span>: <a href="" class="tsd-signature-type tsd-kind-class">Accessory</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="../interfaces/SerializedAccessory.html" class="tsd-signature-type tsd-kind-interface">SerializedAccessory</a></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/homebridge/HAP-NodeJS/blob/cd7fca24e1ee3fa99ce0a968c7b0346a781d7f71/src/lib/Accessory.ts#L1977">lib/Accessory.ts:1977</a></li></ul></aside></div></li></ul></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#_isbridge"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>_<wbr/>is<wbr/>Bridge</span></a><a href="#aid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>aid</span></a><a href="#bridge"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>bridge</span></a><a href="#bridged"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>bridged</span></a><a href="#bridgedaccessories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>bridged<wbr/>Accessories</span></a><a href="#category"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>category</span></a><a href="#displayname"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>display<wbr/>Name</span></a><a href="#lastknownusername"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>last<wbr/>Known<wbr/>Username</span></a><a href="#reachable"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>reachable</span></a><a href="#services"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>services</span></a><a href="#shouldpurgeunusedids"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>should<wbr/>Purge<wbr/>Unused<wbr/>I<wbr/>Ds</span></a><a href="#uuid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>UUID</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#addbridgedaccessories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Bridged<wbr/>Accessories</span></a><a href="#addbridgedaccessory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Bridged<wbr/>Accessory</span></a><a href="#addservice"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Service</span></a><a href="#configurecontroller"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>configure<wbr/>Controller</span></a><a href="#destroy"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>destroy</span></a><a href="#disableunusedidpurge"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>disable<wbr/>Unused<wbr/>ID<wbr/>Purge</span></a><a href="#emit"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>emit</span></a><a href="#enableunusedidpurge"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>enable<wbr/>Unused<wbr/>ID<wbr/>Purge</span></a><a href="#getprimaryaccessory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Primary<wbr/>Accessory</span></a><a href="#getservice"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Service</span></a><a href="#getservicebyid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Service<wbr/>By<wbr/>Id</span></a><a href="#on"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>on</span></a><a href="#publish"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish</span></a><a href="#purgeunusedids"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>purge<wbr/>Unused<wbr/>I<wbr/>Ds</span></a><a href="#removeallbridgedaccessories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>All<wbr/>Bridged<wbr/>Accessories</span></a><a href="#removebridgedaccessories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Bridged<wbr/>Accessories</span></a><a href="#removebridgedaccessory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Bridged<wbr/>Accessory</span></a><a href="#removecontroller"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Controller</span></a><a href="#removeservice"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Service</span></a><a href="#setupuri"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>setup<wbr/>URI</span></a><a href="#unpublish"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>unpublish</span></a><a href="#cleanupaccessorydata"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>cleanup<wbr/>Accessory<wbr/>Data</span></a><a href="#deserialize"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>deserialize</span></a><a href="#serialize"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>serialize</span></a></div></details></div></details></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html">@homebridge/hap-nodejs</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer></footer><div class="overlay"></div></body></html>