chromium/third_party/blink/renderer/modules/mediastream/media_constraints.cc

/*
 * Copyright (C) 2012 Google Inc. All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 *
 *     * Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above
 * copyright notice, this list of conditions and the following disclaimer
 * in the documentation and/or other materials provided with the
 * distribution.
 *     * Neither the name of Google Inc. nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

#include "third_party/blink/renderer/modules/mediastream/media_constraints.h"

#include <math.h>

#include "base/containers/contains.h"
#include "base/memory/scoped_refptr.h"
#include "third_party/blink/renderer/platform/wtf/text/string_builder.h"
#include "third_party/blink/renderer/platform/wtf/text/wtf_string.h"
#include "third_party/blink/renderer/platform/wtf/thread_safe_ref_counted.h"

namespace blink {

namespace {

template <typename T>
void MaybeEmitNamedValue(StringBuilder& builder,
                         bool emit,
                         const char* name,
                         T value) {}

void MaybeEmitNamedBoolean(StringBuilder& builder,
                           bool emit,
                           const char* name,
                           bool value) {}

}  // namespace

class MediaConstraintsPrivate final
    : public ThreadSafeRefCounted<MediaConstraintsPrivate> {};

scoped_refptr<MediaConstraintsPrivate> MediaConstraintsPrivate::Create() {}

scoped_refptr<MediaConstraintsPrivate> MediaConstraintsPrivate::Create(
    const MediaTrackConstraintSetPlatform& basic,
    const Vector<MediaTrackConstraintSetPlatform>& advanced) {}

MediaConstraintsPrivate::MediaConstraintsPrivate(
    const MediaTrackConstraintSetPlatform& basic,
    const Vector<MediaTrackConstraintSetPlatform>& advanced)
    :{}

bool MediaConstraintsPrivate::IsUnconstrained() const {}

const MediaTrackConstraintSetPlatform& MediaConstraintsPrivate::Basic() const {}

MediaTrackConstraintSetPlatform& MediaConstraintsPrivate::MutableBasic() {}

const Vector<MediaTrackConstraintSetPlatform>&
MediaConstraintsPrivate::Advanced() const {}

const String MediaConstraintsPrivate::ToString() const {}

// *Constraints

BaseConstraint::BaseConstraint(const char* name) :{}

BaseConstraint::~BaseConstraint() = default;

bool BaseConstraint::HasMandatory() const {}

LongConstraint::LongConstraint(const char* name)
    :{}

bool LongConstraint::Matches(int32_t value) const {}

bool LongConstraint::IsUnconstrained() const {}

void LongConstraint::ResetToUnconstrained() {}

String LongConstraint::ToString() const {}

const double DoubleConstraint::kConstraintEpsilon =;

DoubleConstraint::DoubleConstraint(const char* name)
    :{}

bool DoubleConstraint::Matches(double value) const {}

bool DoubleConstraint::IsUnconstrained() const {}

void DoubleConstraint::ResetToUnconstrained() {}

String DoubleConstraint::ToString() const {}

StringConstraint::StringConstraint(const char* name)
    :{}

bool StringConstraint::Matches(String value) const {}

bool StringConstraint::IsUnconstrained() const {}

const Vector<String>& StringConstraint::Exact() const {}

const Vector<String>& StringConstraint::Ideal() const {}

void StringConstraint::ResetToUnconstrained() {}

String StringConstraint::ToString() const {}

BooleanConstraint::BooleanConstraint(const char* name)
    :{}

bool BooleanConstraint::Matches(bool value) const {}

bool BooleanConstraint::IsUnconstrained() const {}

void BooleanConstraint::ResetToUnconstrained() {}

String BooleanConstraint::ToString() const {}

MediaTrackConstraintSetPlatform::MediaTrackConstraintSetPlatform()
    :{}

Vector<const BaseConstraint*> MediaTrackConstraintSetPlatform::AllConstraints()
    const {}

bool MediaTrackConstraintSetPlatform::IsUnconstrained() const {}

bool MediaTrackConstraintSetPlatform::HasMandatoryOutsideSet(
    const Vector<String>& good_names,
    String& found_name) const {}

bool MediaTrackConstraintSetPlatform::HasMandatory() const {}

bool MediaTrackConstraintSetPlatform::HasMin() const {}

bool MediaTrackConstraintSetPlatform::HasExact() const {}

String MediaTrackConstraintSetPlatform::ToString() const {}

// MediaConstraints

void MediaConstraints::Assign(const MediaConstraints& other) {}

MediaConstraints::MediaConstraints() = default;

MediaConstraints::MediaConstraints(const MediaConstraints& other) {}

void MediaConstraints::Reset() {}

bool MediaConstraints::IsUnconstrained() const {}

void MediaConstraints::Initialize() {}

void MediaConstraints::Initialize(
    const MediaTrackConstraintSetPlatform& basic,
    const Vector<MediaTrackConstraintSetPlatform>& advanced) {}

const MediaTrackConstraintSetPlatform& MediaConstraints::Basic() const {}

MediaTrackConstraintSetPlatform& MediaConstraints::MutableBasic() {}

const Vector<MediaTrackConstraintSetPlatform>& MediaConstraints::Advanced()
    const {}

const String MediaConstraints::ToString() const {}

}  // namespace blink