| 151 | } |
| 152 | |
| 153 | absl::Status ParsedJsonListValue::Equal( |
| 154 | const Value& other, |
| 155 | const google::protobuf::DescriptorPool* absl_nonnull descriptor_pool, |
| 156 | google::protobuf::MessageFactory* absl_nonnull message_factory, |
| 157 | google::protobuf::Arena* absl_nonnull arena, Value* absl_nonnull result) const { |
| 158 | ABSL_DCHECK(descriptor_pool != nullptr); |
| 159 | ABSL_DCHECK(message_factory != nullptr); |
| 160 | ABSL_DCHECK(arena != nullptr); |
| 161 | ABSL_DCHECK(result != nullptr); |
| 162 | |
| 163 | if (auto other_value = other.AsParsedJsonList(); other_value) { |
| 164 | *result = BoolValue(*this == *other_value); |
| 165 | return absl::OkStatus(); |
| 166 | } |
| 167 | if (auto other_value = other.AsParsedRepeatedField(); other_value) { |
| 168 | if (value_ == nullptr) { |
| 169 | *result = BoolValue(other_value->IsEmpty()); |
| 170 | return absl::OkStatus(); |
| 171 | } |
| 172 | CEL_ASSIGN_OR_RETURN( |
| 173 | auto equal, internal::MessageFieldEquals( |
| 174 | *value_, *other_value->message_, other_value->field_, |
| 175 | descriptor_pool, message_factory)); |
| 176 | *result = BoolValue(equal); |
| 177 | return absl::OkStatus(); |
| 178 | } |
| 179 | if (auto other_value = other.AsList(); other_value) { |
| 180 | return common_internal::ListValueEqual(ListValue(*this), *other_value, |
| 181 | descriptor_pool, message_factory, |
| 182 | arena, result); |
| 183 | } |
| 184 | *result = BoolValue(false); |
| 185 | return absl::OkStatus(); |
| 186 | } |
| 187 | |
| 188 | ParsedJsonListValue ParsedJsonListValue::Clone( |
| 189 | google::protobuf::Arena* absl_nonnull arena) const { |
no test coverage detected