blob: a0c05ab905e2af0da31446b7b84f4496826c0557 [file] [log] [blame]
// Copyright 2019 The Fuchsia Authors. All rights reserved.
// Use of this source is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <lib/zx/time.h>
#include <optional>
#include <string>
#include "src/lib/timekeeper/clock.h"
namespace forensics {
// Formats the provided duration as WdXhYmZs e.g., 1d14h7m32s
std::optional<std::string> FormatDuration(zx::duration duration);
// Returns the non-localized current time according to |clock|.
std::optional<zx::time_utc> CurrentUtcTimeRaw(timekeeper::Clock* clock);
// Returns a non-localized human-readable timestamp of the current time according to |clock|.
std::optional<std::string> CurrentUtcTime(timekeeper::Clock* clock);
} // namespace forensics