mirror of
https://github.com/kidfromjupiter/nearby.git
synced 2026-09-16 07:36:10 -04:00
Merge branch 'master' into release
Change-Id: I56ea2217899e92bdd9d6cb56797ac9895e194fff
This commit is contained in:
@@ -29,17 +29,17 @@ namespace mediums {
|
||||
// p2p connection.
|
||||
class PeerId {
|
||||
public:
|
||||
explicit PeerId(const string& id) : id_(id) {}
|
||||
explicit PeerId(const std::string& id) : id_(id) {}
|
||||
~PeerId() = default;
|
||||
|
||||
static ConstPtr<PeerId> FromRandom(Ptr<HashUtils> hash_utils);
|
||||
static ConstPtr<PeerId> FromSeed(ConstPtr<ByteArray> seed,
|
||||
Ptr<HashUtils> hash_utils);
|
||||
|
||||
const string& GetId() const { return id_; }
|
||||
const std::string& GetId() const { return id_; }
|
||||
|
||||
private:
|
||||
const string id_;
|
||||
const std::string id_;
|
||||
};
|
||||
|
||||
} // namespace mediums
|
||||
|
||||
@@ -60,7 +60,7 @@ Exception::Value WebRtcSocket<Platform>::OutputStreamImpl::close() {
|
||||
// WebRtcSocket
|
||||
template <typename Platform>
|
||||
WebRtcSocket<Platform>::WebRtcSocket(
|
||||
const string& name,
|
||||
const std::string& name,
|
||||
rtc::scoped_refptr<webrtc::DataChannelInterface> data_channel)
|
||||
: name_(name),
|
||||
data_channel_(std::move(data_channel)),
|
||||
|
||||
@@ -38,7 +38,7 @@ constexpr int kMaxDataSize = 1 * 1024 * 1024;
|
||||
template <typename Platform>
|
||||
class WebRtcSocket : public Socket {
|
||||
public:
|
||||
WebRtcSocket(const string& name,
|
||||
WebRtcSocket(const std::string& name,
|
||||
rtc::scoped_refptr<webrtc::DataChannelInterface> data_channel);
|
||||
~WebRtcSocket() override = default;
|
||||
|
||||
@@ -91,7 +91,7 @@ class WebRtcSocket : public Socket {
|
||||
bool SendMessage(ConstPtr<ByteArray> data);
|
||||
void BlockUntilSufficientSpaceInBuffer(int length);
|
||||
|
||||
string name_;
|
||||
std::string name_;
|
||||
rtc::scoped_refptr<webrtc::DataChannelInterface> data_channel_;
|
||||
|
||||
Ptr<Pipe> pipe_;
|
||||
|
||||
Reference in New Issue
Block a user