proxygen
|
#include <Optional.h>
Classes | |
struct | PrivateConstructor |
struct | StorageNonTriviallyDestructible |
struct | StorageTriviallyDestructible |
Public Types | |
typedef Value | value_type |
Public Member Functions | |
FOLLY_CPP14_CONSTEXPR | Optional () noexcept |
Optional (const Optional &src) noexcept(std::is_nothrow_copy_constructible< Value >::value) | |
Optional (Optional &&src) noexcept(std::is_nothrow_move_constructible< Value >::value) | |
FOLLY_CPP14_CONSTEXPR | Optional (const None &) noexcept |
FOLLY_CPP14_CONSTEXPR | Optional (Value &&newValue) noexcept(std::is_nothrow_move_constructible< Value >::value) |
FOLLY_CPP14_CONSTEXPR | Optional (const Value &newValue) noexcept(std::is_nothrow_copy_constructible< Value >::value) |
template<typename Null = std::nullptr_t> | |
FOLLY_CPP14_CONSTEXPR | Optional (typename std::enable_if< !std::is_pointer< Value >::value &&std::is_same< Null, std::nullptr_t >::value, Null >::type) noexcept |
template<typename... Args> | |
FOLLY_CPP14_CONSTEXPR | Optional (in_place_t, Args &&...args) noexcept(std::is_nothrow_constructible< Value, Args... >::value) |
template<typename U , typename... Args> | |
FOLLY_CPP14_CONSTEXPR | Optional (in_place_t, std::initializer_list< U > il, Args &&...args) noexcept(std::is_nothrow_constructible< Value, std::initializer_list< U >, Args... >::value) |
Optional (const detail::OptionalPromiseReturn< Value > &p) | |
void | assign (const None &) |
void | assign (Optional &&src) |
void | assign (const Optional &src) |
void | assign (Value &&newValue) |
void | assign (const Value &newValue) |
Optional & | operator= (None) noexcept |
template<class Arg > | |
Optional & | operator= (Arg &&arg) |
Optional & | operator= (Optional &&other) noexcept(std::is_nothrow_move_assignable< Value >::value) |
Optional & | operator= (const Optional &other) noexcept(std::is_nothrow_copy_assignable< Value >::value) |
template<class... Args> | |
Value & | emplace (Args &&...args) |
template<class U , class... Args> | |
std::enable_if< std::is_constructible< Value, std::initializer_list< U > &, Args &&... >::value, Value & >::type | emplace (std::initializer_list< U > ilist, Args &&...args) |
void | reset () noexcept |
void | clear () noexcept |
void | swap (Optional &that) noexcept(IsNothrowSwappable< Value >::value) |
FOLLY_CPP14_CONSTEXPR const Value & | value () const & |
FOLLY_CPP14_CONSTEXPR Value & | value ()& |
FOLLY_CPP14_CONSTEXPR Value && | value ()&& |
FOLLY_CPP14_CONSTEXPR const Value && | value () const && |
const Value * | get_pointer () const & |
Value * | get_pointer ()& |
Value * | get_pointer ()&&=delete |
FOLLY_CPP14_CONSTEXPR bool | has_value () const noexcept |
FOLLY_CPP14_CONSTEXPR bool | hasValue () const noexcept |
FOLLY_CPP14_CONSTEXPR | operator bool () const noexcept |
FOLLY_CPP14_CONSTEXPR const Value & | operator* () const & |
FOLLY_CPP14_CONSTEXPR Value & | operator* ()& |
FOLLY_CPP14_CONSTEXPR const Value && | operator* () const && |
FOLLY_CPP14_CONSTEXPR Value && | operator* ()&& |
FOLLY_CPP14_CONSTEXPR const Value * | operator-> () const |
FOLLY_CPP14_CONSTEXPR Value * | operator-> () |
template<class U > | |
FOLLY_CPP14_CONSTEXPR Value | value_or (U &&dflt) const & |
template<class U > | |
FOLLY_CPP14_CONSTEXPR Value | value_or (U &&dflt)&& |
Private Types | |
using | Storage = typename std::conditional< std::is_trivially_destructible< Value >::value, StorageTriviallyDestructible, StorageNonTriviallyDestructible >::type |
Private Member Functions | |
template<typename... Args> | |
FOLLY_CPP14_CONSTEXPR | Optional (PrivateConstructor, Args &&...args) noexcept(std::is_constructible< Value, Args &&... >::value) |
void | require_value () const |
template<class... Args> | |
void | construct (Args &&...args) |
Private Attributes | |
Storage | storage_ |
Friends | |
template<class T > | |
constexpr Optional< _t< std::decay< T > > > | make_optional (T &&) |
template<class T , class... Args> | |
constexpr Optional< T > | make_optional (Args &&...args) |
template<class T , class U , class... As> | |
constexpr Optional< T > | make_optional (std::initializer_list< U >, As &&...) |
Definition at line 71 of file Optional.h.
|
private |
Definition at line 429 of file Optional.h.
typedef Value folly::Optional< Value >::value_type |
Definition at line 98 of file Optional.h.
|
inlinenoexcept |
Definition at line 107 of file Optional.h.
|
inlinenoexcept |
Definition at line 109 of file Optional.h.
|
inlinenoexcept |
Definition at line 116 of file Optional.h.
|
inlinenoexcept |
Definition at line 124 of file Optional.h.
|
inlinenoexcept |
Definition at line 126 of file Optional.h.
|
inlinenoexcept |
Definition at line 131 of file Optional.h.
|
inlinenoexcept |
|
inlineexplicitnoexcept |
Definition at line 147 of file Optional.h.
|
inlineexplicitnoexcept |
Definition at line 152 of file Optional.h.
|
inline |
Definition at line 163 of file Optional.h.
|
inlineprivatenoexcept |
Definition at line 367 of file Optional.h.
|
inline |
Definition at line 168 of file Optional.h.
|
inline |
Definition at line 172 of file Optional.h.
|
inline |
Definition at line 183 of file Optional.h.
|
inline |
Definition at line 191 of file Optional.h.
|
inline |
Definition at line 199 of file Optional.h.
|
inlinenoexcept |
Definition at line 251 of file Optional.h.
Referenced by folly::SSLContext::authenticate(), wangle::EvbHandshakeHelper::connectionError(), wangle::EvbHandshakeHelper::connectionReady(), destroy< IOThreadPoolExecutor >(), wangle::EvbHandshakeHelper::dropConnection(), folly::TEST(), TEST(), and TEST_F().
|
inlineprivate |
Definition at line 379 of file Optional.h.
|
inline |
Definition at line 231 of file Optional.h.
Referenced by folly::gen::detail::GroupByAdjacent< Selector >::Generator< Value, Source, ValueDecayed, Key, KeyDecayed >::apply(), folly::dynamicconverter_detail::Dereferencer< T >::derefToCache(), folly::dynamicconverter_detail::Dereferencer< std::pair< F, S > >::derefToCache(), wangle::EvbHandshakeHelper::dropConnection(), folly::makeExpected(), folly::TEST(), TEST(), and TEST_F().
|
inline |
Definition at line 241 of file Optional.h.
|
inline |
Definition at line 288 of file Optional.h.
Referenced by folly::gen::detail::Reduce< Reducer >::compose(), folly::gen::detail::Min< Selector, Comparer >::compose(), folly::get_pointer(), and folly::gen::detail::operator|().
|
inline |
Definition at line 291 of file Optional.h.
|
delete |
|
inlinenoexcept |
Definition at line 296 of file Optional.h.
Referenced by fizz::client::AsyncFizzClientT< SM >::pskResumed(), folly::UnboundedQueue< T, false, 6 >::try_dequeue_for(), folly::UnboundedQueue< T, false, 6 >::try_dequeue_until(), and TYPED_TEST().
|
inlinenoexcept |
Definition at line 300 of file Optional.h.
Referenced by folly::gen::detail::GroupByAdjacent< Selector >::Generator< Value, Source, ValueDecayed, Key, KeyDecayed >::apply(), folly::Optional< NamedGroup >::assign(), wangle::EvbHandshakeHelper::connectionError(), wangle::EvbHandshakeHelper::connectionReady(), fizz::FizzUtil::createTicketCipher(), folly::FileWriterFactory::createWriter(), folly::io::StreamCodec::doUncompress(), fizz::sm::getCertificateRequest(), folly::AsyncUDPSocket::getGSO(), fizz::sm::getHrrKeyExchangers(), folly::bser::getTemplate(), proxygen::HTTPException::hasCodecStatusCode(), folly::logConfigToDynamic(), folly::LogHandlerConfig::LogHandlerConfig(), proxygen::HTTPServerAcceptor::makeConfig(), fizz::sm::negotiatePsk(), proxygen::HTTP1xCodec::onHeadersComplete(), proxygen::HTTPTransaction::onIngressBody(), proxygen::HTTPTransaction::onIngressEOM(), BlockingSocket::open(), hash< folly::Optional< T > >::operator()(), folly::operator<(), folly::operator<<(), folly::operator==(), folly::operator>(), AsyncSocketIntegrationTest::performPingPongTest(), BlockingSocket::readHelper(), folly::LoggerDB::startConfigUpdate(), folly::TEST(), TEST(), TYPED_TEST(), folly::LogHandlerConfig::update(), fizz::extensions::test::TokenBindingServerExtensionTest::verifyExtensionFields(), and BlockingSocket::write().
|
inlineexplicitnoexcept |
Definition at line 304 of file Optional.h.
|
inline |
Definition at line 308 of file Optional.h.
|
inline |
Definition at line 311 of file Optional.h.
|
inline |
Definition at line 314 of file Optional.h.
|
inline |
Definition at line 317 of file Optional.h.
|
inline |
Definition at line 321 of file Optional.h.
|
inline |
Definition at line 324 of file Optional.h.
|
inlinenoexcept |
Definition at line 207 of file Optional.h.
|
inline |
Definition at line 213 of file Optional.h.
|
inlinenoexcept |
Definition at line 218 of file Optional.h.
|
inlinenoexcept |
Definition at line 224 of file Optional.h.
|
inlineprivate |
Definition at line 372 of file Optional.h.
|
inlinenoexcept |
|
inlinenoexcept |
Definition at line 255 of file Optional.h.
|
inline |
Definition at line 268 of file Optional.h.
Referenced by folly::gen::detail::GroupByAdjacent< Selector >::Generator< Value, Source, ValueDecayed, Key, KeyDecayed >::apply(), folly::Optional< NamedGroup >::assign(), BENCHMARK(), BENCHMARK_RELATIVE(), folly::FileWriterFactory::createWriter(), folly::dynamicconverter_detail::Transformer< T, It >::dereference(), proxygen::HTTPDefaultSessionCodecFactory::getCodec(), folly::AsyncUDPSocket::getGSO(), folly::bser::getTemplate(), folly::logConfigToDynamic(), proxygen::HTTPServerAcceptor::makeConfig(), proxygen::HTTP1xCodec::onHeadersComplete(), proxygen::HTTPTransaction::onIngressBody(), proxygen::HTTPTransaction::onIngressEOM(), BlockingSocket::open(), folly::operator<(), folly::operator<<(), folly::operator==(), folly::gen::detail::operator|(), BlockingSocket::readHelper(), proxygen::HTTPTransaction::sendBody(), folly::LoggerDB::startConfigUpdate(), TEST(), folly::TEST(), TEST_F(), TYPED_TEST(), and BlockingSocket::write().
|
inline |
Definition at line 273 of file Optional.h.
|
inline |
Definition at line 278 of file Optional.h.
|
inline |
Definition at line 283 of file Optional.h.
|
inline |
Definition at line 330 of file Optional.h.
Referenced by folly::EventBase::checkIsInEventBaseThread(), ConnectionFilterTest::createDefaultOpts(), fizz::PeerCertImpl< T >::getIdentity(), folly::io::Codec::getUncompressedLength(), fizz::sm::handleCertMsg(), TestHandlerFactory::TestHandler::onEOM(), proxygen::Mock1867Callback::onFieldStart(), folly::TEST(), and folly::io::Codec::uncompress().
|
inline |
Definition at line 339 of file Optional.h.
|
friend |
Definition at line 450 of file Optional.h.
|
friend |
Definition at line 457 of file Optional.h.
|
friend |
|
private |
Definition at line 431 of file Optional.h.