proxygen
CheckedInt Struct Reference

Public Member Functions

 CheckedInt ()
 
 CheckedInt (int value_)
 
 CheckedInt (const CheckedInt &rhs, int)
 
 CheckedInt (const CheckedInt &rhs)
 
 CheckedInt (CheckedInt &&rhs) noexcept
 
CheckedIntoperator= (const CheckedInt &rhs)
 
CheckedIntoperator= (CheckedInt &&rhs) noexcept
 
 ~CheckedInt ()
 

Public Attributes

int value
 

Static Public Attributes

static const int DEFAULT_VALUE = (int)0xdeadbeef
 

Detailed Description

Definition at line 789 of file small_vector_test.cpp.

Constructor & Destructor Documentation

CheckedInt::CheckedInt ( )
inline

Definition at line 791 of file small_vector_test.cpp.

791 : value(DEFAULT_VALUE) {}
static const int DEFAULT_VALUE
CheckedInt::CheckedInt ( int  value_)
inlineexplicit

Definition at line 792 of file small_vector_test.cpp.

792 : value(value_) {}
CheckedInt::CheckedInt ( const CheckedInt rhs,
int   
)
inline

Definition at line 793 of file small_vector_test.cpp.

793 : value(rhs.value) {}
CheckedInt::CheckedInt ( const CheckedInt rhs)
inline

Definition at line 794 of file small_vector_test.cpp.

794 : value(rhs.value) {}
CheckedInt::CheckedInt ( CheckedInt &&  rhs)
inlinenoexcept

Definition at line 795 of file small_vector_test.cpp.

References folly::detail::rhs.

795  : value(rhs.value) {
796  rhs.value = DEFAULT_VALUE;
797  }
static const int DEFAULT_VALUE
CheckedInt::~CheckedInt ( )
inline

Definition at line 807 of file small_vector_test.cpp.

807 {}

Member Function Documentation

CheckedInt& CheckedInt::operator= ( const CheckedInt rhs)
inline

Definition at line 798 of file small_vector_test.cpp.

References folly::value(), and value.

798  {
799  value = rhs.value;
800  return *this;
801  }
CheckedInt& CheckedInt::operator= ( CheckedInt &&  rhs)
inlinenoexcept

Definition at line 802 of file small_vector_test.cpp.

References folly::detail::rhs, and folly::value().

802  {
803  value = rhs.value;
804  rhs.value = DEFAULT_VALUE;
805  return *this;
806  }
static const int DEFAULT_VALUE

Member Data Documentation

const int CheckedInt::DEFAULT_VALUE = (int)0xdeadbeef
static

Definition at line 790 of file small_vector_test.cpp.

int CheckedInt::value

Definition at line 808 of file small_vector_test.cpp.

Referenced by operator=(), and TEST().


The documentation for this struct was generated from the following file: