Lines Matching refs:T
29 template <typename T>
39 static CmdlineParseResult<T> Failure() { in Failure()
44 static CmdlineParseResult<T> Failure(const std::string& message) { in Failure()
49 static CmdlineParseResult<T> Success(const T& value) { in Success()
54 static CmdlineParseResult<T> Success(T&& value) { in Success()
55 return CmdlineParseResult(std::forward<T>(value)); in Success()
60 static CmdlineParseResult<T> SuccessNoValue() { in SuccessNoValue()
61 return CmdlineParseResult(T {}); in SuccessNoValue()
65 static CmdlineParseResult<T> OutOfRange(const std::string& message) { in OutOfRange()
72 static CmdlineParseResult<T> OutOfRange(const T& value, in OutOfRange()
73 const T& min, in OutOfRange()
74 const T& max) { in OutOfRange()
83 const T& GetValue() const { in GetValue()
91 T& GetValue() { in GetValue()
99 T&& ReleaseValue() { in ReleaseValue()
114 static CmdlineParseResult<T> CastError(const CmdlineParseResult<T2>& other) { in CastError()
116 return CmdlineParseResult<T>(other.GetStatus()); in CastError()
125 explicit CmdlineParseResult(const T& value) in CmdlineParseResult()
127 explicit CmdlineParseResult(T&& value) in CmdlineParseResult()
128 : CmdlineResult(kSuccess), value_(std::forward<T>(value)), has_value_(true) {} in CmdlineParseResult()
132 T value_;