Chromium Code Reviews| Index: remoting/protocol/pepper_channel.h |
| diff --git a/remoting/protocol/pepper_channel.h b/remoting/protocol/pepper_channel.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..a356ade8a58cd6fa5432e9649c120fa7a0bbc190 |
| --- /dev/null |
| +++ b/remoting/protocol/pepper_channel.h |
| @@ -0,0 +1,55 @@ |
| +// Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef REMOTING_PROTOCOL_PEPPER_CHANNEL_H_ |
| +#define REMOTING_PROTOCOL_PEPPER_CHANNEL_H_ |
| + |
| +#include <string> |
| + |
| +#include "base/basictypes.h" |
| +#include "base/threading/non_thread_safe.h" |
| + |
| +namespace pp { |
| +class Instance; |
| +} // namespace pp |
| + |
| +namespace crypto { |
| +class RSAPrivateKey; |
| +} // namespace crypto |
| + |
| +namespace cricket { |
| +class Candidate; |
| +} // namespace cricket |
| + |
| +namespace remoting { |
| +namespace protocol { |
| + |
| +struct TransportConfig; |
| + |
| +// Interface for protocol channels. There will be two implementations: |
| +// PepperStreamChannel and PepperDatagramChannel. |
|
Wez
2011/09/09 23:39:12
This is actually an interface defining functions c
Sergey Ulanov
2011/09/12 19:50:50
Done.
|
| +class PepperChannel : public base::NonThreadSafe { |
| + public: |
| + PepperChannel() { } |
| + virtual ~PepperChannel() { } |
| + |
| + // Connect the channel using specified |config|. |
| + virtual void Connect(pp::Instance* pp_instance, |
| + const TransportConfig& config, |
| + const std::string& remote_cert) = 0; |
| + |
| + // Adds |candidate| received from the peer. |
| + virtual void AddRemoveCandidate(const cricket::Candidate& candidate) = 0; |
| + |
| + // Name of the channel. |
| + virtual const std::string& name() = 0; |
| + |
| + protected: |
| + DISALLOW_COPY_AND_ASSIGN(PepperChannel); |
| +}; |
| + |
| +} // namespace protocol |
| +} // namespace remoting |
| + |
| +#endif // REMOTING_PROTOCOL_PEPPER_CHANNEL_H_ |