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#ifndef CHROME_BROWSER_LOCAL_DISCOVERY_PRIVETV3_SETUP_OPERATION_H_
6#define CHROME_BROWSER_LOCAL_DISCOVERY_PRIVETV3_SETUP_OPERATION_H_
7
8#include <string>
9
10#include "base/callback.h"
11#include "base/memory/scoped_ptr.h"
12
13namespace local_discovery {
14
15class PrivetV3Session;
16
17class PrivetV3SetupOperation {
18 public:
19  enum Status { STATUS_SUCCESS, STATUS_SETUP_ERROR, STATUS_SESSION_ERROR };
20
21  virtual ~PrivetV3SetupOperation() {}
22
23  typedef base::Callback<void(Status status)> SetupStatusCallback;
24
25  static scoped_ptr<PrivetV3SetupOperation> Create(
26      PrivetV3Session* session,
27      const SetupStatusCallback& callback,
28      const std::string& ticket_id);
29
30  virtual void AddWifiCredentials(const std::string& ssid,
31                                  const std::string& passwd) = 0;
32  virtual void Start() = 0;
33};
34
35}  // namespace local_discovery
36
37#endif  // CHROME_BROWSER_LOCAL_DISCOVERY_PRIVETV3_SETUP_OPERATION_H_
38