| 1748 | } |
| 1749 | |
| 1750 | absl::Status AddLibrary(cel::ParserLibrary library) override { |
| 1751 | if (!library.id.empty()) { |
| 1752 | auto [it, inserted] = library_ids_.insert(library.id); |
| 1753 | if (!inserted) { |
| 1754 | return absl::AlreadyExistsError( |
| 1755 | absl::StrCat("parser library already exists: ", library.id)); |
| 1756 | } |
| 1757 | } |
| 1758 | libraries_.push_back(std::move(library)); |
| 1759 | return absl::OkStatus(); |
| 1760 | } |
| 1761 | |
| 1762 | absl::Status AddLibrarySubset(cel::ParserLibrarySubset subset) override { |
| 1763 | if (subset.library_id.empty()) { |