chromium/third_party/mediapipe/src/mediapipe/framework/timestamp.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.

#include "mediapipe/framework/timestamp.h"

#include <string>

#include "absl/log/absl_check.h"
#include "absl/log/absl_log.h"
#include "absl/strings/str_cat.h"

namespace mediapipe {

constexpr double Timestamp::kTimestampUnitsPerSecond;

// In the following functions:
// - The safe int type will check for overflow/underflow and other errors.
// - The CHECK in the constructor will disallow special values.
TimestampDiff Timestamp::operator-(const Timestamp other) const {}
TimestampDiff TimestampDiff::operator+(const TimestampDiff other) const {}
TimestampDiff TimestampDiff::operator-(const TimestampDiff other) const {}

// Clamp the addition to the range [Timestamp::Min(), Timestamp::Max()].
Timestamp Timestamp::operator+(const TimestampDiff offset) const {}
Timestamp Timestamp::operator-(const TimestampDiff offset) const {}
Timestamp TimestampDiff::operator+(const Timestamp timestamp) const {}

Timestamp Timestamp::operator+=(const TimestampDiff other) {}
Timestamp Timestamp::operator-=(const TimestampDiff other) {}
Timestamp Timestamp::operator++() {}
Timestamp Timestamp::operator--() {}
Timestamp Timestamp::operator++(int /*unused*/) {}
Timestamp Timestamp::operator--(int /*unused*/) {}

std::string Timestamp::DebugString() const {}
std::string TimestampDiff::DebugString() const {}

Timestamp Timestamp::NextAllowedInStream() const {}

bool Timestamp::HasNextAllowedInStream() const {}

Timestamp Timestamp::PreviousAllowedInStream() const {}

std::ostream& operator<<(std::ostream& os, Timestamp arg) {}
std::ostream& operator<<(std::ostream& os, TimestampDiff arg) {}

}  // namespace mediapipe