Retrieve associated CelValue. If the value is not set and producer is set, obtain and cache value from producer.
| 113 | // If the value is not set and producer is set, |
| 114 | // obtain and cache value from producer. |
| 115 | absl::optional<CelValue> RetrieveValue(google::protobuf::Arena* arena) const { |
| 116 | if (!value_.has_value()) { |
| 117 | if (producer_) { |
| 118 | value_ = producer_->Produce(arena); |
| 119 | } |
| 120 | } |
| 121 | |
| 122 | return value_; |
| 123 | } |
| 124 | |
| 125 | bool ClearValue() { |
| 126 | bool result = value_.has_value(); |