OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
520 | 520 |
521 void WebMediaConstraints::Reset() { | 521 void WebMediaConstraints::Reset() { |
522 private_.Reset(); | 522 private_.Reset(); |
523 } | 523 } |
524 | 524 |
525 bool WebMediaConstraints::IsEmpty() const { | 525 bool WebMediaConstraints::IsEmpty() const { |
526 return private_.IsNull() || private_->IsEmpty(); | 526 return private_.IsNull() || private_->IsEmpty(); |
527 } | 527 } |
528 | 528 |
529 void WebMediaConstraints::Initialize() { | 529 void WebMediaConstraints::Initialize() { |
530 ASSERT(IsNull()); | 530 DCHECK(IsNull()); |
531 private_ = WebMediaConstraintsPrivate::Create(); | 531 private_ = WebMediaConstraintsPrivate::Create(); |
532 } | 532 } |
533 | 533 |
534 void WebMediaConstraints::Initialize( | 534 void WebMediaConstraints::Initialize( |
535 const WebMediaTrackConstraintSet& basic, | 535 const WebMediaTrackConstraintSet& basic, |
536 const WebVector<WebMediaTrackConstraintSet>& advanced) { | 536 const WebVector<WebMediaTrackConstraintSet>& advanced) { |
537 ASSERT(IsNull()); | 537 DCHECK(IsNull()); |
538 private_ = WebMediaConstraintsPrivate::Create(basic, advanced); | 538 private_ = WebMediaConstraintsPrivate::Create(basic, advanced); |
539 } | 539 } |
540 | 540 |
541 const WebMediaTrackConstraintSet& WebMediaConstraints::Basic() const { | 541 const WebMediaTrackConstraintSet& WebMediaConstraints::Basic() const { |
542 ASSERT(!IsNull()); | 542 DCHECK(!IsNull()); |
543 return private_->Basic(); | 543 return private_->Basic(); |
544 } | 544 } |
545 | 545 |
546 const WebVector<WebMediaTrackConstraintSet>& WebMediaConstraints::Advanced() | 546 const WebVector<WebMediaTrackConstraintSet>& WebMediaConstraints::Advanced() |
547 const { | 547 const { |
548 ASSERT(!IsNull()); | 548 DCHECK(!IsNull()); |
549 return private_->Advanced(); | 549 return private_->Advanced(); |
550 } | 550 } |
551 | 551 |
552 const WebString WebMediaConstraints::ToString() const { | 552 const WebString WebMediaConstraints::ToString() const { |
553 if (IsNull()) | 553 if (IsNull()) |
554 return WebString(""); | 554 return WebString(""); |
555 return private_->ToString(); | 555 return private_->ToString(); |
556 } | 556 } |
557 | 557 |
558 } // namespace blink | 558 } // namespace blink |
OLD | NEW |