chromium/third_party/mediapipe/src/mediapipe/framework/packet_type.cc

// Copyright 2019 The MediaPipe Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//      http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

// Definitions for PacketType and PacketTypeSet.

#include "mediapipe/framework/packet_type.h"

#include <unordered_set>
#include <utility>

#include "absl/status/status.h"
#include "absl/strings/str_cat.h"
#include "absl/strings/str_join.h"
#include "absl/types/span.h"
#include "absl/types/variant.h"
#include "mediapipe/framework/port/canonical_errors.h"
#include "mediapipe/framework/port/logging.h"
#include "mediapipe/framework/port/map_util.h"
#include "mediapipe/framework/port/source_location.h"
#include "mediapipe/framework/port/status_builder.h"
#include "mediapipe/framework/tool/status_util.h"
#include "mediapipe/framework/tool/type_util.h"
#include "mediapipe/framework/tool/validate_name.h"
#include "mediapipe/framework/type_map.h"

namespace mediapipe {

absl::Status PacketType::AcceptAny(const TypeSpec& type) {}

absl::Status PacketType::AcceptNone(const TypeSpec& type) {}

PacketType& PacketType::SetAny() {}

PacketType& PacketType::SetNone() {}

PacketType& PacketType::SetSameAs(const PacketType* type) {}

PacketType& PacketType::Optional() {}

bool PacketType::IsInitialized() const {}

const PacketType* PacketType::SameAsPtr() const {}

PacketType* PacketType::GetSameAs() {}

const PacketType* PacketType::GetSameAs() const {}

bool PacketType::IsAny() const {}

bool PacketType::IsNone() const {}

bool PacketType::IsOneOf() const {}

bool PacketType::IsExactType() const {}

const std::string* PacketType::RegisteredTypeName() const {}

namespace internal {

struct TypeIdFormatter {};

template <class Formatter>
class QuoteFormatter {};
template <class Formatter>
explicit QuoteFormatter(Formatter f) -> QuoteFormatter<Formatter>;

}  // namespace internal

std::string PacketType::TypeNameForOneOf(TypeIdSpan types) {}

std::string PacketType::DebugTypeName() const {}

static bool HaveCommonType(absl::Span<const TypeId> types1,
                           absl::Span<const TypeId> types2) {}

absl::Status PacketType::Validate(const Packet& packet) const {}

PacketType::TypeIdSpan PacketType::GetTypeSpan(const TypeSpec& type_spec) {}

bool PacketType::IsConsistentWith(const PacketType& other) const {}

absl::Status ValidatePacketTypeSet(const PacketTypeSet& packet_type_set) {}

absl::Status ValidatePacketSet(const PacketTypeSet& packet_type_set,
                               const PacketSet& packet_set) {}

}  // namespace mediapipe