Index: content/renderer/media/rtc_certificate.cc |
diff --git a/content/renderer/media/rtc_certificate.cc b/content/renderer/media/rtc_certificate.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..1ef3072ee0589629b2df446b478ba6963f226e90 |
--- /dev/null |
+++ b/content/renderer/media/rtc_certificate.cc |
@@ -0,0 +1,39 @@ |
+// Copyright (c) 2015 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. |
+ |
+#include "content/renderer/media/rtc_certificate.h" |
+ |
+#include "content/renderer/media/peer_connection_identity_store.h" |
+#include "url/gurl.h" |
+ |
+namespace content { |
+ |
+RTCCertificate::RTCCertificate( |
+ const blink::WebRTCKeyType& key_type, |
+ const rtc::scoped_refptr<rtc::RTCCertificate>& certificate) |
+ : key_type_(key_type), certificate_(certificate) { |
+ DCHECK(certificate_); |
+} |
+ |
+RTCCertificate::~RTCCertificate() { |
+} |
+ |
+RTCCertificate* RTCCertificate::shallowCopy() const { |
+ return new RTCCertificate(key_type_, certificate_); |
+} |
+ |
+const blink::WebRTCKeyType& RTCCertificate::keyType() const { |
+ return key_type_; |
+} |
+ |
+double RTCCertificate::expires() const { |
+ return static_cast<double>(certificate_->expires_timestamp_ns()); |
+} |
+ |
+const rtc::scoped_refptr<rtc::RTCCertificate>* |
+RTCCertificate::rtcCertificate() const { |
+ return &certificate_; |
+} |
+ |
+} // namespace content |