template <typename T>
class DefaultValue
Defined at line 653 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-actions.h
This partial specialization allows a user to set default values for
reference types.
Public Methods
void Set (T & x)
Sets the default value for type T
&
.
Defined at line 657 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-actions.h
void Clear ()
Unsets the default value for type T
&
.
Defined at line 662 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-actions.h
bool IsSet ()
Returns true if and only if the user has set the default value for type T
&
.
Defined at line 665 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-actions.h
bool Exists ()
Returns true if T has a default return value set by the user or there
exists a built-in default value.
Defined at line 669 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-actions.h
T & Get ()
Returns the default value for type T
&
if the user has set one;
otherwise returns the built-in default value if there is one;
otherwise aborts the process.
Defined at line 676 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-actions.h