Sha256: 2060e0ffc3ac129be28ce2448071f22b46f41dfc1e14108477b7a57d7b71617e

Contents?: true

Size: 1.36 KB

Versions: 9

Compression:

Stored size: 1.36 KB

Contents

/* -*- Mode: C++; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
/*
 *   Copyright 2020-Present Couchbase, Inc.
 *
 *   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.
 */

#pragma once

#include <chrono>
#include <cstdint>

namespace couchbase::core::impl
{
#ifndef COUCHBASE_CXX_CLIENT_DOXYGEN
/**
 * @return value that represents absence of expiry time
 *
 * @since 1.0.0
 * @internal
 */
std::uint32_t
expiry_none();

/**
 * @param expiry number of seconds
 * @return value encoding relative time for KV protocol
 *
 * @since 1.0.0
 * @internal
 */
std::uint32_t
expiry_relative(std::chrono::seconds expiry);

/**
 * @param time_point
 * @return value encoding absolute time for KV protocol
 *
 * @since 1.0.0
 * @internal
 */
std::uint32_t
expiry_absolute(std::chrono::system_clock::time_point time_point);
#endif
} // namespace couchbase::core::impl

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
couchbase-3.5.2 ext/couchbase/couchbase/expiry.hxx
couchbase-3.5.1 ext/couchbase/couchbase/expiry.hxx
couchbase-3.5.0 ext/couchbase/couchbase/expiry.hxx
couchbase-3.4.5 ext/couchbase/couchbase/expiry.hxx
couchbase-3.4.4 ext/couchbase/couchbase/expiry.hxx
couchbase-3.4.3 ext/couchbase/couchbase/expiry.hxx
couchbase-3.4.2 ext/couchbase/couchbase/expiry.hxx
couchbase-3.4.1 ext/couchbase/couchbase/expiry.hxx
couchbase-3.4.0 ext/couchbase/couchbase/expiry.hxx