OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 // Setup related functions for a Google Cloud Devices (GCD) target device |
| 6 // running on Chrome OS Core. The actual bootstrapping and GCD registration is |
| 7 // handled by the privetd and buffet system daemons. |
| 8 namespace shell.gcd { |
| 9 |
| 10 enum SetupStatus { |
| 11 // Not yet configured. Waiting for a connection from the phone or laptop |
| 12 // setup app. |
| 13 unconfigured, |
| 14 |
| 15 // Displaying code for user to verify they wish to set up this device. |
| 16 confirmingSetup, |
| 17 |
| 18 // Establishing a secure connection to the setup device and exchanging the |
| 19 // Wi-Fi credentials. |
| 20 exchangingCredentials, |
| 21 |
| 22 // Connecting to the local network. |
| 23 connectingToNetwork, |
| 24 |
| 25 // Registering with the GCD backend. |
| 26 registering, |
| 27 |
| 28 // Setup completed. |
| 29 completed |
| 30 }; |
| 31 |
| 32 callback SetupStatusCallback = void(SetupStatus status); |
| 33 |
| 34 interface Functions { |
| 35 // Returns the current setup status via |callback|. |
| 36 static void getSetupStatus(SetupStatusCallback callback); |
| 37 }; |
| 38 |
| 39 interface Events { |
| 40 // Notifies that setup has transitioned to a new |status|. |
| 41 static void onSetupStatusChanged(SetupStatus status); |
| 42 }; |
| 43 }; |
OLD | NEW |