From 1da984b6d9b153f7af00ad9e7925710b5cb828d4 Mon Sep 17 00:00:00 2001 From: cloud-java-bot Date: Tue, 2 Jun 2026 14:25:07 +0000 Subject: [PATCH 1/6] feat: [backstory] new module for backstory --- generation_config.yaml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/generation_config.yaml b/generation_config.yaml index 59a63830c4d5..099df1c87216 100644 --- a/generation_config.yaml +++ b/generation_config.yaml @@ -284,6 +284,21 @@ libraries: GAPICs: - proto_path: google/cloud/automl/v1 - proto_path: google/cloud/automl/v1beta1 +- api_shortname: backstory + name_pretty: Malachite Common Protos + product_documentation: https://cloud.google.com/chronicle/docs/secops/secops-overview + api_description: Common Universal Data Model (UDM) and Entity protos used by Chronicle. + client_documentation: + https://cloud.google.com/java/docs/reference/google-cloud-backstory/latest/overview + release_level: preview + distribution_name: com.google.cloud:google-cloud-backstory + api_id: backstory.googleapis.com + library_type: GAPIC_AUTO + group_id: com.google.cloud + cloud_api: true + GAPICs: + - proto_path: backstory + requires_billing: true - api_shortname: backupdr name_pretty: Backup and DR Service API product_documentation: https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-dr From 120310eb6d2410eefd49cfd257890e0f3759838d Mon Sep 17 00:00:00 2001 From: cloud-java-bot Date: Tue, 2 Jun 2026 21:02:24 +0000 Subject: [PATCH 2/6] chore: generate libraries at Tue Jun 2 21:00:23 UTC 2026 --- gapic-libraries-bom/pom.xml | 7 + java-backstory/.OwlBot-hermetic.yaml | 35 + java-backstory/.repo-metadata.json | 16 + java-backstory/README.md | 205 + .../google-cloud-backstory-bom/pom.xml | 33 + java-backstory/google-cloud-backstory/pom.xml | 106 + java-backstory/owlbot.py | 37 + java-backstory/pom.xml | 43 + .../google/backstory/AnalyticsMetadata.java | 576 + .../backstory/AnalyticsMetadataOrBuilder.java | 39 + .../google/backstory/AppCompatMetadata.java | 781 + .../backstory/AppCompatMetadataOrBuilder.java | 68 + .../java/com/google/backstory/Artifact.java | 5157 +++ .../com/google/backstory/ArtifactClient.java | 965 + .../backstory/ArtifactClientOrBuilder.java | 121 + .../google/backstory/ArtifactOrBuilder.java | 671 + .../main/java/com/google/backstory/Asset.java | 8117 ++++ .../com/google/backstory/AssetOrBuilder.java | 1005 + .../google/backstory/AtiPrioritization.java | 3128 ++ .../backstory/AtiPrioritizationOrBuilder.java | 349 + .../com/google/backstory/AttackDetails.java | 3672 ++ .../backstory/AttackDetailsOrBuilder.java | 151 + .../java/com/google/backstory/Attribute.java | 2856 ++ .../google/backstory/AttributeOrBuilder.java | 312 + .../com/google/backstory/Authentication.java | 2523 ++ .../backstory/AuthenticationOrBuilder.java | 158 + .../com/google/backstory/BoolSequence.java | 641 + .../backstory/BoolSequenceOrBuilder.java | 53 + .../java/com/google/backstory/Browser.java | 6970 +++ .../google/backstory/BrowserOrBuilder.java | 444 + .../com/google/backstory/BytesSequence.java | 621 + .../backstory/BytesSequenceOrBuilder.java | 53 + .../com/google/backstory/Certificate.java | 2263 + .../backstory/CertificateOrBuilder.java | 269 + .../main/java/com/google/backstory/Cloud.java | 1537 + .../com/google/backstory/CloudOrBuilder.java | 157 + .../java/com/google/backstory/Collection.java | 6904 +++ .../google/backstory/CollectionOrBuilder.java | 871 + .../backstory/CollectionOuterClass.java | 285 + .../java/com/google/backstory/DNSRecord.java | 2337 + .../google/backstory/DNSRecordOrBuilder.java | 278 + .../java/com/google/backstory/DataAccess.java | 86 + .../backstory/DataAccessIngestionLabel.java | 769 + .../DataAccessIngestionLabelOrBuilder.java | 65 + .../google/backstory/DataAccessLabels.java | 2213 + .../backstory/DataAccessLabelsOrBuilder.java | 310 + .../google/backstory/DataTableRowInfo.java | 1063 + .../backstory/DataTableRowInfoOrBuilder.java | 105 + .../main/java/com/google/backstory/Dhcp.java | 5013 +++ .../com/google/backstory/DhcpOrBuilder.java | 488 + .../main/java/com/google/backstory/Dns.java | 5681 +++ .../com/google/backstory/DnsOrBuilder.java | 351 + .../java/com/google/backstory/Domain.java | 8608 ++++ .../com/google/backstory/DomainOrBuilder.java | 1139 + .../com/google/backstory/DoubleSequence.java | 642 + .../backstory/DoubleSequenceOrBuilder.java | 53 + .../java/com/google/backstory/Element.java | 1944 + .../google/backstory/ElementOrBuilder.java | 228 + .../main/java/com/google/backstory/Email.java | 2304 + .../com/google/backstory/EmailOrBuilder.java | 335 + .../java/com/google/backstory/Entity.java | 2332 + .../backstory/EntityGraphEnrichment.java | 1220 + .../EntityGraphEnrichmentOrBuilder.java | 105 + .../com/google/backstory/EntityMetadata.java | 5501 +++ .../backstory/EntityMetadataOrBuilder.java | 617 + .../com/google/backstory/EntityOrBuilder.java | 264 + .../com/google/backstory/EntityProto.java | 382 + .../java/com/google/backstory/EntityRisk.java | 3335 ++ .../google/backstory/EntityRiskOrBuilder.java | 417 + .../com/google/backstory/EntityRiskProto.java | 119 + .../java/com/google/backstory/ExifInfo.java | 1527 + .../google/backstory/ExifInfoOrBuilder.java | 167 + .../java/com/google/backstory/Extensions.java | 3279 ++ .../google/backstory/ExtensionsOrBuilder.java | 410 + .../java/com/google/backstory/Favicon.java | 759 + .../google/backstory/FaviconOrBuilder.java | 65 + .../main/java/com/google/backstory/File.java | 14479 +++++++ .../com/google/backstory/FileMetadata.java | 699 + .../backstory/FileMetadataCodesign.java | 1251 + .../FileMetadataCodesignOrBuilder.java | 128 + .../google/backstory/FileMetadataImports.java | 868 + .../FileMetadataImportsOrBuilder.java | 93 + .../backstory/FileMetadataOrBuilder.java | 58 + .../com/google/backstory/FileMetadataPE.java | 5488 +++ .../backstory/FileMetadataPEOrBuilder.java | 621 + .../backstory/FileMetadataPeResourceInfo.java | 1270 + .../FileMetadataPeResourceInfoOrBuilder.java | 136 + .../google/backstory/FileMetadataSection.java | 1062 + .../FileMetadataSectionOrBuilder.java | 104 + .../backstory/FileMetadataSignatureInfo.java | 2078 + .../FileMetadataSignatureInfoOrBuilder.java | 242 + .../com/google/backstory/FileOrBuilder.java | 1432 + .../com/google/backstory/FindingVariable.java | 4413 ++ .../backstory/FindingVariableOrBuilder.java | 552 + .../main/java/com/google/backstory/Ftp.java | 570 + .../com/google/backstory/FtpOrBuilder.java | 39 + .../main/java/com/google/backstory/Group.java | 1856 + .../com/google/backstory/GroupOrBuilder.java | 232 + .../com/google/backstory/GroupedFields.java | 2707 ++ .../backstory/GroupedFieldsOrBuilder.java | 445 + .../java/com/google/backstory/Hardware.java | 1723 + .../google/backstory/HardwareOrBuilder.java | 197 + .../main/java/com/google/backstory/Http.java | 1074 + .../com/google/backstory/HttpOrBuilder.java | 111 + .../main/java/com/google/backstory/Id.java | 1155 + .../com/google/backstory/IdOrBuilder.java | 82 + .../com/google/backstory/IdOuterClass.java | 68 + .../com/google/backstory/Int64Sequence.java | 637 + .../backstory/Int64SequenceOrBuilder.java | 53 + .../com/google/backstory/Investigation.java | 2360 + .../backstory/InvestigationOrBuilder.java | 392 + .../main/java/com/google/backstory/Label.java | 1045 + .../com/google/backstory/LabelOrBuilder.java | 104 + .../com/google/backstory/LatencyMetrics.java | 1864 + .../backstory/LatencyMetricsOrBuilder.java | 210 + .../java/com/google/backstory/LinuxUtmp.java | 868 + .../google/backstory/LinuxUtmpOrBuilder.java | 39 + .../java/com/google/backstory/Location.java | 2090 + .../google/backstory/LocationOrBuilder.java | 255 + .../java/com/google/backstory/Metadata.java | 10224 +++++ .../google/backstory/MetadataOrBuilder.java | 764 + .../java/com/google/backstory/Metric.java | 6430 +++ .../com/google/backstory/MetricOrBuilder.java | 423 + .../java/com/google/backstory/Network.java | 8920 ++++ .../google/backstory/NetworkOrBuilder.java | 787 + .../main/java/com/google/backstory/Noun.java | 12147 ++++++ .../com/google/backstory/NounOrBuilder.java | 1569 + .../google/backstory/NtfsFileMetadata.java | 2323 + .../backstory/NtfsFileMetadataOrBuilder.java | 253 + .../com/google/backstory/OutlookMetadata.java | 1053 + .../backstory/OutlookMetadataOrBuilder.java | 105 + .../java/com/google/backstory/PDFInfo.java | 2621 ++ .../google/backstory/PDFInfoOrBuilder.java | 315 + .../com/google/backstory/PeFileMetadata.java | 574 + .../backstory/PeFileMetadataOrBuilder.java | 39 + .../java/com/google/backstory/Permission.java | 1131 + .../google/backstory/PermissionOrBuilder.java | 91 + .../google/backstory/PlatformSoftware.java | 933 + .../backstory/PlatformSoftwareOrBuilder.java | 95 + .../com/google/backstory/PopularityRank.java | 966 + .../backstory/PopularityRankOrBuilder.java | 89 + .../backstory/PrefetchFileMetadata.java | 677 + .../PrefetchFileMetadataOrBuilder.java | 52 + .../java/com/google/backstory/Prevalence.java | 883 + .../google/backstory/PrevalenceOrBuilder.java | 82 + .../java/com/google/backstory/Priority.java | 245 + .../java/com/google/backstory/Process.java | 5685 +++ .../google/backstory/ProcessOrBuilder.java | 678 + .../java/com/google/backstory/ProxyInfo.java | 1540 + .../google/backstory/ProxyInfoOrBuilder.java | 169 + .../java/com/google/backstory/Reason.java | 199 + .../java/com/google/backstory/Reference.java | 2332 + .../google/backstory/ReferenceOrBuilder.java | 274 + .../java/com/google/backstory/Registry.java | 1639 + .../google/backstory/RegistryOrBuilder.java | 138 + .../java/com/google/backstory/Relation.java | 2122 + .../google/backstory/RelationOrBuilder.java | 169 + .../java/com/google/backstory/Reputation.java | 176 + .../java/com/google/backstory/Resource.java | 4723 ++ .../google/backstory/ResourceOrBuilder.java | 491 + .../com/google/backstory/ResourceUsage.java | 763 + .../backstory/ResourceUsageOrBuilder.java | 65 + .../backstory/ResponsePlatformInfo.java | 905 + .../ResponsePlatformInfoOrBuilder.java | 67 + .../java/com/google/backstory/RiskDelta.java | 972 + .../google/backstory/RiskDeltaOrBuilder.java | 89 + .../main/java/com/google/backstory/Role.java | 1081 + .../com/google/backstory/RoleOrBuilder.java | 91 + .../com/google/backstory/SSLCertificate.java | 14209 ++++++ .../backstory/SSLCertificateOrBuilder.java | 496 + .../backstory/ScheduledAnacronTask.java | 1251 + .../ScheduledAnacronTaskOrBuilder.java | 132 + .../google/backstory/ScheduledCronTask.java | 2172 + .../backstory/ScheduledCronTaskOrBuilder.java | 271 + .../com/google/backstory/ScheduledTask.java | 1253 + .../backstory/ScheduledTaskOrBuilder.java | 131 + .../com/google/backstory/SecurityResult.java | 36035 ++++++++++++++++ .../backstory/SecurityResultOrBuilder.java | 1945 + .../java/com/google/backstory/Service.java | 2250 + .../google/backstory/ServiceOrBuilder.java | 190 + .../com/google/backstory/SignatureInfo.java | 958 + .../backstory/SignatureInfoOrBuilder.java | 87 + .../java/com/google/backstory/SignerInfo.java | 1333 + .../google/backstory/SignerInfoOrBuilder.java | 184 + .../main/java/com/google/backstory/Smtp.java | 1722 + .../com/google/backstory/SmtpOrBuilder.java | 225 + .../google/backstory/SoarAlertMetadata.java | 1713 + .../backstory/SoarAlertMetadataOrBuilder.java | 195 + .../java/com/google/backstory/Software.java | 1672 + .../google/backstory/SoftwareOrBuilder.java | 177 + .../main/java/com/google/backstory/Srum.java | 1482 + .../com/google/backstory/SrumOrBuilder.java | 167 + .../java/com/google/backstory/Status.java | 222 + .../com/google/backstory/StringSequence.java | 675 + .../backstory/StringSequenceOrBuilder.java | 67 + .../backstory/StringToInt64MapEntry.java | 739 + .../StringToInt64MapEntryOrBuilder.java | 78 + .../google/backstory/SystemEventDetails.java | 956 + .../SystemEventDetailsOrBuilder.java | 91 + .../main/java/com/google/backstory/Tags.java | 911 + .../com/google/backstory/TagsOrBuilder.java | 107 + .../com/google/backstory/ThreatVerdict.java | 199 + .../java/com/google/backstory/TimeOff.java | 856 + .../google/backstory/TimeOffOrBuilder.java | 76 + .../main/java/com/google/backstory/Tls.java | 4928 +++ .../com/google/backstory/TlsOrBuilder.java | 244 + .../java/com/google/backstory/Tracker.java | 1232 + .../google/backstory/TrackerOrBuilder.java | 128 + .../java/com/google/backstory/Tunnels.java | 759 + .../google/backstory/TunnelsOrBuilder.java | 65 + .../main/java/com/google/backstory/UDM.java | 5168 +++ .../com/google/backstory/UDMOrBuilder.java | 668 + .../main/java/com/google/backstory/Udm.java | 4280 ++ .../com/google/backstory/Uint64Sequence.java | 637 + .../backstory/Uint64SequenceOrBuilder.java | 53 + .../main/java/com/google/backstory/Url.java | 3555 ++ .../com/google/backstory/UrlOrBuilder.java | 454 + .../main/java/com/google/backstory/User.java | 9529 ++++ .../java/com/google/backstory/UserAssist.java | 980 + .../google/backstory/UserAssistOrBuilder.java | 91 + .../com/google/backstory/UserOrBuilder.java | 1261 + .../java/com/google/backstory/UsnJournal.java | 3161 ++ .../google/backstory/UsnJournalOrBuilder.java | 259 + .../java/com/google/backstory/Verdict.java | 177 + .../java/com/google/backstory/Volume.java | 1331 + .../com/google/backstory/VolumeOrBuilder.java | 143 + .../com/google/backstory/Vulnerabilities.java | 905 + .../backstory/VulnerabilitiesOrBuilder.java | 69 + .../com/google/backstory/Vulnerability.java | 4298 ++ .../backstory/VulnerabilityOrBuilder.java | 539 + .../com/google/backstory/WindowsEventLog.java | 1188 + .../backstory/WindowsEventLogOrBuilder.java | 93 + .../backstory/WindowsScheduledTask.java | 6266 +++ .../WindowsScheduledTaskOrBuilder.java | 243 + .../google/backstory/WmiPersistenceItem.java | 2102 + .../WmiPersistenceItemOrBuilder.java | 249 + .../main/java/com/google/backstory/X509.java | 1326 + .../com/google/backstory/X509OrBuilder.java | 143 + .../src/main/proto/backstory/collection.proto | 371 + .../main/proto/backstory/data_access.proto | 54 + .../src/main/proto/backstory/entity.proto | 629 + .../main/proto/backstory/entity_risk.proto | 104 + .../src/main/proto/backstory/id.proto | 72 + .../src/main/proto/backstory/udm.proto | 6605 +++ pom.xml | 1 + versions.txt | 1 + 246 files changed, 379607 insertions(+) create mode 100644 java-backstory/.OwlBot-hermetic.yaml create mode 100644 java-backstory/.repo-metadata.json create mode 100644 java-backstory/README.md create mode 100644 java-backstory/google-cloud-backstory-bom/pom.xml create mode 100644 java-backstory/google-cloud-backstory/pom.xml create mode 100644 java-backstory/owlbot.py create mode 100644 java-backstory/pom.xml create mode 100644 java-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Artifact.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ArtifactClient.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Asset.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AtiPrioritization.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AttackDetails.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Attribute.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Authentication.java create mode 100644 java-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/BoolSequence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Browser.java create mode 100644 java-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/BytesSequence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Certificate.java create mode 100644 java-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Cloud.java create mode 100644 java-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Collection.java create mode 100644 java-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DNSRecord.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataAccess.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataAccessLabels.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Dhcp.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DhcpOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Dns.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DnsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Domain.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DomainOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DoubleSequence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/DoubleSequenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Element.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ElementOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Email.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EmailOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Entity.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityGraphEnrichment.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityGraphEnrichmentOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityProto.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityRisk.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityRiskOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/EntityRiskProto.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ExifInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ExifInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Extensions.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ExtensionsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Favicon.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FaviconOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/File.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataCodesign.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataCodesignOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataImports.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataImportsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataPE.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataPEOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataSection.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataSectionOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FileOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FindingVariable.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FindingVariableOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Ftp.java create mode 100644 java-backstory/src/main/java/com/google/backstory/FtpOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Group.java create mode 100644 java-backstory/src/main/java/com/google/backstory/GroupOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/GroupedFields.java create mode 100644 java-backstory/src/main/java/com/google/backstory/GroupedFieldsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Hardware.java create mode 100644 java-backstory/src/main/java/com/google/backstory/HardwareOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Http.java create mode 100644 java-backstory/src/main/java/com/google/backstory/HttpOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Id.java create mode 100644 java-backstory/src/main/java/com/google/backstory/IdOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/IdOuterClass.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Int64Sequence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Int64SequenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Investigation.java create mode 100644 java-backstory/src/main/java/com/google/backstory/InvestigationOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Label.java create mode 100644 java-backstory/src/main/java/com/google/backstory/LabelOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/LatencyMetrics.java create mode 100644 java-backstory/src/main/java/com/google/backstory/LatencyMetricsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/LinuxUtmp.java create mode 100644 java-backstory/src/main/java/com/google/backstory/LinuxUtmpOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Location.java create mode 100644 java-backstory/src/main/java/com/google/backstory/LocationOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Metadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/MetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Metric.java create mode 100644 java-backstory/src/main/java/com/google/backstory/MetricOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Network.java create mode 100644 java-backstory/src/main/java/com/google/backstory/NetworkOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Noun.java create mode 100644 java-backstory/src/main/java/com/google/backstory/NounOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/NtfsFileMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/NtfsFileMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/OutlookMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/OutlookMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PDFInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PDFInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PeFileMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PeFileMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Permission.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PermissionOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PlatformSoftware.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PlatformSoftwareOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PopularityRank.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PopularityRankOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PrefetchFileMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PrefetchFileMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Prevalence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/PrevalenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Priority.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Process.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ProcessOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ProxyInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ProxyInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Reason.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Reference.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ReferenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Registry.java create mode 100644 java-backstory/src/main/java/com/google/backstory/RegistryOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Relation.java create mode 100644 java-backstory/src/main/java/com/google/backstory/RelationOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Reputation.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Resource.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ResourceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ResourceUsage.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ResourceUsageOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ResponsePlatformInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ResponsePlatformInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/RiskDelta.java create mode 100644 java-backstory/src/main/java/com/google/backstory/RiskDeltaOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Role.java create mode 100644 java-backstory/src/main/java/com/google/backstory/RoleOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SSLCertificate.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SSLCertificateOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ScheduledAnacronTask.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ScheduledAnacronTaskOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ScheduledCronTask.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ScheduledCronTaskOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ScheduledTask.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ScheduledTaskOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SecurityResult.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SecurityResultOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Service.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ServiceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SignatureInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SignatureInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SignerInfo.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SignerInfoOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Smtp.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SmtpOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SoarAlertMetadata.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SoarAlertMetadataOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Software.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SoftwareOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Srum.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SrumOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Status.java create mode 100644 java-backstory/src/main/java/com/google/backstory/StringSequence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/StringSequenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/StringToInt64MapEntry.java create mode 100644 java-backstory/src/main/java/com/google/backstory/StringToInt64MapEntryOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SystemEventDetails.java create mode 100644 java-backstory/src/main/java/com/google/backstory/SystemEventDetailsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Tags.java create mode 100644 java-backstory/src/main/java/com/google/backstory/TagsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/ThreatVerdict.java create mode 100644 java-backstory/src/main/java/com/google/backstory/TimeOff.java create mode 100644 java-backstory/src/main/java/com/google/backstory/TimeOffOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Tls.java create mode 100644 java-backstory/src/main/java/com/google/backstory/TlsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Tracker.java create mode 100644 java-backstory/src/main/java/com/google/backstory/TrackerOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Tunnels.java create mode 100644 java-backstory/src/main/java/com/google/backstory/TunnelsOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UDM.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UDMOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Udm.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Uint64Sequence.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Uint64SequenceOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Url.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UrlOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/User.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UserAssist.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UserAssistOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UserOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UsnJournal.java create mode 100644 java-backstory/src/main/java/com/google/backstory/UsnJournalOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Verdict.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Volume.java create mode 100644 java-backstory/src/main/java/com/google/backstory/VolumeOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Vulnerabilities.java create mode 100644 java-backstory/src/main/java/com/google/backstory/VulnerabilitiesOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/Vulnerability.java create mode 100644 java-backstory/src/main/java/com/google/backstory/VulnerabilityOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/WindowsEventLog.java create mode 100644 java-backstory/src/main/java/com/google/backstory/WindowsEventLogOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/WindowsScheduledTask.java create mode 100644 java-backstory/src/main/java/com/google/backstory/WindowsScheduledTaskOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/WmiPersistenceItem.java create mode 100644 java-backstory/src/main/java/com/google/backstory/WmiPersistenceItemOrBuilder.java create mode 100644 java-backstory/src/main/java/com/google/backstory/X509.java create mode 100644 java-backstory/src/main/java/com/google/backstory/X509OrBuilder.java create mode 100644 java-backstory/src/main/proto/backstory/collection.proto create mode 100644 java-backstory/src/main/proto/backstory/data_access.proto create mode 100644 java-backstory/src/main/proto/backstory/entity.proto create mode 100644 java-backstory/src/main/proto/backstory/entity_risk.proto create mode 100644 java-backstory/src/main/proto/backstory/id.proto create mode 100644 java-backstory/src/main/proto/backstory/udm.proto diff --git a/gapic-libraries-bom/pom.xml b/gapic-libraries-bom/pom.xml index 96cdd4e69c92..7ca86b62b0f1 100644 --- a/gapic-libraries-bom/pom.xml +++ b/gapic-libraries-bom/pom.xml @@ -175,6 +175,13 @@ pom import + + com.google.cloud + google-cloud-backstory-bom + 0.0.1-SNAPSHOT + pom + import + com.google.cloud google-cloud-backupdr-bom diff --git a/java-backstory/.OwlBot-hermetic.yaml b/java-backstory/.OwlBot-hermetic.yaml new file mode 100644 index 000000000000..0f5259ed6710 --- /dev/null +++ b/java-backstory/.OwlBot-hermetic.yaml @@ -0,0 +1,35 @@ +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + + +deep-remove-regex: +- "/java-backstory/grpc-google-.*/src" +- "/java-backstory/proto-google-.*/src" +- "/java-backstory/google-.*/src" +- "/java-backstory/samples/snippets/generated" + +deep-preserve-regex: +- "/java-backstory/google-.*/src/test/java/com/google/cloud/.*/v.*/it/IT.*Test.java" + +deep-copy-regex: +- source: "/backstory/.*-java/proto-google-.*/src" + dest: "/owl-bot-staging/java-backstory/proto-google-cloud-backstory/src" +- source: "/backstory/.*-java/grpc-google-.*/src" + dest: "/owl-bot-staging/java-backstory/grpc-google-cloud-backstory/src" +- source: "/backstory/.*-java/gapic-google-.*/src" + dest: "/owl-bot-staging/java-backstory/google-cloud-backstory/src" +- source: "/backstory/.*-java/samples/snippets/generated" + dest: "/owl-bot-staging/java-backstory/samples/snippets/generated" + +api-name: backstory \ No newline at end of file diff --git a/java-backstory/.repo-metadata.json b/java-backstory/.repo-metadata.json new file mode 100644 index 000000000000..bd0684045421 --- /dev/null +++ b/java-backstory/.repo-metadata.json @@ -0,0 +1,16 @@ +{ + "api_shortname": "backstory", + "name_pretty": "Malachite Common Protos", + "product_documentation": "https://cloud.google.com/chronicle/docs/secops/secops-overview", + "api_description": "Common Universal Data Model (UDM) and Entity protos used by Chronicle.", + "client_documentation": "https://cloud.google.com/java/docs/reference/google-cloud-backstory/latest/overview", + "release_level": "preview", + "transport": "grpc", + "language": "java", + "repo": "googleapis/google-cloud-java", + "repo_short": "java-backstory", + "distribution_name": "com.google.cloud:google-cloud-backstory", + "api_id": "backstory.googleapis.com", + "library_type": "GAPIC_AUTO", + "requires_billing": true +} \ No newline at end of file diff --git a/java-backstory/README.md b/java-backstory/README.md new file mode 100644 index 000000000000..ecc96e1a8fc3 --- /dev/null +++ b/java-backstory/README.md @@ -0,0 +1,205 @@ +# Google Malachite Common Protos Client for Java + +Java idiomatic client for [Malachite Common Protos][product-docs]. + +[![Maven][maven-version-image]][maven-version-link] +![Stability][stability-image] + +- [Product Documentation][product-docs] +- [Client Library Documentation][javadocs] + +> Note: This client is a work-in-progress, and may occasionally +> make backwards-incompatible changes. + + +## Quickstart + + +If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file: + +```xml + + + + com.google.cloud + libraries-bom + 26.83.0 + pom + import + + + + + + + com.google.cloud + google-cloud-backstory + + +``` + +If you are using Maven without the BOM, add this to your dependencies: + + +```xml + + com.google.cloud + google-cloud-backstory + 0.0.0 + +``` + +If you are using Gradle without BOM, add this to your dependencies: + +```Groovy +implementation 'com.google.cloud:google-cloud-backstory:0.0.0' +``` + +If you are using SBT, add this to your dependencies: + +```Scala +libraryDependencies += "com.google.cloud" % "google-cloud-backstory" % "0.0.0" +``` + +## Authentication + +See the [Authentication][authentication] section in the base directory's README. + +## Authorization + +The client application making API calls must be granted [authorization scopes][auth-scopes] required for the desired Malachite Common Protos APIs, and the authenticated principal must have the [IAM role(s)][predefined-iam-roles] required to access GCP resources using the Malachite Common Protos API calls. + +## Getting Started + +### Prerequisites + +You will need a [Google Cloud Platform Console][developer-console] project with the Malachite Common Protos [API enabled][enable-api]. +You will need to [enable billing][enable-billing] to use Google Malachite Common Protos. +[Follow these instructions][create-project] to get your project set up. You will also need to set up the local development environment by +[installing the Google Cloud Command Line Interface][cloud-cli] and running the following commands in command line: +`gcloud auth login` and `gcloud config set project [YOUR PROJECT ID]`. + +### Installation and setup + +You'll need to obtain the `google-cloud-backstory` library. See the [Quickstart](#quickstart) section +to add `google-cloud-backstory` as a dependency in your code. + +## About Malachite Common Protos + + +[Malachite Common Protos][product-docs] Common Universal Data Model (UDM) and Entity protos used by Chronicle. + +See the [Malachite Common Protos client library docs][javadocs] to learn how to +use this Malachite Common Protos Client Library. + + + + + + +## Troubleshooting + +To get help, follow the instructions in the [shared Troubleshooting document][troubleshooting]. + +## Transport + +Malachite Common Protos uses gRPC for the transport layer. + +## Supported Java Versions + +Java 8 or above is required for using this client. + +Google's Java client libraries, +[Google Cloud Client Libraries][cloudlibs] +and +[Google Cloud API Libraries][apilibs], +follow the +[Oracle Java SE support roadmap][oracle] +(see the Oracle Java SE Product Releases section). + +### For new development + +In general, new feature development occurs with support for the lowest Java +LTS version covered by Oracle's Premier Support (which typically lasts 5 years +from initial General Availability). If the minimum required JVM for a given +library is changed, it is accompanied by a [semver][semver] major release. + +Java 11 and (in September 2021) Java 17 are the best choices for new +development. + +### Keeping production systems current + +Google tests its client libraries with all current LTS versions covered by +Oracle's Extended Support (which typically lasts 8 years from initial +General Availability). + +#### Legacy support + +Google's client libraries support legacy versions of Java runtimes with long +term stable libraries that don't receive feature updates on a best efforts basis +as it may not be possible to backport all patches. + +Google provides updates on a best efforts basis to apps that continue to use +Java 7, though apps might need to upgrade to current versions of the library +that supports their JVM. + +#### Where to find specific information + +The latest versions and the supported Java versions are identified on +the individual GitHub repository `github.com/GoogleAPIs/java-SERVICENAME` +and on [google-cloud-java][g-c-j]. + +## Versioning + + +This library follows [Semantic Versioning](http://semver.org/). + + +It is currently in major version zero (``0.y.z``), which means that anything may change at any time +and the public API should not be considered stable. + + +## Contributing + + +Contributions to this library are always welcome and highly encouraged. + +See [CONTRIBUTING][contributing] for more information how to get started. + +Please note that this project is released with a Contributor Code of Conduct. By participating in +this project you agree to abide by its terms. See [Code of Conduct][code-of-conduct] for more +information. + + +## License + +Apache 2.0 - See [LICENSE][license] for more information. + +Java is a registered trademark of Oracle and/or its affiliates. + +[product-docs]: https://cloud.google.com/chronicle/docs/secops/secops-overview +[javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-backstory/latest/overview +[stability-image]: https://img.shields.io/badge/stability-preview-yellow +[maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-backstory.svg +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-backstory/0.0.0 +[authentication]: https://github.com/googleapis/google-cloud-java#authentication +[auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes +[predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles +[iam-policy]: https://cloud.google.com/iam/docs/overview#cloud-iam-policy +[developer-console]: https://console.developers.google.com/ +[create-project]: https://cloud.google.com/resource-manager/docs/creating-managing-projects +[cloud-cli]: https://cloud.google.com/cli +[troubleshooting]: https://github.com/googleapis/google-cloud-java/blob/main/TROUBLESHOOTING.md +[contributing]: https://github.com/googleapis/google-cloud-java/blob/main/CONTRIBUTING.md +[code-of-conduct]: https://github.com/googleapis/google-cloud-java/blob/main/CODE_OF_CONDUCT.md#contributor-code-of-conduct +[license]: https://github.com/googleapis/google-cloud-java/blob/main/LICENSE +[enable-billing]: https://cloud.google.com/apis/docs/getting-started#enabling_billing +[enable-api]: https://console.cloud.google.com/flows/enableapi?apiid=backstory.googleapis.com +[libraries-bom]: https://github.com/GoogleCloudPlatform/cloud-opensource-java/wiki/The-Google-Cloud-Platform-Libraries-BOM +[shell_img]: https://gstatic.com/cloudssh/images/open-btn.png + +[semver]: https://semver.org/ +[cloudlibs]: https://cloud.google.com/apis/docs/client-libraries-explained +[apilibs]: https://cloud.google.com/apis/docs/client-libraries-explained#google_api_client_libraries +[oracle]: https://www.oracle.com/java/technologies/java-se-support-roadmap.html +[g-c-j]: http://github.com/googleapis/google-cloud-java diff --git a/java-backstory/google-cloud-backstory-bom/pom.xml b/java-backstory/google-cloud-backstory-bom/pom.xml new file mode 100644 index 000000000000..30cb2d7b46a6 --- /dev/null +++ b/java-backstory/google-cloud-backstory-bom/pom.xml @@ -0,0 +1,33 @@ + + + 4.0.0 + com.google.cloud + google-cloud-backstory-bom + 0.0.1-SNAPSHOT + pom + + com.google.cloud + google-cloud-pom-parent + 1.87.0-SNAPSHOT + ../../google-cloud-pom-parent/pom.xml + + + Google Malachite Common Protos BOM + + BOM for Malachite Common Protos + + + + true + + + + + + com.google.cloud + google-cloud-backstory + 0.0.1-SNAPSHOT + + + + diff --git a/java-backstory/google-cloud-backstory/pom.xml b/java-backstory/google-cloud-backstory/pom.xml new file mode 100644 index 000000000000..dd2bc5ca6631 --- /dev/null +++ b/java-backstory/google-cloud-backstory/pom.xml @@ -0,0 +1,106 @@ + + + 4.0.0 + com.google.cloud + google-cloud-backstory + 0.0.1-SNAPSHOT + jar + Google Malachite Common Protos + Malachite Common Protos Common Universal Data Model (UDM) and Entity protos used by Chronicle. + + com.google.cloud + google-cloud-backstory-parent + 0.0.1-SNAPSHOT + + + google-cloud-backstory + + + + io.grpc + grpc-api + + + io.grpc + grpc-stub + + + io.grpc + grpc-protobuf + + + com.google.api + api-common + + + com.google.protobuf + protobuf-java + + + com.google.api.grpc + proto-google-common-protos + + + + com.google.guava + guava + + + com.google.api + gax + + + com.google.api + gax-grpc + + + com.google.api + gax-httpjson + + + com.google.api.grpc + proto-google-iam-v1 + + + org.threeten + threetenbp + + + + + com.google.api.grpc + grpc-google-common-protos + test + + + com.google.api.grpc + grpc-google-iam-v1 + test + + + junit + junit + test + + + + + com.google.api + gax + testlib + test + + + com.google.api + gax-grpc + testlib + test + + + com.google.api + gax-httpjson + testlib + test + + + diff --git a/java-backstory/owlbot.py b/java-backstory/owlbot.py new file mode 100644 index 000000000000..fbb37df70f1a --- /dev/null +++ b/java-backstory/owlbot.py @@ -0,0 +1,37 @@ +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import synthtool as s +from synthtool.languages import java + +for library in s.get_staging_dirs(): + # put any special-case replacements here + s.move(library) + +s.remove_staging_dirs() +java.common_templates( + monorepo=True, + excludes=[ + ".github/*", + ".kokoro/*", + "samples/*", + "CODE_OF_CONDUCT.md", + "CONTRIBUTING.md", + "LICENSE", + "SECURITY.md", + "java.header", + "license-checks.xml", + "renovate.json", + ".gitignore" +]) \ No newline at end of file diff --git a/java-backstory/pom.xml b/java-backstory/pom.xml new file mode 100644 index 000000000000..99315bc2491a --- /dev/null +++ b/java-backstory/pom.xml @@ -0,0 +1,43 @@ + + + 4.0.0 + com.google.cloud + google-cloud-backstory-parent + pom + 0.0.1-SNAPSHOT + Google Malachite Common Protos Parent + + Java idiomatic client for Google Cloud Platform services. + + + + com.google.cloud + google-cloud-jar-parent + 1.87.0-SNAPSHOT + ../google-cloud-jar-parent/pom.xml + + + + UTF-8 + UTF-8 + github + google-cloud-backstory-parent + + + + + + com.google.cloud + google-cloud-backstory + 0.0.1-SNAPSHOT + + + + + + + google-cloud-backstory + google-cloud-backstory-bom + + + diff --git a/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java b/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java new file mode 100644 index 000000000000..c6b83d7d51bb --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java @@ -0,0 +1,576 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Stores information about an analytics metric used in a rule.
+ * 
+ * + * Protobuf type {@code google.backstory.AnalyticsMetadata} + */ +@com.google.protobuf.Generated +public final class AnalyticsMetadata extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.AnalyticsMetadata) + AnalyticsMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AnalyticsMetadata"); + } + + // Use AnalyticsMetadata.newBuilder() to construct. + private AnalyticsMetadata(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AnalyticsMetadata() { + analytic_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_AnalyticsMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AnalyticsMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AnalyticsMetadata.class, + com.google.backstory.AnalyticsMetadata.Builder.class); + } + + public static final int ANALYTIC_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object analytic_ = ""; + + /** + * + * + *
+   * Name of the analytic.
+   * 
+ * + * string analytic = 1; + * + * @return The analytic. + */ + @java.lang.Override + public java.lang.String getAnalytic() { + java.lang.Object ref = analytic_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + analytic_ = s; + return s; + } + } + + /** + * + * + *
+   * Name of the analytic.
+   * 
+ * + * string analytic = 1; + * + * @return The bytes for analytic. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAnalyticBytes() { + java.lang.Object ref = analytic_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + analytic_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(analytic_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, analytic_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(analytic_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, analytic_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.AnalyticsMetadata)) { + return super.equals(obj); + } + com.google.backstory.AnalyticsMetadata other = (com.google.backstory.AnalyticsMetadata) obj; + + if (!getAnalytic().equals(other.getAnalytic())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ANALYTIC_FIELD_NUMBER; + hash = (53 * hash) + getAnalytic().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.AnalyticsMetadata parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AnalyticsMetadata parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.AnalyticsMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AnalyticsMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.AnalyticsMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Stores information about an analytics metric used in a rule.
+   * 
+ * + * Protobuf type {@code google.backstory.AnalyticsMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.AnalyticsMetadata) + com.google.backstory.AnalyticsMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_AnalyticsMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AnalyticsMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AnalyticsMetadata.class, + com.google.backstory.AnalyticsMetadata.Builder.class); + } + + // Construct using com.google.backstory.AnalyticsMetadata.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + analytic_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_AnalyticsMetadata_descriptor; + } + + @java.lang.Override + public com.google.backstory.AnalyticsMetadata getDefaultInstanceForType() { + return com.google.backstory.AnalyticsMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.AnalyticsMetadata build() { + com.google.backstory.AnalyticsMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.AnalyticsMetadata buildPartial() { + com.google.backstory.AnalyticsMetadata result = + new com.google.backstory.AnalyticsMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.AnalyticsMetadata result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.analytic_ = analytic_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.AnalyticsMetadata) { + return mergeFrom((com.google.backstory.AnalyticsMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.AnalyticsMetadata other) { + if (other == com.google.backstory.AnalyticsMetadata.getDefaultInstance()) return this; + if (!other.getAnalytic().isEmpty()) { + analytic_ = other.analytic_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + analytic_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object analytic_ = ""; + + /** + * + * + *
+     * Name of the analytic.
+     * 
+ * + * string analytic = 1; + * + * @return The analytic. + */ + public java.lang.String getAnalytic() { + java.lang.Object ref = analytic_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + analytic_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Name of the analytic.
+     * 
+ * + * string analytic = 1; + * + * @return The bytes for analytic. + */ + public com.google.protobuf.ByteString getAnalyticBytes() { + java.lang.Object ref = analytic_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + analytic_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Name of the analytic.
+     * 
+ * + * string analytic = 1; + * + * @param value The analytic to set. + * @return This builder for chaining. + */ + public Builder setAnalytic(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + analytic_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Name of the analytic.
+     * 
+ * + * string analytic = 1; + * + * @return This builder for chaining. + */ + public Builder clearAnalytic() { + analytic_ = getDefaultInstance().getAnalytic(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Name of the analytic.
+     * 
+ * + * string analytic = 1; + * + * @param value The bytes for analytic to set. + * @return This builder for chaining. + */ + public Builder setAnalyticBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + analytic_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.AnalyticsMetadata) + } + + // @@protoc_insertion_point(class_scope:google.backstory.AnalyticsMetadata) + private static final com.google.backstory.AnalyticsMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.AnalyticsMetadata(); + } + + public static com.google.backstory.AnalyticsMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AnalyticsMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.AnalyticsMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java new file mode 100644 index 000000000000..29163e6a2c87 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java @@ -0,0 +1,39 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AnalyticsMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.AnalyticsMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Name of the analytic.
+   * 
+ * + * string analytic = 1; + * + * @return The analytic. + */ + java.lang.String getAnalytic(); + + /** + * + * + *
+   * Name of the analytic.
+   * 
+ * + * string analytic = 1; + * + * @return The bytes for analytic. + */ + com.google.protobuf.ByteString getAnalyticBytes(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java b/java-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java new file mode 100644 index 000000000000..48fa43e177b5 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java @@ -0,0 +1,781 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Windows AppCompatCache (Application Compatibility) metadata.
+ * 
+ * + * Protobuf type {@code google.backstory.AppCompatMetadata} + */ +@com.google.protobuf.Generated +public final class AppCompatMetadata extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.AppCompatMetadata) + AppCompatMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AppCompatMetadata"); + } + + // Use AppCompatMetadata.newBuilder() to construct. + private AppCompatMetadata(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AppCompatMetadata() { + controlSet_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_AppCompatMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AppCompatMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AppCompatMetadata.class, + com.google.backstory.AppCompatMetadata.Builder.class); + } + + public static final int SEQUENCE_FIELD_NUMBER = 1; + private int sequence_ = 0; + + /** + * + * + *
+   * Indicates the chronological order in which the entry was added to the
+   * cache.
+   * 
+ * + * int32 sequence = 1; + * + * @return The sequence. + */ + @java.lang.Override + public int getSequence() { + return sequence_; + } + + public static final int EXECUTED_FIELD_NUMBER = 2; + private boolean executed_ = false; + + /** + * + * + *
+   * Indicates whether the file associated with the entry was executed.
+   * 
+ * + * bool executed = 2; + * + * @return The executed. + */ + @java.lang.Override + public boolean getExecuted() { + return executed_; + } + + public static final int CONTROL_SET_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object controlSet_ = ""; + + /** + * + * + *
+   * Indicates which registry Control Set the AppCompatCache data belongs to
+   * (e.g., "ControlSet001").
+   * 
+ * + * string control_set = 3; + * + * @return The controlSet. + */ + @java.lang.Override + public java.lang.String getControlSet() { + java.lang.Object ref = controlSet_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + controlSet_ = s; + return s; + } + } + + /** + * + * + *
+   * Indicates which registry Control Set the AppCompatCache data belongs to
+   * (e.g., "ControlSet001").
+   * 
+ * + * string control_set = 3; + * + * @return The bytes for controlSet. + */ + @java.lang.Override + public com.google.protobuf.ByteString getControlSetBytes() { + java.lang.Object ref = controlSet_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + controlSet_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (sequence_ != 0) { + output.writeInt32(1, sequence_); + } + if (executed_ != false) { + output.writeBool(2, executed_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(controlSet_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, controlSet_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (sequence_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, sequence_); + } + if (executed_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, executed_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(controlSet_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, controlSet_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.AppCompatMetadata)) { + return super.equals(obj); + } + com.google.backstory.AppCompatMetadata other = (com.google.backstory.AppCompatMetadata) obj; + + if (getSequence() != other.getSequence()) return false; + if (getExecuted() != other.getExecuted()) return false; + if (!getControlSet().equals(other.getControlSet())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SEQUENCE_FIELD_NUMBER; + hash = (53 * hash) + getSequence(); + hash = (37 * hash) + EXECUTED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getExecuted()); + hash = (37 * hash) + CONTROL_SET_FIELD_NUMBER; + hash = (53 * hash) + getControlSet().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.AppCompatMetadata parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AppCompatMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AppCompatMetadata parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AppCompatMetadata parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.AppCompatMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AppCompatMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.AppCompatMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Windows AppCompatCache (Application Compatibility) metadata.
+   * 
+ * + * Protobuf type {@code google.backstory.AppCompatMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.AppCompatMetadata) + com.google.backstory.AppCompatMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_AppCompatMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AppCompatMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AppCompatMetadata.class, + com.google.backstory.AppCompatMetadata.Builder.class); + } + + // Construct using com.google.backstory.AppCompatMetadata.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + sequence_ = 0; + executed_ = false; + controlSet_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_AppCompatMetadata_descriptor; + } + + @java.lang.Override + public com.google.backstory.AppCompatMetadata getDefaultInstanceForType() { + return com.google.backstory.AppCompatMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.AppCompatMetadata build() { + com.google.backstory.AppCompatMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.AppCompatMetadata buildPartial() { + com.google.backstory.AppCompatMetadata result = + new com.google.backstory.AppCompatMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.AppCompatMetadata result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.sequence_ = sequence_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.executed_ = executed_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.controlSet_ = controlSet_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.AppCompatMetadata) { + return mergeFrom((com.google.backstory.AppCompatMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.AppCompatMetadata other) { + if (other == com.google.backstory.AppCompatMetadata.getDefaultInstance()) return this; + if (other.getSequence() != 0) { + setSequence(other.getSequence()); + } + if (other.getExecuted() != false) { + setExecuted(other.getExecuted()); + } + if (!other.getControlSet().isEmpty()) { + controlSet_ = other.controlSet_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + sequence_ = input.readInt32(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 16: + { + executed_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + controlSet_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int sequence_; + + /** + * + * + *
+     * Indicates the chronological order in which the entry was added to the
+     * cache.
+     * 
+ * + * int32 sequence = 1; + * + * @return The sequence. + */ + @java.lang.Override + public int getSequence() { + return sequence_; + } + + /** + * + * + *
+     * Indicates the chronological order in which the entry was added to the
+     * cache.
+     * 
+ * + * int32 sequence = 1; + * + * @param value The sequence to set. + * @return This builder for chaining. + */ + public Builder setSequence(int value) { + + sequence_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates the chronological order in which the entry was added to the
+     * cache.
+     * 
+ * + * int32 sequence = 1; + * + * @return This builder for chaining. + */ + public Builder clearSequence() { + bitField0_ = (bitField0_ & ~0x00000001); + sequence_ = 0; + onChanged(); + return this; + } + + private boolean executed_; + + /** + * + * + *
+     * Indicates whether the file associated with the entry was executed.
+     * 
+ * + * bool executed = 2; + * + * @return The executed. + */ + @java.lang.Override + public boolean getExecuted() { + return executed_; + } + + /** + * + * + *
+     * Indicates whether the file associated with the entry was executed.
+     * 
+ * + * bool executed = 2; + * + * @param value The executed to set. + * @return This builder for chaining. + */ + public Builder setExecuted(boolean value) { + + executed_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates whether the file associated with the entry was executed.
+     * 
+ * + * bool executed = 2; + * + * @return This builder for chaining. + */ + public Builder clearExecuted() { + bitField0_ = (bitField0_ & ~0x00000002); + executed_ = false; + onChanged(); + return this; + } + + private java.lang.Object controlSet_ = ""; + + /** + * + * + *
+     * Indicates which registry Control Set the AppCompatCache data belongs to
+     * (e.g., "ControlSet001").
+     * 
+ * + * string control_set = 3; + * + * @return The controlSet. + */ + public java.lang.String getControlSet() { + java.lang.Object ref = controlSet_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + controlSet_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Indicates which registry Control Set the AppCompatCache data belongs to
+     * (e.g., "ControlSet001").
+     * 
+ * + * string control_set = 3; + * + * @return The bytes for controlSet. + */ + public com.google.protobuf.ByteString getControlSetBytes() { + java.lang.Object ref = controlSet_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + controlSet_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Indicates which registry Control Set the AppCompatCache data belongs to
+     * (e.g., "ControlSet001").
+     * 
+ * + * string control_set = 3; + * + * @param value The controlSet to set. + * @return This builder for chaining. + */ + public Builder setControlSet(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + controlSet_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates which registry Control Set the AppCompatCache data belongs to
+     * (e.g., "ControlSet001").
+     * 
+ * + * string control_set = 3; + * + * @return This builder for chaining. + */ + public Builder clearControlSet() { + controlSet_ = getDefaultInstance().getControlSet(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates which registry Control Set the AppCompatCache data belongs to
+     * (e.g., "ControlSet001").
+     * 
+ * + * string control_set = 3; + * + * @param value The bytes for controlSet to set. + * @return This builder for chaining. + */ + public Builder setControlSetBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + controlSet_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.AppCompatMetadata) + } + + // @@protoc_insertion_point(class_scope:google.backstory.AppCompatMetadata) + private static final com.google.backstory.AppCompatMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.AppCompatMetadata(); + } + + public static com.google.backstory.AppCompatMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AppCompatMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.AppCompatMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java new file mode 100644 index 000000000000..dfc8ef8dbbc2 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java @@ -0,0 +1,68 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AppCompatMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.AppCompatMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Indicates the chronological order in which the entry was added to the
+   * cache.
+   * 
+ * + * int32 sequence = 1; + * + * @return The sequence. + */ + int getSequence(); + + /** + * + * + *
+   * Indicates whether the file associated with the entry was executed.
+   * 
+ * + * bool executed = 2; + * + * @return The executed. + */ + boolean getExecuted(); + + /** + * + * + *
+   * Indicates which registry Control Set the AppCompatCache data belongs to
+   * (e.g., "ControlSet001").
+   * 
+ * + * string control_set = 3; + * + * @return The controlSet. + */ + java.lang.String getControlSet(); + + /** + * + * + *
+   * Indicates which registry Control Set the AppCompatCache data belongs to
+   * (e.g., "ControlSet001").
+   * 
+ * + * string control_set = 3; + * + * @return The bytes for controlSet. + */ + com.google.protobuf.ByteString getControlSetBytes(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Artifact.java b/java-backstory/src/main/java/com/google/backstory/Artifact.java new file mode 100644 index 000000000000..52f404e1bc04 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Artifact.java @@ -0,0 +1,5157 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Information about an artifact. The artifact can only be an IP.
+ * 
+ * + * Protobuf type {@code google.backstory.Artifact} + */ +@com.google.protobuf.Generated +public final class Artifact extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Artifact) + ArtifactOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Artifact"); + } + + // Use Artifact.newBuilder() to construct. + private Artifact(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Artifact() { + ip_ = ""; + asOwner_ = ""; + jarm_ = ""; + regionalInternetRegistry_ = ""; + tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + whois_ = ""; + tunnels_ = java.util.Collections.emptyList(); + risks_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Artifact_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Artifact_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Artifact.class, com.google.backstory.Artifact.Builder.class); + } + + private int bitField0_; + public static final int IP_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object ip_ = ""; + + /** + * + * + *
+   * IP address of the artifact.
+   * This field can be used as an entity indicator for an external destination
+   * IP entity.
+   * 
+ * + * string ip = 1; + * + * @return The ip. + */ + @java.lang.Override + public java.lang.String getIp() { + java.lang.Object ref = ip_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + ip_ = s; + return s; + } + } + + /** + * + * + *
+   * IP address of the artifact.
+   * This field can be used as an entity indicator for an external destination
+   * IP entity.
+   * 
+ * + * string ip = 1; + * + * @return The bytes for ip. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIpBytes() { + java.lang.Object ref = ip_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + ip_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PREVALENCE_FIELD_NUMBER = 2; + private com.google.backstory.Prevalence prevalence_; + + /** + * + * + *
+   * The prevalence of the artifact within the customer's environment.
+   * 
+ * + * .google.backstory.Prevalence prevalence = 2; + * + * @return Whether the prevalence field is set. + */ + @java.lang.Override + public boolean hasPrevalence() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The prevalence of the artifact within the customer's environment.
+   * 
+ * + * .google.backstory.Prevalence prevalence = 2; + * + * @return The prevalence. + */ + @java.lang.Override + public com.google.backstory.Prevalence getPrevalence() { + return prevalence_ == null ? com.google.backstory.Prevalence.getDefaultInstance() : prevalence_; + } + + /** + * + * + *
+   * The prevalence of the artifact within the customer's environment.
+   * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + @java.lang.Override + public com.google.backstory.PrevalenceOrBuilder getPrevalenceOrBuilder() { + return prevalence_ == null ? com.google.backstory.Prevalence.getDefaultInstance() : prevalence_; + } + + public static final int FIRST_SEEN_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp firstSeenTime_; + + /** + * + * + *
+   * First seen timestamp of the IP in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + * + * @return Whether the firstSeenTime field is set. + */ + @java.lang.Override + public boolean hasFirstSeenTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * First seen timestamp of the IP in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + * + * @return The firstSeenTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getFirstSeenTime() { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } + + /** + * + * + *
+   * First seen timestamp of the IP in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getFirstSeenTimeOrBuilder() { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } + + public static final int LAST_SEEN_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp lastSeenTime_; + + /** + * + * + *
+   * Last seen timestamp of the IP address in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + * + * @return Whether the lastSeenTime field is set. + */ + @java.lang.Override + public boolean hasLastSeenTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Last seen timestamp of the IP address in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + * + * @return The lastSeenTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastSeenTime() { + return lastSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastSeenTime_; + } + + /** + * + * + *
+   * Last seen timestamp of the IP address in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastSeenTimeOrBuilder() { + return lastSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastSeenTime_; + } + + public static final int LOCATION_FIELD_NUMBER = 5; + private com.google.backstory.Location location_; + + /** + * + * + *
+   * Location of the Artifact's IP address.
+   * 
+ * + * .google.backstory.Location location = 5; + * + * @return Whether the location field is set. + */ + @java.lang.Override + public boolean hasLocation() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+   * Location of the Artifact's IP address.
+   * 
+ * + * .google.backstory.Location location = 5; + * + * @return The location. + */ + @java.lang.Override + public com.google.backstory.Location getLocation() { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } + + /** + * + * + *
+   * Location of the Artifact's IP address.
+   * 
+ * + * .google.backstory.Location location = 5; + */ + @java.lang.Override + public com.google.backstory.LocationOrBuilder getLocationOrBuilder() { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } + + public static final int NETWORK_FIELD_NUMBER = 6; + private com.google.backstory.Network network_; + + /** + * + * + *
+   * Network information related to the Artifact's IP address.
+   * 
+ * + * .google.backstory.Network network = 6; + * + * @return Whether the network field is set. + */ + @java.lang.Override + public boolean hasNetwork() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+   * Network information related to the Artifact's IP address.
+   * 
+ * + * .google.backstory.Network network = 6; + * + * @return The network. + */ + @java.lang.Override + public com.google.backstory.Network getNetwork() { + return network_ == null ? com.google.backstory.Network.getDefaultInstance() : network_; + } + + /** + * + * + *
+   * Network information related to the Artifact's IP address.
+   * 
+ * + * .google.backstory.Network network = 6; + */ + @java.lang.Override + public com.google.backstory.NetworkOrBuilder getNetworkOrBuilder() { + return network_ == null ? com.google.backstory.Network.getDefaultInstance() : network_; + } + + public static final int AS_OWNER_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object asOwner_ = ""; + + /** + * + * + *
+   * Owner of the Autonomous System to which the IP address belongs.
+   * 
+ * + * string as_owner = 7; + * + * @return The asOwner. + */ + @java.lang.Override + public java.lang.String getAsOwner() { + java.lang.Object ref = asOwner_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + asOwner_ = s; + return s; + } + } + + /** + * + * + *
+   * Owner of the Autonomous System to which the IP address belongs.
+   * 
+ * + * string as_owner = 7; + * + * @return The bytes for asOwner. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAsOwnerBytes() { + java.lang.Object ref = asOwner_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + asOwner_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ASN_FIELD_NUMBER = 8; + private long asn_ = 0L; + + /** + * + * + *
+   * Autonomous System Number to which the IP address belongs.
+   * 
+ * + * int64 asn = 8; + * + * @return The asn. + */ + @java.lang.Override + public long getAsn() { + return asn_; + } + + public static final int JARM_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private volatile java.lang.Object jarm_ = ""; + + /** + * + * + *
+   * The JARM hash for the IP address.
+   * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+   * 
+ * + * string jarm = 9; + * + * @return The jarm. + */ + @java.lang.Override + public java.lang.String getJarm() { + java.lang.Object ref = jarm_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jarm_ = s; + return s; + } + } + + /** + * + * + *
+   * The JARM hash for the IP address.
+   * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+   * 
+ * + * string jarm = 9; + * + * @return The bytes for jarm. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJarmBytes() { + java.lang.Object ref = jarm_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jarm_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LAST_HTTPS_CERTIFICATE_FIELD_NUMBER = 10; + private com.google.backstory.SSLCertificate lastHttpsCertificate_; + + /** + * + * + *
+   * SSL certificate information about the IP address.
+   * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + * + * @return Whether the lastHttpsCertificate field is set. + */ + @java.lang.Override + public boolean hasLastHttpsCertificate() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+   * SSL certificate information about the IP address.
+   * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + * + * @return The lastHttpsCertificate. + */ + @java.lang.Override + public com.google.backstory.SSLCertificate getLastHttpsCertificate() { + return lastHttpsCertificate_ == null + ? com.google.backstory.SSLCertificate.getDefaultInstance() + : lastHttpsCertificate_; + } + + /** + * + * + *
+   * SSL certificate information about the IP address.
+   * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + @java.lang.Override + public com.google.backstory.SSLCertificateOrBuilder getLastHttpsCertificateOrBuilder() { + return lastHttpsCertificate_ == null + ? com.google.backstory.SSLCertificate.getDefaultInstance() + : lastHttpsCertificate_; + } + + public static final int LAST_HTTPS_CERTIFICATE_DATE_FIELD_NUMBER = 11; + private com.google.protobuf.Timestamp lastHttpsCertificateDate_; + + /** + * + * + *
+   * Most recent date for the certificate in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + * + * @return Whether the lastHttpsCertificateDate field is set. + */ + @java.lang.Override + public boolean hasLastHttpsCertificateDate() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+   * Most recent date for the certificate in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + * + * @return The lastHttpsCertificateDate. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastHttpsCertificateDate() { + return lastHttpsCertificateDate_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastHttpsCertificateDate_; + } + + /** + * + * + *
+   * Most recent date for the certificate in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastHttpsCertificateDateOrBuilder() { + return lastHttpsCertificateDate_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastHttpsCertificateDate_; + } + + public static final int REGIONAL_INTERNET_REGISTRY_FIELD_NUMBER = 12; + + @SuppressWarnings("serial") + private volatile java.lang.Object regionalInternetRegistry_ = ""; + + /** + * + * + *
+   * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+   * 
+ * + * string regional_internet_registry = 12; + * + * @return The regionalInternetRegistry. + */ + @java.lang.Override + public java.lang.String getRegionalInternetRegistry() { + java.lang.Object ref = regionalInternetRegistry_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + regionalInternetRegistry_ = s; + return s; + } + } + + /** + * + * + *
+   * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+   * 
+ * + * string regional_internet_registry = 12; + * + * @return The bytes for regionalInternetRegistry. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRegionalInternetRegistryBytes() { + java.lang.Object ref = regionalInternetRegistry_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + regionalInternetRegistry_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TAGS_FIELD_NUMBER = 13; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList tags_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @return A list containing the tags. + */ + public com.google.protobuf.ProtocolStringList getTagsList() { + return tags_; + } + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @return The count of tags. + */ + public int getTagsCount() { + return tags_.size(); + } + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @param index The index of the element to return. + * @return The tags at the given index. + */ + public java.lang.String getTags(int index) { + return tags_.get(index); + } + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @param index The index of the value to return. + * @return The bytes of the tags at the given index. + */ + public com.google.protobuf.ByteString getTagsBytes(int index) { + return tags_.getByteString(index); + } + + public static final int WHOIS_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private volatile java.lang.Object whois_ = ""; + + /** + * + * + *
+   * WHOIS information as returned from the pertinent WHOIS server.
+   * 
+ * + * string whois = 14; + * + * @return The whois. + */ + @java.lang.Override + public java.lang.String getWhois() { + java.lang.Object ref = whois_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + whois_ = s; + return s; + } + } + + /** + * + * + *
+   * WHOIS information as returned from the pertinent WHOIS server.
+   * 
+ * + * string whois = 14; + * + * @return The bytes for whois. + */ + @java.lang.Override + public com.google.protobuf.ByteString getWhoisBytes() { + java.lang.Object ref = whois_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + whois_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int WHOIS_DATE_FIELD_NUMBER = 15; + private com.google.protobuf.Timestamp whoisDate_; + + /** + * + * + *
+   * Date of the last update of the WHOIS record in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + * + * @return Whether the whoisDate field is set. + */ + @java.lang.Override + public boolean hasWhoisDate() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
+   * Date of the last update of the WHOIS record in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + * + * @return The whoisDate. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getWhoisDate() { + return whoisDate_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : whoisDate_; + } + + /** + * + * + *
+   * Date of the last update of the WHOIS record in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getWhoisDateOrBuilder() { + return whoisDate_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : whoisDate_; + } + + public static final int TUNNELS_FIELD_NUMBER = 16; + + @SuppressWarnings("serial") + private java.util.List tunnels_; + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + @java.lang.Override + public java.util.List getTunnelsList() { + return tunnels_; + } + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + @java.lang.Override + public java.util.List getTunnelsOrBuilderList() { + return tunnels_; + } + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + @java.lang.Override + public int getTunnelsCount() { + return tunnels_.size(); + } + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + @java.lang.Override + public com.google.backstory.Tunnels getTunnels(int index) { + return tunnels_.get(index); + } + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + @java.lang.Override + public com.google.backstory.TunnelsOrBuilder getTunnelsOrBuilder(int index) { + return tunnels_.get(index); + } + + public static final int ANONYMOUS_FIELD_NUMBER = 17; + private boolean anonymous_ = false; + + /** + * + * + *
+   * Whether the VPN tunnels are configured for anonymous browsing or not.
+   * 
+ * + * bool anonymous = 17; + * + * @return The anonymous. + */ + @java.lang.Override + public boolean getAnonymous() { + return anonymous_; + } + + public static final int ARTIFACT_CLIENT_FIELD_NUMBER = 18; + private com.google.backstory.ArtifactClient artifactClient_; + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + * + * @return Whether the artifactClient field is set. + */ + @java.lang.Override + public boolean hasArtifactClient() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + * + * @return The artifactClient. + */ + @java.lang.Override + public com.google.backstory.ArtifactClient getArtifactClient() { + return artifactClient_ == null + ? com.google.backstory.ArtifactClient.getDefaultInstance() + : artifactClient_; + } + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + @java.lang.Override + public com.google.backstory.ArtifactClientOrBuilder getArtifactClientOrBuilder() { + return artifactClient_ == null + ? com.google.backstory.ArtifactClient.getDefaultInstance() + : artifactClient_; + } + + public static final int RISKS_FIELD_NUMBER = 19; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList risks_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @return A list containing the risks. + */ + public com.google.protobuf.ProtocolStringList getRisksList() { + return risks_; + } + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @return The count of risks. + */ + public int getRisksCount() { + return risks_.size(); + } + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @param index The index of the element to return. + * @return The risks at the given index. + */ + public java.lang.String getRisks(int index) { + return risks_.get(index); + } + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @param index The index of the value to return. + * @return The bytes of the risks at the given index. + */ + public com.google.protobuf.ByteString getRisksBytes(int index) { + return risks_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(ip_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, ip_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getPrevalence()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(3, getFirstSeenTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(4, getLastSeenTime()); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(5, getLocation()); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(6, getNetwork()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(asOwner_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, asOwner_); + } + if (asn_ != 0L) { + output.writeInt64(8, asn_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(jarm_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 9, jarm_); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeMessage(10, getLastHttpsCertificate()); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeMessage(11, getLastHttpsCertificateDate()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(regionalInternetRegistry_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 12, regionalInternetRegistry_); + } + for (int i = 0; i < tags_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 13, tags_.getRaw(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(whois_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 14, whois_); + } + if (((bitField0_ & 0x00000080) != 0)) { + output.writeMessage(15, getWhoisDate()); + } + for (int i = 0; i < tunnels_.size(); i++) { + output.writeMessage(16, tunnels_.get(i)); + } + if (anonymous_ != false) { + output.writeBool(17, anonymous_); + } + if (((bitField0_ & 0x00000100) != 0)) { + output.writeMessage(18, getArtifactClient()); + } + for (int i = 0; i < risks_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 19, risks_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(ip_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, ip_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPrevalence()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFirstSeenTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getLastSeenTime()); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getLocation()); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getNetwork()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(asOwner_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(7, asOwner_); + } + if (asn_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, asn_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(jarm_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(9, jarm_); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(10, getLastHttpsCertificate()); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 11, getLastHttpsCertificateDate()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(regionalInternetRegistry_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(12, regionalInternetRegistry_); + } + { + int dataSize = 0; + for (int i = 0; i < tags_.size(); i++) { + dataSize += computeStringSizeNoTag(tags_.getRaw(i)); + } + size += dataSize; + size += 1 * getTagsList().size(); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(whois_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(14, whois_); + } + if (((bitField0_ & 0x00000080) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, getWhoisDate()); + } + for (int i = 0; i < tunnels_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(16, tunnels_.get(i)); + } + if (anonymous_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(17, anonymous_); + } + if (((bitField0_ & 0x00000100) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getArtifactClient()); + } + { + int dataSize = 0; + for (int i = 0; i < risks_.size(); i++) { + dataSize += computeStringSizeNoTag(risks_.getRaw(i)); + } + size += dataSize; + size += 2 * getRisksList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Artifact)) { + return super.equals(obj); + } + com.google.backstory.Artifact other = (com.google.backstory.Artifact) obj; + + if (!getIp().equals(other.getIp())) return false; + if (hasPrevalence() != other.hasPrevalence()) return false; + if (hasPrevalence()) { + if (!getPrevalence().equals(other.getPrevalence())) return false; + } + if (hasFirstSeenTime() != other.hasFirstSeenTime()) return false; + if (hasFirstSeenTime()) { + if (!getFirstSeenTime().equals(other.getFirstSeenTime())) return false; + } + if (hasLastSeenTime() != other.hasLastSeenTime()) return false; + if (hasLastSeenTime()) { + if (!getLastSeenTime().equals(other.getLastSeenTime())) return false; + } + if (hasLocation() != other.hasLocation()) return false; + if (hasLocation()) { + if (!getLocation().equals(other.getLocation())) return false; + } + if (hasNetwork() != other.hasNetwork()) return false; + if (hasNetwork()) { + if (!getNetwork().equals(other.getNetwork())) return false; + } + if (!getAsOwner().equals(other.getAsOwner())) return false; + if (getAsn() != other.getAsn()) return false; + if (!getJarm().equals(other.getJarm())) return false; + if (hasLastHttpsCertificate() != other.hasLastHttpsCertificate()) return false; + if (hasLastHttpsCertificate()) { + if (!getLastHttpsCertificate().equals(other.getLastHttpsCertificate())) return false; + } + if (hasLastHttpsCertificateDate() != other.hasLastHttpsCertificateDate()) return false; + if (hasLastHttpsCertificateDate()) { + if (!getLastHttpsCertificateDate().equals(other.getLastHttpsCertificateDate())) return false; + } + if (!getRegionalInternetRegistry().equals(other.getRegionalInternetRegistry())) return false; + if (!getTagsList().equals(other.getTagsList())) return false; + if (!getWhois().equals(other.getWhois())) return false; + if (hasWhoisDate() != other.hasWhoisDate()) return false; + if (hasWhoisDate()) { + if (!getWhoisDate().equals(other.getWhoisDate())) return false; + } + if (!getTunnelsList().equals(other.getTunnelsList())) return false; + if (getAnonymous() != other.getAnonymous()) return false; + if (hasArtifactClient() != other.hasArtifactClient()) return false; + if (hasArtifactClient()) { + if (!getArtifactClient().equals(other.getArtifactClient())) return false; + } + if (!getRisksList().equals(other.getRisksList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + IP_FIELD_NUMBER; + hash = (53 * hash) + getIp().hashCode(); + if (hasPrevalence()) { + hash = (37 * hash) + PREVALENCE_FIELD_NUMBER; + hash = (53 * hash) + getPrevalence().hashCode(); + } + if (hasFirstSeenTime()) { + hash = (37 * hash) + FIRST_SEEN_TIME_FIELD_NUMBER; + hash = (53 * hash) + getFirstSeenTime().hashCode(); + } + if (hasLastSeenTime()) { + hash = (37 * hash) + LAST_SEEN_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastSeenTime().hashCode(); + } + if (hasLocation()) { + hash = (37 * hash) + LOCATION_FIELD_NUMBER; + hash = (53 * hash) + getLocation().hashCode(); + } + if (hasNetwork()) { + hash = (37 * hash) + NETWORK_FIELD_NUMBER; + hash = (53 * hash) + getNetwork().hashCode(); + } + hash = (37 * hash) + AS_OWNER_FIELD_NUMBER; + hash = (53 * hash) + getAsOwner().hashCode(); + hash = (37 * hash) + ASN_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getAsn()); + hash = (37 * hash) + JARM_FIELD_NUMBER; + hash = (53 * hash) + getJarm().hashCode(); + if (hasLastHttpsCertificate()) { + hash = (37 * hash) + LAST_HTTPS_CERTIFICATE_FIELD_NUMBER; + hash = (53 * hash) + getLastHttpsCertificate().hashCode(); + } + if (hasLastHttpsCertificateDate()) { + hash = (37 * hash) + LAST_HTTPS_CERTIFICATE_DATE_FIELD_NUMBER; + hash = (53 * hash) + getLastHttpsCertificateDate().hashCode(); + } + hash = (37 * hash) + REGIONAL_INTERNET_REGISTRY_FIELD_NUMBER; + hash = (53 * hash) + getRegionalInternetRegistry().hashCode(); + if (getTagsCount() > 0) { + hash = (37 * hash) + TAGS_FIELD_NUMBER; + hash = (53 * hash) + getTagsList().hashCode(); + } + hash = (37 * hash) + WHOIS_FIELD_NUMBER; + hash = (53 * hash) + getWhois().hashCode(); + if (hasWhoisDate()) { + hash = (37 * hash) + WHOIS_DATE_FIELD_NUMBER; + hash = (53 * hash) + getWhoisDate().hashCode(); + } + if (getTunnelsCount() > 0) { + hash = (37 * hash) + TUNNELS_FIELD_NUMBER; + hash = (53 * hash) + getTunnelsList().hashCode(); + } + hash = (37 * hash) + ANONYMOUS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAnonymous()); + if (hasArtifactClient()) { + hash = (37 * hash) + ARTIFACT_CLIENT_FIELD_NUMBER; + hash = (53 * hash) + getArtifactClient().hashCode(); + } + if (getRisksCount() > 0) { + hash = (37 * hash) + RISKS_FIELD_NUMBER; + hash = (53 * hash) + getRisksList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Artifact parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Artifact parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Artifact parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Artifact parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Artifact parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Artifact parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Artifact parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Artifact parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Artifact parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Artifact parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Artifact parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Artifact parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Artifact prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Information about an artifact. The artifact can only be an IP.
+   * 
+ * + * Protobuf type {@code google.backstory.Artifact} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Artifact) + com.google.backstory.ArtifactOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Artifact_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Artifact_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Artifact.class, com.google.backstory.Artifact.Builder.class); + } + + // Construct using com.google.backstory.Artifact.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetPrevalenceFieldBuilder(); + internalGetFirstSeenTimeFieldBuilder(); + internalGetLastSeenTimeFieldBuilder(); + internalGetLocationFieldBuilder(); + internalGetNetworkFieldBuilder(); + internalGetLastHttpsCertificateFieldBuilder(); + internalGetLastHttpsCertificateDateFieldBuilder(); + internalGetWhoisDateFieldBuilder(); + internalGetTunnelsFieldBuilder(); + internalGetArtifactClientFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + ip_ = ""; + prevalence_ = null; + if (prevalenceBuilder_ != null) { + prevalenceBuilder_.dispose(); + prevalenceBuilder_ = null; + } + firstSeenTime_ = null; + if (firstSeenTimeBuilder_ != null) { + firstSeenTimeBuilder_.dispose(); + firstSeenTimeBuilder_ = null; + } + lastSeenTime_ = null; + if (lastSeenTimeBuilder_ != null) { + lastSeenTimeBuilder_.dispose(); + lastSeenTimeBuilder_ = null; + } + location_ = null; + if (locationBuilder_ != null) { + locationBuilder_.dispose(); + locationBuilder_ = null; + } + network_ = null; + if (networkBuilder_ != null) { + networkBuilder_.dispose(); + networkBuilder_ = null; + } + asOwner_ = ""; + asn_ = 0L; + jarm_ = ""; + lastHttpsCertificate_ = null; + if (lastHttpsCertificateBuilder_ != null) { + lastHttpsCertificateBuilder_.dispose(); + lastHttpsCertificateBuilder_ = null; + } + lastHttpsCertificateDate_ = null; + if (lastHttpsCertificateDateBuilder_ != null) { + lastHttpsCertificateDateBuilder_.dispose(); + lastHttpsCertificateDateBuilder_ = null; + } + regionalInternetRegistry_ = ""; + tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + whois_ = ""; + whoisDate_ = null; + if (whoisDateBuilder_ != null) { + whoisDateBuilder_.dispose(); + whoisDateBuilder_ = null; + } + if (tunnelsBuilder_ == null) { + tunnels_ = java.util.Collections.emptyList(); + } else { + tunnels_ = null; + tunnelsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00008000); + anonymous_ = false; + artifactClient_ = null; + if (artifactClientBuilder_ != null) { + artifactClientBuilder_.dispose(); + artifactClientBuilder_ = null; + } + risks_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Artifact_descriptor; + } + + @java.lang.Override + public com.google.backstory.Artifact getDefaultInstanceForType() { + return com.google.backstory.Artifact.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Artifact build() { + com.google.backstory.Artifact result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Artifact buildPartial() { + com.google.backstory.Artifact result = new com.google.backstory.Artifact(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.Artifact result) { + if (tunnelsBuilder_ == null) { + if (((bitField0_ & 0x00008000) != 0)) { + tunnels_ = java.util.Collections.unmodifiableList(tunnels_); + bitField0_ = (bitField0_ & ~0x00008000); + } + result.tunnels_ = tunnels_; + } else { + result.tunnels_ = tunnelsBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.Artifact result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.ip_ = ip_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.prevalence_ = prevalenceBuilder_ == null ? prevalence_ : prevalenceBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.firstSeenTime_ = + firstSeenTimeBuilder_ == null ? firstSeenTime_ : firstSeenTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.lastSeenTime_ = + lastSeenTimeBuilder_ == null ? lastSeenTime_ : lastSeenTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.location_ = locationBuilder_ == null ? location_ : locationBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.network_ = networkBuilder_ == null ? network_ : networkBuilder_.build(); + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.asOwner_ = asOwner_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.asn_ = asn_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.jarm_ = jarm_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.lastHttpsCertificate_ = + lastHttpsCertificateBuilder_ == null + ? lastHttpsCertificate_ + : lastHttpsCertificateBuilder_.build(); + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.lastHttpsCertificateDate_ = + lastHttpsCertificateDateBuilder_ == null + ? lastHttpsCertificateDate_ + : lastHttpsCertificateDateBuilder_.build(); + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.regionalInternetRegistry_ = regionalInternetRegistry_; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + tags_.makeImmutable(); + result.tags_ = tags_; + } + if (((from_bitField0_ & 0x00002000) != 0)) { + result.whois_ = whois_; + } + if (((from_bitField0_ & 0x00004000) != 0)) { + result.whoisDate_ = whoisDateBuilder_ == null ? whoisDate_ : whoisDateBuilder_.build(); + to_bitField0_ |= 0x00000080; + } + if (((from_bitField0_ & 0x00010000) != 0)) { + result.anonymous_ = anonymous_; + } + if (((from_bitField0_ & 0x00020000) != 0)) { + result.artifactClient_ = + artifactClientBuilder_ == null ? artifactClient_ : artifactClientBuilder_.build(); + to_bitField0_ |= 0x00000100; + } + if (((from_bitField0_ & 0x00040000) != 0)) { + risks_.makeImmutable(); + result.risks_ = risks_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Artifact) { + return mergeFrom((com.google.backstory.Artifact) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Artifact other) { + if (other == com.google.backstory.Artifact.getDefaultInstance()) return this; + if (!other.getIp().isEmpty()) { + ip_ = other.ip_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasPrevalence()) { + mergePrevalence(other.getPrevalence()); + } + if (other.hasFirstSeenTime()) { + mergeFirstSeenTime(other.getFirstSeenTime()); + } + if (other.hasLastSeenTime()) { + mergeLastSeenTime(other.getLastSeenTime()); + } + if (other.hasLocation()) { + mergeLocation(other.getLocation()); + } + if (other.hasNetwork()) { + mergeNetwork(other.getNetwork()); + } + if (!other.getAsOwner().isEmpty()) { + asOwner_ = other.asOwner_; + bitField0_ |= 0x00000040; + onChanged(); + } + if (other.getAsn() != 0L) { + setAsn(other.getAsn()); + } + if (!other.getJarm().isEmpty()) { + jarm_ = other.jarm_; + bitField0_ |= 0x00000100; + onChanged(); + } + if (other.hasLastHttpsCertificate()) { + mergeLastHttpsCertificate(other.getLastHttpsCertificate()); + } + if (other.hasLastHttpsCertificateDate()) { + mergeLastHttpsCertificateDate(other.getLastHttpsCertificateDate()); + } + if (!other.getRegionalInternetRegistry().isEmpty()) { + regionalInternetRegistry_ = other.regionalInternetRegistry_; + bitField0_ |= 0x00000800; + onChanged(); + } + if (!other.tags_.isEmpty()) { + if (tags_.isEmpty()) { + tags_ = other.tags_; + bitField0_ |= 0x00001000; + } else { + ensureTagsIsMutable(); + tags_.addAll(other.tags_); + } + onChanged(); + } + if (!other.getWhois().isEmpty()) { + whois_ = other.whois_; + bitField0_ |= 0x00002000; + onChanged(); + } + if (other.hasWhoisDate()) { + mergeWhoisDate(other.getWhoisDate()); + } + if (tunnelsBuilder_ == null) { + if (!other.tunnels_.isEmpty()) { + if (tunnels_.isEmpty()) { + tunnels_ = other.tunnels_; + bitField0_ = (bitField0_ & ~0x00008000); + } else { + ensureTunnelsIsMutable(); + tunnels_.addAll(other.tunnels_); + } + onChanged(); + } + } else { + if (!other.tunnels_.isEmpty()) { + if (tunnelsBuilder_.isEmpty()) { + tunnelsBuilder_.dispose(); + tunnelsBuilder_ = null; + tunnels_ = other.tunnels_; + bitField0_ = (bitField0_ & ~0x00008000); + tunnelsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetTunnelsFieldBuilder() + : null; + } else { + tunnelsBuilder_.addAllMessages(other.tunnels_); + } + } + } + if (other.getAnonymous() != false) { + setAnonymous(other.getAnonymous()); + } + if (other.hasArtifactClient()) { + mergeArtifactClient(other.getArtifactClient()); + } + if (!other.risks_.isEmpty()) { + if (risks_.isEmpty()) { + risks_ = other.risks_; + bitField0_ |= 0x00040000; + } else { + ensureRisksIsMutable(); + risks_.addAll(other.risks_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + ip_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetPrevalenceFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetFirstSeenTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetLastSeenTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetLocationFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage(internalGetNetworkFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 58: + { + asOwner_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 64: + { + asn_ = input.readInt64(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 74: + { + jarm_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000100; + break; + } // case 74 + case 82: + { + input.readMessage( + internalGetLastHttpsCertificateFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000200; + break; + } // case 82 + case 90: + { + input.readMessage( + internalGetLastHttpsCertificateDateFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000400; + break; + } // case 90 + case 98: + { + regionalInternetRegistry_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000800; + break; + } // case 98 + case 106: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureTagsIsMutable(); + tags_.add(s); + break; + } // case 106 + case 114: + { + whois_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00002000; + break; + } // case 114 + case 122: + { + input.readMessage( + internalGetWhoisDateFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00004000; + break; + } // case 122 + case 130: + { + com.google.backstory.Tunnels m = + input.readMessage(com.google.backstory.Tunnels.parser(), extensionRegistry); + if (tunnelsBuilder_ == null) { + ensureTunnelsIsMutable(); + tunnels_.add(m); + } else { + tunnelsBuilder_.addMessage(m); + } + break; + } // case 130 + case 136: + { + anonymous_ = input.readBool(); + bitField0_ |= 0x00010000; + break; + } // case 136 + case 146: + { + input.readMessage( + internalGetArtifactClientFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00020000; + break; + } // case 146 + case 154: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureRisksIsMutable(); + risks_.add(s); + break; + } // case 154 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object ip_ = ""; + + /** + * + * + *
+     * IP address of the artifact.
+     * This field can be used as an entity indicator for an external destination
+     * IP entity.
+     * 
+ * + * string ip = 1; + * + * @return The ip. + */ + public java.lang.String getIp() { + java.lang.Object ref = ip_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + ip_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * IP address of the artifact.
+     * This field can be used as an entity indicator for an external destination
+     * IP entity.
+     * 
+ * + * string ip = 1; + * + * @return The bytes for ip. + */ + public com.google.protobuf.ByteString getIpBytes() { + java.lang.Object ref = ip_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + ip_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * IP address of the artifact.
+     * This field can be used as an entity indicator for an external destination
+     * IP entity.
+     * 
+ * + * string ip = 1; + * + * @param value The ip to set. + * @return This builder for chaining. + */ + public Builder setIp(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ip_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * IP address of the artifact.
+     * This field can be used as an entity indicator for an external destination
+     * IP entity.
+     * 
+ * + * string ip = 1; + * + * @return This builder for chaining. + */ + public Builder clearIp() { + ip_ = getDefaultInstance().getIp(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * IP address of the artifact.
+     * This field can be used as an entity indicator for an external destination
+     * IP entity.
+     * 
+ * + * string ip = 1; + * + * @param value The bytes for ip to set. + * @return This builder for chaining. + */ + public Builder setIpBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ip_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.backstory.Prevalence prevalence_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Prevalence, + com.google.backstory.Prevalence.Builder, + com.google.backstory.PrevalenceOrBuilder> + prevalenceBuilder_; + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + * + * @return Whether the prevalence field is set. + */ + public boolean hasPrevalence() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + * + * @return The prevalence. + */ + public com.google.backstory.Prevalence getPrevalence() { + if (prevalenceBuilder_ == null) { + return prevalence_ == null + ? com.google.backstory.Prevalence.getDefaultInstance() + : prevalence_; + } else { + return prevalenceBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + public Builder setPrevalence(com.google.backstory.Prevalence value) { + if (prevalenceBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + prevalence_ = value; + } else { + prevalenceBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + public Builder setPrevalence(com.google.backstory.Prevalence.Builder builderForValue) { + if (prevalenceBuilder_ == null) { + prevalence_ = builderForValue.build(); + } else { + prevalenceBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + public Builder mergePrevalence(com.google.backstory.Prevalence value) { + if (prevalenceBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && prevalence_ != null + && prevalence_ != com.google.backstory.Prevalence.getDefaultInstance()) { + getPrevalenceBuilder().mergeFrom(value); + } else { + prevalence_ = value; + } + } else { + prevalenceBuilder_.mergeFrom(value); + } + if (prevalence_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + public Builder clearPrevalence() { + bitField0_ = (bitField0_ & ~0x00000002); + prevalence_ = null; + if (prevalenceBuilder_ != null) { + prevalenceBuilder_.dispose(); + prevalenceBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + public com.google.backstory.Prevalence.Builder getPrevalenceBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetPrevalenceFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + public com.google.backstory.PrevalenceOrBuilder getPrevalenceOrBuilder() { + if (prevalenceBuilder_ != null) { + return prevalenceBuilder_.getMessageOrBuilder(); + } else { + return prevalence_ == null + ? com.google.backstory.Prevalence.getDefaultInstance() + : prevalence_; + } + } + + /** + * + * + *
+     * The prevalence of the artifact within the customer's environment.
+     * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Prevalence, + com.google.backstory.Prevalence.Builder, + com.google.backstory.PrevalenceOrBuilder> + internalGetPrevalenceFieldBuilder() { + if (prevalenceBuilder_ == null) { + prevalenceBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Prevalence, + com.google.backstory.Prevalence.Builder, + com.google.backstory.PrevalenceOrBuilder>( + getPrevalence(), getParentForChildren(), isClean()); + prevalence_ = null; + } + return prevalenceBuilder_; + } + + private com.google.protobuf.Timestamp firstSeenTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + firstSeenTimeBuilder_; + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + * + * @return Whether the firstSeenTime field is set. + */ + public boolean hasFirstSeenTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + * + * @return The firstSeenTime. + */ + public com.google.protobuf.Timestamp getFirstSeenTime() { + if (firstSeenTimeBuilder_ == null) { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } else { + return firstSeenTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + public Builder setFirstSeenTime(com.google.protobuf.Timestamp value) { + if (firstSeenTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + firstSeenTime_ = value; + } else { + firstSeenTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + public Builder setFirstSeenTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (firstSeenTimeBuilder_ == null) { + firstSeenTime_ = builderForValue.build(); + } else { + firstSeenTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + public Builder mergeFirstSeenTime(com.google.protobuf.Timestamp value) { + if (firstSeenTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && firstSeenTime_ != null + && firstSeenTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getFirstSeenTimeBuilder().mergeFrom(value); + } else { + firstSeenTime_ = value; + } + } else { + firstSeenTimeBuilder_.mergeFrom(value); + } + if (firstSeenTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + public Builder clearFirstSeenTime() { + bitField0_ = (bitField0_ & ~0x00000004); + firstSeenTime_ = null; + if (firstSeenTimeBuilder_ != null) { + firstSeenTimeBuilder_.dispose(); + firstSeenTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + public com.google.protobuf.Timestamp.Builder getFirstSeenTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetFirstSeenTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + public com.google.protobuf.TimestampOrBuilder getFirstSeenTimeOrBuilder() { + if (firstSeenTimeBuilder_ != null) { + return firstSeenTimeBuilder_.getMessageOrBuilder(); + } else { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } + } + + /** + * + * + *
+     * First seen timestamp of the IP in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetFirstSeenTimeFieldBuilder() { + if (firstSeenTimeBuilder_ == null) { + firstSeenTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getFirstSeenTime(), getParentForChildren(), isClean()); + firstSeenTime_ = null; + } + return firstSeenTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastSeenTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastSeenTimeBuilder_; + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + * + * @return Whether the lastSeenTime field is set. + */ + public boolean hasLastSeenTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + * + * @return The lastSeenTime. + */ + public com.google.protobuf.Timestamp getLastSeenTime() { + if (lastSeenTimeBuilder_ == null) { + return lastSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastSeenTime_; + } else { + return lastSeenTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + public Builder setLastSeenTime(com.google.protobuf.Timestamp value) { + if (lastSeenTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastSeenTime_ = value; + } else { + lastSeenTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + public Builder setLastSeenTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastSeenTimeBuilder_ == null) { + lastSeenTime_ = builderForValue.build(); + } else { + lastSeenTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + public Builder mergeLastSeenTime(com.google.protobuf.Timestamp value) { + if (lastSeenTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && lastSeenTime_ != null + && lastSeenTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastSeenTimeBuilder().mergeFrom(value); + } else { + lastSeenTime_ = value; + } + } else { + lastSeenTimeBuilder_.mergeFrom(value); + } + if (lastSeenTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + public Builder clearLastSeenTime() { + bitField0_ = (bitField0_ & ~0x00000008); + lastSeenTime_ = null; + if (lastSeenTimeBuilder_ != null) { + lastSeenTimeBuilder_.dispose(); + lastSeenTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + public com.google.protobuf.Timestamp.Builder getLastSeenTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetLastSeenTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + public com.google.protobuf.TimestampOrBuilder getLastSeenTimeOrBuilder() { + if (lastSeenTimeBuilder_ != null) { + return lastSeenTimeBuilder_.getMessageOrBuilder(); + } else { + return lastSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastSeenTime_; + } + } + + /** + * + * + *
+     * Last seen timestamp of the IP address in the customer's environment.
+     * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastSeenTimeFieldBuilder() { + if (lastSeenTimeBuilder_ == null) { + lastSeenTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastSeenTime(), getParentForChildren(), isClean()); + lastSeenTime_ = null; + } + return lastSeenTimeBuilder_; + } + + private com.google.backstory.Location location_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Location, + com.google.backstory.Location.Builder, + com.google.backstory.LocationOrBuilder> + locationBuilder_; + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + * + * @return Whether the location field is set. + */ + public boolean hasLocation() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + * + * @return The location. + */ + public com.google.backstory.Location getLocation() { + if (locationBuilder_ == null) { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } else { + return locationBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + public Builder setLocation(com.google.backstory.Location value) { + if (locationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + location_ = value; + } else { + locationBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + public Builder setLocation(com.google.backstory.Location.Builder builderForValue) { + if (locationBuilder_ == null) { + location_ = builderForValue.build(); + } else { + locationBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + public Builder mergeLocation(com.google.backstory.Location value) { + if (locationBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && location_ != null + && location_ != com.google.backstory.Location.getDefaultInstance()) { + getLocationBuilder().mergeFrom(value); + } else { + location_ = value; + } + } else { + locationBuilder_.mergeFrom(value); + } + if (location_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + public Builder clearLocation() { + bitField0_ = (bitField0_ & ~0x00000010); + location_ = null; + if (locationBuilder_ != null) { + locationBuilder_.dispose(); + locationBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + public com.google.backstory.Location.Builder getLocationBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetLocationFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + public com.google.backstory.LocationOrBuilder getLocationOrBuilder() { + if (locationBuilder_ != null) { + return locationBuilder_.getMessageOrBuilder(); + } else { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } + } + + /** + * + * + *
+     * Location of the Artifact's IP address.
+     * 
+ * + * .google.backstory.Location location = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Location, + com.google.backstory.Location.Builder, + com.google.backstory.LocationOrBuilder> + internalGetLocationFieldBuilder() { + if (locationBuilder_ == null) { + locationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Location, + com.google.backstory.Location.Builder, + com.google.backstory.LocationOrBuilder>( + getLocation(), getParentForChildren(), isClean()); + location_ = null; + } + return locationBuilder_; + } + + private com.google.backstory.Network network_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Network, + com.google.backstory.Network.Builder, + com.google.backstory.NetworkOrBuilder> + networkBuilder_; + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + * + * @return Whether the network field is set. + */ + public boolean hasNetwork() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + * + * @return The network. + */ + public com.google.backstory.Network getNetwork() { + if (networkBuilder_ == null) { + return network_ == null ? com.google.backstory.Network.getDefaultInstance() : network_; + } else { + return networkBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + public Builder setNetwork(com.google.backstory.Network value) { + if (networkBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + network_ = value; + } else { + networkBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + public Builder setNetwork(com.google.backstory.Network.Builder builderForValue) { + if (networkBuilder_ == null) { + network_ = builderForValue.build(); + } else { + networkBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + public Builder mergeNetwork(com.google.backstory.Network value) { + if (networkBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && network_ != null + && network_ != com.google.backstory.Network.getDefaultInstance()) { + getNetworkBuilder().mergeFrom(value); + } else { + network_ = value; + } + } else { + networkBuilder_.mergeFrom(value); + } + if (network_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + public Builder clearNetwork() { + bitField0_ = (bitField0_ & ~0x00000020); + network_ = null; + if (networkBuilder_ != null) { + networkBuilder_.dispose(); + networkBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + public com.google.backstory.Network.Builder getNetworkBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetNetworkFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + public com.google.backstory.NetworkOrBuilder getNetworkOrBuilder() { + if (networkBuilder_ != null) { + return networkBuilder_.getMessageOrBuilder(); + } else { + return network_ == null ? com.google.backstory.Network.getDefaultInstance() : network_; + } + } + + /** + * + * + *
+     * Network information related to the Artifact's IP address.
+     * 
+ * + * .google.backstory.Network network = 6; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Network, + com.google.backstory.Network.Builder, + com.google.backstory.NetworkOrBuilder> + internalGetNetworkFieldBuilder() { + if (networkBuilder_ == null) { + networkBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Network, + com.google.backstory.Network.Builder, + com.google.backstory.NetworkOrBuilder>( + getNetwork(), getParentForChildren(), isClean()); + network_ = null; + } + return networkBuilder_; + } + + private java.lang.Object asOwner_ = ""; + + /** + * + * + *
+     * Owner of the Autonomous System to which the IP address belongs.
+     * 
+ * + * string as_owner = 7; + * + * @return The asOwner. + */ + public java.lang.String getAsOwner() { + java.lang.Object ref = asOwner_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + asOwner_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Owner of the Autonomous System to which the IP address belongs.
+     * 
+ * + * string as_owner = 7; + * + * @return The bytes for asOwner. + */ + public com.google.protobuf.ByteString getAsOwnerBytes() { + java.lang.Object ref = asOwner_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + asOwner_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Owner of the Autonomous System to which the IP address belongs.
+     * 
+ * + * string as_owner = 7; + * + * @param value The asOwner to set. + * @return This builder for chaining. + */ + public Builder setAsOwner(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + asOwner_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Owner of the Autonomous System to which the IP address belongs.
+     * 
+ * + * string as_owner = 7; + * + * @return This builder for chaining. + */ + public Builder clearAsOwner() { + asOwner_ = getDefaultInstance().getAsOwner(); + bitField0_ = (bitField0_ & ~0x00000040); + onChanged(); + return this; + } + + /** + * + * + *
+     * Owner of the Autonomous System to which the IP address belongs.
+     * 
+ * + * string as_owner = 7; + * + * @param value The bytes for asOwner to set. + * @return This builder for chaining. + */ + public Builder setAsOwnerBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + asOwner_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + private long asn_; + + /** + * + * + *
+     * Autonomous System Number to which the IP address belongs.
+     * 
+ * + * int64 asn = 8; + * + * @return The asn. + */ + @java.lang.Override + public long getAsn() { + return asn_; + } + + /** + * + * + *
+     * Autonomous System Number to which the IP address belongs.
+     * 
+ * + * int64 asn = 8; + * + * @param value The asn to set. + * @return This builder for chaining. + */ + public Builder setAsn(long value) { + + asn_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Autonomous System Number to which the IP address belongs.
+     * 
+ * + * int64 asn = 8; + * + * @return This builder for chaining. + */ + public Builder clearAsn() { + bitField0_ = (bitField0_ & ~0x00000080); + asn_ = 0L; + onChanged(); + return this; + } + + private java.lang.Object jarm_ = ""; + + /** + * + * + *
+     * The JARM hash for the IP address.
+     * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+     * 
+ * + * string jarm = 9; + * + * @return The jarm. + */ + public java.lang.String getJarm() { + java.lang.Object ref = jarm_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jarm_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The JARM hash for the IP address.
+     * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+     * 
+ * + * string jarm = 9; + * + * @return The bytes for jarm. + */ + public com.google.protobuf.ByteString getJarmBytes() { + java.lang.Object ref = jarm_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jarm_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The JARM hash for the IP address.
+     * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+     * 
+ * + * string jarm = 9; + * + * @param value The jarm to set. + * @return This builder for chaining. + */ + public Builder setJarm(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + jarm_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * The JARM hash for the IP address.
+     * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+     * 
+ * + * string jarm = 9; + * + * @return This builder for chaining. + */ + public Builder clearJarm() { + jarm_ = getDefaultInstance().getJarm(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + return this; + } + + /** + * + * + *
+     * The JARM hash for the IP address.
+     * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+     * 
+ * + * string jarm = 9; + * + * @param value The bytes for jarm to set. + * @return This builder for chaining. + */ + public Builder setJarmBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + jarm_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + private com.google.backstory.SSLCertificate lastHttpsCertificate_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.SSLCertificate, + com.google.backstory.SSLCertificate.Builder, + com.google.backstory.SSLCertificateOrBuilder> + lastHttpsCertificateBuilder_; + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + * + * @return Whether the lastHttpsCertificate field is set. + */ + public boolean hasLastHttpsCertificate() { + return ((bitField0_ & 0x00000200) != 0); + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + * + * @return The lastHttpsCertificate. + */ + public com.google.backstory.SSLCertificate getLastHttpsCertificate() { + if (lastHttpsCertificateBuilder_ == null) { + return lastHttpsCertificate_ == null + ? com.google.backstory.SSLCertificate.getDefaultInstance() + : lastHttpsCertificate_; + } else { + return lastHttpsCertificateBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + public Builder setLastHttpsCertificate(com.google.backstory.SSLCertificate value) { + if (lastHttpsCertificateBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastHttpsCertificate_ = value; + } else { + lastHttpsCertificateBuilder_.setMessage(value); + } + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + public Builder setLastHttpsCertificate( + com.google.backstory.SSLCertificate.Builder builderForValue) { + if (lastHttpsCertificateBuilder_ == null) { + lastHttpsCertificate_ = builderForValue.build(); + } else { + lastHttpsCertificateBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + public Builder mergeLastHttpsCertificate(com.google.backstory.SSLCertificate value) { + if (lastHttpsCertificateBuilder_ == null) { + if (((bitField0_ & 0x00000200) != 0) + && lastHttpsCertificate_ != null + && lastHttpsCertificate_ != com.google.backstory.SSLCertificate.getDefaultInstance()) { + getLastHttpsCertificateBuilder().mergeFrom(value); + } else { + lastHttpsCertificate_ = value; + } + } else { + lastHttpsCertificateBuilder_.mergeFrom(value); + } + if (lastHttpsCertificate_ != null) { + bitField0_ |= 0x00000200; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + public Builder clearLastHttpsCertificate() { + bitField0_ = (bitField0_ & ~0x00000200); + lastHttpsCertificate_ = null; + if (lastHttpsCertificateBuilder_ != null) { + lastHttpsCertificateBuilder_.dispose(); + lastHttpsCertificateBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + public com.google.backstory.SSLCertificate.Builder getLastHttpsCertificateBuilder() { + bitField0_ |= 0x00000200; + onChanged(); + return internalGetLastHttpsCertificateFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + public com.google.backstory.SSLCertificateOrBuilder getLastHttpsCertificateOrBuilder() { + if (lastHttpsCertificateBuilder_ != null) { + return lastHttpsCertificateBuilder_.getMessageOrBuilder(); + } else { + return lastHttpsCertificate_ == null + ? com.google.backstory.SSLCertificate.getDefaultInstance() + : lastHttpsCertificate_; + } + } + + /** + * + * + *
+     * SSL certificate information about the IP address.
+     * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.SSLCertificate, + com.google.backstory.SSLCertificate.Builder, + com.google.backstory.SSLCertificateOrBuilder> + internalGetLastHttpsCertificateFieldBuilder() { + if (lastHttpsCertificateBuilder_ == null) { + lastHttpsCertificateBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.SSLCertificate, + com.google.backstory.SSLCertificate.Builder, + com.google.backstory.SSLCertificateOrBuilder>( + getLastHttpsCertificate(), getParentForChildren(), isClean()); + lastHttpsCertificate_ = null; + } + return lastHttpsCertificateBuilder_; + } + + private com.google.protobuf.Timestamp lastHttpsCertificateDate_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastHttpsCertificateDateBuilder_; + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + * + * @return Whether the lastHttpsCertificateDate field is set. + */ + public boolean hasLastHttpsCertificateDate() { + return ((bitField0_ & 0x00000400) != 0); + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + * + * @return The lastHttpsCertificateDate. + */ + public com.google.protobuf.Timestamp getLastHttpsCertificateDate() { + if (lastHttpsCertificateDateBuilder_ == null) { + return lastHttpsCertificateDate_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastHttpsCertificateDate_; + } else { + return lastHttpsCertificateDateBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + public Builder setLastHttpsCertificateDate(com.google.protobuf.Timestamp value) { + if (lastHttpsCertificateDateBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastHttpsCertificateDate_ = value; + } else { + lastHttpsCertificateDateBuilder_.setMessage(value); + } + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + public Builder setLastHttpsCertificateDate( + com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastHttpsCertificateDateBuilder_ == null) { + lastHttpsCertificateDate_ = builderForValue.build(); + } else { + lastHttpsCertificateDateBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + public Builder mergeLastHttpsCertificateDate(com.google.protobuf.Timestamp value) { + if (lastHttpsCertificateDateBuilder_ == null) { + if (((bitField0_ & 0x00000400) != 0) + && lastHttpsCertificateDate_ != null + && lastHttpsCertificateDate_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastHttpsCertificateDateBuilder().mergeFrom(value); + } else { + lastHttpsCertificateDate_ = value; + } + } else { + lastHttpsCertificateDateBuilder_.mergeFrom(value); + } + if (lastHttpsCertificateDate_ != null) { + bitField0_ |= 0x00000400; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + public Builder clearLastHttpsCertificateDate() { + bitField0_ = (bitField0_ & ~0x00000400); + lastHttpsCertificateDate_ = null; + if (lastHttpsCertificateDateBuilder_ != null) { + lastHttpsCertificateDateBuilder_.dispose(); + lastHttpsCertificateDateBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + public com.google.protobuf.Timestamp.Builder getLastHttpsCertificateDateBuilder() { + bitField0_ |= 0x00000400; + onChanged(); + return internalGetLastHttpsCertificateDateFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + public com.google.protobuf.TimestampOrBuilder getLastHttpsCertificateDateOrBuilder() { + if (lastHttpsCertificateDateBuilder_ != null) { + return lastHttpsCertificateDateBuilder_.getMessageOrBuilder(); + } else { + return lastHttpsCertificateDate_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastHttpsCertificateDate_; + } + } + + /** + * + * + *
+     * Most recent date for the certificate in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastHttpsCertificateDateFieldBuilder() { + if (lastHttpsCertificateDateBuilder_ == null) { + lastHttpsCertificateDateBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastHttpsCertificateDate(), getParentForChildren(), isClean()); + lastHttpsCertificateDate_ = null; + } + return lastHttpsCertificateDateBuilder_; + } + + private java.lang.Object regionalInternetRegistry_ = ""; + + /** + * + * + *
+     * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+     * 
+ * + * string regional_internet_registry = 12; + * + * @return The regionalInternetRegistry. + */ + public java.lang.String getRegionalInternetRegistry() { + java.lang.Object ref = regionalInternetRegistry_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + regionalInternetRegistry_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+     * 
+ * + * string regional_internet_registry = 12; + * + * @return The bytes for regionalInternetRegistry. + */ + public com.google.protobuf.ByteString getRegionalInternetRegistryBytes() { + java.lang.Object ref = regionalInternetRegistry_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + regionalInternetRegistry_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+     * 
+ * + * string regional_internet_registry = 12; + * + * @param value The regionalInternetRegistry to set. + * @return This builder for chaining. + */ + public Builder setRegionalInternetRegistry(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + regionalInternetRegistry_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+     * 
+ * + * string regional_internet_registry = 12; + * + * @return This builder for chaining. + */ + public Builder clearRegionalInternetRegistry() { + regionalInternetRegistry_ = getDefaultInstance().getRegionalInternetRegistry(); + bitField0_ = (bitField0_ & ~0x00000800); + onChanged(); + return this; + } + + /** + * + * + *
+     * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+     * 
+ * + * string regional_internet_registry = 12; + * + * @param value The bytes for regionalInternetRegistry to set. + * @return This builder for chaining. + */ + public Builder setRegionalInternetRegistryBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + regionalInternetRegistry_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList tags_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureTagsIsMutable() { + if (!tags_.isModifiable()) { + tags_ = new com.google.protobuf.LazyStringArrayList(tags_); + } + bitField0_ |= 0x00001000; + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @return A list containing the tags. + */ + public com.google.protobuf.ProtocolStringList getTagsList() { + tags_.makeImmutable(); + return tags_; + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @return The count of tags. + */ + public int getTagsCount() { + return tags_.size(); + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @param index The index of the element to return. + * @return The tags at the given index. + */ + public java.lang.String getTags(int index) { + return tags_.get(index); + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @param index The index of the value to return. + * @return The bytes of the tags at the given index. + */ + public com.google.protobuf.ByteString getTagsBytes(int index) { + return tags_.getByteString(index); + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @param index The index to set the value at. + * @param value The tags to set. + * @return This builder for chaining. + */ + public Builder setTags(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureTagsIsMutable(); + tags_.set(index, value); + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @param value The tags to add. + * @return This builder for chaining. + */ + public Builder addTags(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureTagsIsMutable(); + tags_.add(value); + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @param values The tags to add. + * @return This builder for chaining. + */ + public Builder addAllTags(java.lang.Iterable values) { + ensureTagsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tags_); + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @return This builder for chaining. + */ + public Builder clearTags() { + tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00001000); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identification attributes
+     * 
+ * + * repeated string tags = 13; + * + * @param value The bytes of the tags to add. + * @return This builder for chaining. + */ + public Builder addTagsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureTagsIsMutable(); + tags_.add(value); + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + private java.lang.Object whois_ = ""; + + /** + * + * + *
+     * WHOIS information as returned from the pertinent WHOIS server.
+     * 
+ * + * string whois = 14; + * + * @return The whois. + */ + public java.lang.String getWhois() { + java.lang.Object ref = whois_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + whois_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * WHOIS information as returned from the pertinent WHOIS server.
+     * 
+ * + * string whois = 14; + * + * @return The bytes for whois. + */ + public com.google.protobuf.ByteString getWhoisBytes() { + java.lang.Object ref = whois_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + whois_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * WHOIS information as returned from the pertinent WHOIS server.
+     * 
+ * + * string whois = 14; + * + * @param value The whois to set. + * @return This builder for chaining. + */ + public Builder setWhois(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + whois_ = value; + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
+     * WHOIS information as returned from the pertinent WHOIS server.
+     * 
+ * + * string whois = 14; + * + * @return This builder for chaining. + */ + public Builder clearWhois() { + whois_ = getDefaultInstance().getWhois(); + bitField0_ = (bitField0_ & ~0x00002000); + onChanged(); + return this; + } + + /** + * + * + *
+     * WHOIS information as returned from the pertinent WHOIS server.
+     * 
+ * + * string whois = 14; + * + * @param value The bytes for whois to set. + * @return This builder for chaining. + */ + public Builder setWhoisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + whois_ = value; + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp whoisDate_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + whoisDateBuilder_; + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + * + * @return Whether the whoisDate field is set. + */ + public boolean hasWhoisDate() { + return ((bitField0_ & 0x00004000) != 0); + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + * + * @return The whoisDate. + */ + public com.google.protobuf.Timestamp getWhoisDate() { + if (whoisDateBuilder_ == null) { + return whoisDate_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : whoisDate_; + } else { + return whoisDateBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + public Builder setWhoisDate(com.google.protobuf.Timestamp value) { + if (whoisDateBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + whoisDate_ = value; + } else { + whoisDateBuilder_.setMessage(value); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + public Builder setWhoisDate(com.google.protobuf.Timestamp.Builder builderForValue) { + if (whoisDateBuilder_ == null) { + whoisDate_ = builderForValue.build(); + } else { + whoisDateBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + public Builder mergeWhoisDate(com.google.protobuf.Timestamp value) { + if (whoisDateBuilder_ == null) { + if (((bitField0_ & 0x00004000) != 0) + && whoisDate_ != null + && whoisDate_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getWhoisDateBuilder().mergeFrom(value); + } else { + whoisDate_ = value; + } + } else { + whoisDateBuilder_.mergeFrom(value); + } + if (whoisDate_ != null) { + bitField0_ |= 0x00004000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + public Builder clearWhoisDate() { + bitField0_ = (bitField0_ & ~0x00004000); + whoisDate_ = null; + if (whoisDateBuilder_ != null) { + whoisDateBuilder_.dispose(); + whoisDateBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + public com.google.protobuf.Timestamp.Builder getWhoisDateBuilder() { + bitField0_ |= 0x00004000; + onChanged(); + return internalGetWhoisDateFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + public com.google.protobuf.TimestampOrBuilder getWhoisDateOrBuilder() { + if (whoisDateBuilder_ != null) { + return whoisDateBuilder_.getMessageOrBuilder(); + } else { + return whoisDate_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : whoisDate_; + } + } + + /** + * + * + *
+     * Date of the last update of the WHOIS record in VirusTotal.
+     * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetWhoisDateFieldBuilder() { + if (whoisDateBuilder_ == null) { + whoisDateBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getWhoisDate(), getParentForChildren(), isClean()); + whoisDate_ = null; + } + return whoisDateBuilder_; + } + + private java.util.List tunnels_ = + java.util.Collections.emptyList(); + + private void ensureTunnelsIsMutable() { + if (!((bitField0_ & 0x00008000) != 0)) { + tunnels_ = new java.util.ArrayList(tunnels_); + bitField0_ |= 0x00008000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Tunnels, + com.google.backstory.Tunnels.Builder, + com.google.backstory.TunnelsOrBuilder> + tunnelsBuilder_; + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public java.util.List getTunnelsList() { + if (tunnelsBuilder_ == null) { + return java.util.Collections.unmodifiableList(tunnels_); + } else { + return tunnelsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public int getTunnelsCount() { + if (tunnelsBuilder_ == null) { + return tunnels_.size(); + } else { + return tunnelsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public com.google.backstory.Tunnels getTunnels(int index) { + if (tunnelsBuilder_ == null) { + return tunnels_.get(index); + } else { + return tunnelsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder setTunnels(int index, com.google.backstory.Tunnels value) { + if (tunnelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTunnelsIsMutable(); + tunnels_.set(index, value); + onChanged(); + } else { + tunnelsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder setTunnels(int index, com.google.backstory.Tunnels.Builder builderForValue) { + if (tunnelsBuilder_ == null) { + ensureTunnelsIsMutable(); + tunnels_.set(index, builderForValue.build()); + onChanged(); + } else { + tunnelsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder addTunnels(com.google.backstory.Tunnels value) { + if (tunnelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTunnelsIsMutable(); + tunnels_.add(value); + onChanged(); + } else { + tunnelsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder addTunnels(int index, com.google.backstory.Tunnels value) { + if (tunnelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTunnelsIsMutable(); + tunnels_.add(index, value); + onChanged(); + } else { + tunnelsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder addTunnels(com.google.backstory.Tunnels.Builder builderForValue) { + if (tunnelsBuilder_ == null) { + ensureTunnelsIsMutable(); + tunnels_.add(builderForValue.build()); + onChanged(); + } else { + tunnelsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder addTunnels(int index, com.google.backstory.Tunnels.Builder builderForValue) { + if (tunnelsBuilder_ == null) { + ensureTunnelsIsMutable(); + tunnels_.add(index, builderForValue.build()); + onChanged(); + } else { + tunnelsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder addAllTunnels( + java.lang.Iterable values) { + if (tunnelsBuilder_ == null) { + ensureTunnelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tunnels_); + onChanged(); + } else { + tunnelsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder clearTunnels() { + if (tunnelsBuilder_ == null) { + tunnels_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00008000); + onChanged(); + } else { + tunnelsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public Builder removeTunnels(int index) { + if (tunnelsBuilder_ == null) { + ensureTunnelsIsMutable(); + tunnels_.remove(index); + onChanged(); + } else { + tunnelsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public com.google.backstory.Tunnels.Builder getTunnelsBuilder(int index) { + return internalGetTunnelsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public com.google.backstory.TunnelsOrBuilder getTunnelsOrBuilder(int index) { + if (tunnelsBuilder_ == null) { + return tunnels_.get(index); + } else { + return tunnelsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public java.util.List + getTunnelsOrBuilderList() { + if (tunnelsBuilder_ != null) { + return tunnelsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(tunnels_); + } + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public com.google.backstory.Tunnels.Builder addTunnelsBuilder() { + return internalGetTunnelsFieldBuilder() + .addBuilder(com.google.backstory.Tunnels.getDefaultInstance()); + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public com.google.backstory.Tunnels.Builder addTunnelsBuilder(int index) { + return internalGetTunnelsFieldBuilder() + .addBuilder(index, com.google.backstory.Tunnels.getDefaultInstance()); + } + + /** + * + * + *
+     * VPN tunnels.
+     * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + public java.util.List getTunnelsBuilderList() { + return internalGetTunnelsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Tunnels, + com.google.backstory.Tunnels.Builder, + com.google.backstory.TunnelsOrBuilder> + internalGetTunnelsFieldBuilder() { + if (tunnelsBuilder_ == null) { + tunnelsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Tunnels, + com.google.backstory.Tunnels.Builder, + com.google.backstory.TunnelsOrBuilder>( + tunnels_, ((bitField0_ & 0x00008000) != 0), getParentForChildren(), isClean()); + tunnels_ = null; + } + return tunnelsBuilder_; + } + + private boolean anonymous_; + + /** + * + * + *
+     * Whether the VPN tunnels are configured for anonymous browsing or not.
+     * 
+ * + * bool anonymous = 17; + * + * @return The anonymous. + */ + @java.lang.Override + public boolean getAnonymous() { + return anonymous_; + } + + /** + * + * + *
+     * Whether the VPN tunnels are configured for anonymous browsing or not.
+     * 
+ * + * bool anonymous = 17; + * + * @param value The anonymous to set. + * @return This builder for chaining. + */ + public Builder setAnonymous(boolean value) { + + anonymous_ = value; + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Whether the VPN tunnels are configured for anonymous browsing or not.
+     * 
+ * + * bool anonymous = 17; + * + * @return This builder for chaining. + */ + public Builder clearAnonymous() { + bitField0_ = (bitField0_ & ~0x00010000); + anonymous_ = false; + onChanged(); + return this; + } + + private com.google.backstory.ArtifactClient artifactClient_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.ArtifactClient, + com.google.backstory.ArtifactClient.Builder, + com.google.backstory.ArtifactClientOrBuilder> + artifactClientBuilder_; + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + * + * @return Whether the artifactClient field is set. + */ + public boolean hasArtifactClient() { + return ((bitField0_ & 0x00020000) != 0); + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + * + * @return The artifactClient. + */ + public com.google.backstory.ArtifactClient getArtifactClient() { + if (artifactClientBuilder_ == null) { + return artifactClient_ == null + ? com.google.backstory.ArtifactClient.getDefaultInstance() + : artifactClient_; + } else { + return artifactClientBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + public Builder setArtifactClient(com.google.backstory.ArtifactClient value) { + if (artifactClientBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + artifactClient_ = value; + } else { + artifactClientBuilder_.setMessage(value); + } + bitField0_ |= 0x00020000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + public Builder setArtifactClient(com.google.backstory.ArtifactClient.Builder builderForValue) { + if (artifactClientBuilder_ == null) { + artifactClient_ = builderForValue.build(); + } else { + artifactClientBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00020000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + public Builder mergeArtifactClient(com.google.backstory.ArtifactClient value) { + if (artifactClientBuilder_ == null) { + if (((bitField0_ & 0x00020000) != 0) + && artifactClient_ != null + && artifactClient_ != com.google.backstory.ArtifactClient.getDefaultInstance()) { + getArtifactClientBuilder().mergeFrom(value); + } else { + artifactClient_ = value; + } + } else { + artifactClientBuilder_.mergeFrom(value); + } + if (artifactClient_ != null) { + bitField0_ |= 0x00020000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + public Builder clearArtifactClient() { + bitField0_ = (bitField0_ & ~0x00020000); + artifactClient_ = null; + if (artifactClientBuilder_ != null) { + artifactClientBuilder_.dispose(); + artifactClientBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + public com.google.backstory.ArtifactClient.Builder getArtifactClientBuilder() { + bitField0_ |= 0x00020000; + onChanged(); + return internalGetArtifactClientFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + public com.google.backstory.ArtifactClientOrBuilder getArtifactClientOrBuilder() { + if (artifactClientBuilder_ != null) { + return artifactClientBuilder_.getMessageOrBuilder(); + } else { + return artifactClient_ == null + ? com.google.backstory.ArtifactClient.getDefaultInstance() + : artifactClient_; + } + } + + /** + * + * + *
+     * Entity or software accessing or utilizing network resources.
+     * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.ArtifactClient, + com.google.backstory.ArtifactClient.Builder, + com.google.backstory.ArtifactClientOrBuilder> + internalGetArtifactClientFieldBuilder() { + if (artifactClientBuilder_ == null) { + artifactClientBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.ArtifactClient, + com.google.backstory.ArtifactClient.Builder, + com.google.backstory.ArtifactClientOrBuilder>( + getArtifactClient(), getParentForChildren(), isClean()); + artifactClient_ = null; + } + return artifactClientBuilder_; + } + + private com.google.protobuf.LazyStringArrayList risks_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureRisksIsMutable() { + if (!risks_.isModifiable()) { + risks_ = new com.google.protobuf.LazyStringArrayList(risks_); + } + bitField0_ |= 0x00040000; + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @return A list containing the risks. + */ + public com.google.protobuf.ProtocolStringList getRisksList() { + risks_.makeImmutable(); + return risks_; + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @return The count of risks. + */ + public int getRisksCount() { + return risks_.size(); + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @param index The index of the element to return. + * @return The risks at the given index. + */ + public java.lang.String getRisks(int index) { + return risks_.get(index); + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @param index The index of the value to return. + * @return The bytes of the risks at the given index. + */ + public com.google.protobuf.ByteString getRisksBytes(int index) { + return risks_.getByteString(index); + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @param index The index to set the value at. + * @param value The risks to set. + * @return This builder for chaining. + */ + public Builder setRisks(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureRisksIsMutable(); + risks_.set(index, value); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @param value The risks to add. + * @return This builder for chaining. + */ + public Builder addRisks(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureRisksIsMutable(); + risks_.add(value); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @param values The risks to add. + * @return This builder for chaining. + */ + public Builder addAllRisks(java.lang.Iterable values) { + ensureRisksIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, risks_); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @return This builder for chaining. + */ + public Builder clearRisks() { + risks_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00040000); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * This field lists potential risks associated with the network activity.
+     * 
+ * + * repeated string risks = 19; + * + * @param value The bytes of the risks to add. + * @return This builder for chaining. + */ + public Builder addRisksBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureRisksIsMutable(); + risks_.add(value); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Artifact) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Artifact) + private static final com.google.backstory.Artifact DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Artifact(); + } + + public static com.google.backstory.Artifact getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Artifact parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Artifact getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/ArtifactClient.java b/java-backstory/src/main/java/com/google/backstory/ArtifactClient.java new file mode 100644 index 000000000000..1ed820924187 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/ArtifactClient.java @@ -0,0 +1,965 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Entity or software accessing or utilizing network resources.
+ * 
+ * + * Protobuf type {@code google.backstory.ArtifactClient} + */ +@com.google.protobuf.Generated +public final class ArtifactClient extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.ArtifactClient) + ArtifactClientOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "ArtifactClient"); + } + + // Use ArtifactClient.newBuilder() to construct. + private ArtifactClient(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ArtifactClient() { + behaviors_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proxies_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_ArtifactClient_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_ArtifactClient_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.ArtifactClient.class, + com.google.backstory.ArtifactClient.Builder.class); + } + + public static final int BEHAVIORS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList behaviors_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @return A list containing the behaviors. + */ + public com.google.protobuf.ProtocolStringList getBehaviorsList() { + return behaviors_; + } + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @return The count of behaviors. + */ + public int getBehaviorsCount() { + return behaviors_.size(); + } + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @param index The index of the element to return. + * @return The behaviors at the given index. + */ + public java.lang.String getBehaviors(int index) { + return behaviors_.get(index); + } + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @param index The index of the value to return. + * @return The bytes of the behaviors at the given index. + */ + public com.google.protobuf.ByteString getBehaviorsBytes(int index) { + return behaviors_.getByteString(index); + } + + public static final int PROXIES_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proxies_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @return A list containing the proxies. + */ + public com.google.protobuf.ProtocolStringList getProxiesList() { + return proxies_; + } + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @return The count of proxies. + */ + public int getProxiesCount() { + return proxies_.size(); + } + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @param index The index of the element to return. + * @return The proxies at the given index. + */ + public java.lang.String getProxies(int index) { + return proxies_.get(index); + } + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @param index The index of the value to return. + * @return The bytes of the proxies at the given index. + */ + public com.google.protobuf.ByteString getProxiesBytes(int index) { + return proxies_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < behaviors_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, behaviors_.getRaw(i)); + } + for (int i = 0; i < proxies_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, proxies_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < behaviors_.size(); i++) { + dataSize += computeStringSizeNoTag(behaviors_.getRaw(i)); + } + size += dataSize; + size += 1 * getBehaviorsList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proxies_.size(); i++) { + dataSize += computeStringSizeNoTag(proxies_.getRaw(i)); + } + size += dataSize; + size += 1 * getProxiesList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.ArtifactClient)) { + return super.equals(obj); + } + com.google.backstory.ArtifactClient other = (com.google.backstory.ArtifactClient) obj; + + if (!getBehaviorsList().equals(other.getBehaviorsList())) return false; + if (!getProxiesList().equals(other.getProxiesList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getBehaviorsCount() > 0) { + hash = (37 * hash) + BEHAVIORS_FIELD_NUMBER; + hash = (53 * hash) + getBehaviorsList().hashCode(); + } + if (getProxiesCount() > 0) { + hash = (37 * hash) + PROXIES_FIELD_NUMBER; + hash = (53 * hash) + getProxiesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.ArtifactClient parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.ArtifactClient parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.ArtifactClient parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.ArtifactClient parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.ArtifactClient parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.ArtifactClient parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.ArtifactClient parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.ArtifactClient parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.ArtifactClient parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.ArtifactClient parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.ArtifactClient parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.ArtifactClient parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.ArtifactClient prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * Protobuf type {@code google.backstory.ArtifactClient} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.ArtifactClient) + com.google.backstory.ArtifactClientOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_ArtifactClient_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_ArtifactClient_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.ArtifactClient.class, + com.google.backstory.ArtifactClient.Builder.class); + } + + // Construct using com.google.backstory.ArtifactClient.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + behaviors_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proxies_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_ArtifactClient_descriptor; + } + + @java.lang.Override + public com.google.backstory.ArtifactClient getDefaultInstanceForType() { + return com.google.backstory.ArtifactClient.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.ArtifactClient build() { + com.google.backstory.ArtifactClient result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.ArtifactClient buildPartial() { + com.google.backstory.ArtifactClient result = new com.google.backstory.ArtifactClient(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.ArtifactClient result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + behaviors_.makeImmutable(); + result.behaviors_ = behaviors_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + proxies_.makeImmutable(); + result.proxies_ = proxies_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.ArtifactClient) { + return mergeFrom((com.google.backstory.ArtifactClient) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.ArtifactClient other) { + if (other == com.google.backstory.ArtifactClient.getDefaultInstance()) return this; + if (!other.behaviors_.isEmpty()) { + if (behaviors_.isEmpty()) { + behaviors_ = other.behaviors_; + bitField0_ |= 0x00000001; + } else { + ensureBehaviorsIsMutable(); + behaviors_.addAll(other.behaviors_); + } + onChanged(); + } + if (!other.proxies_.isEmpty()) { + if (proxies_.isEmpty()) { + proxies_ = other.proxies_; + bitField0_ |= 0x00000002; + } else { + ensureProxiesIsMutable(); + proxies_.addAll(other.proxies_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureBehaviorsIsMutable(); + behaviors_.add(s); + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProxiesIsMutable(); + proxies_.add(s); + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringArrayList behaviors_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureBehaviorsIsMutable() { + if (!behaviors_.isModifiable()) { + behaviors_ = new com.google.protobuf.LazyStringArrayList(behaviors_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @return A list containing the behaviors. + */ + public com.google.protobuf.ProtocolStringList getBehaviorsList() { + behaviors_.makeImmutable(); + return behaviors_; + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @return The count of behaviors. + */ + public int getBehaviorsCount() { + return behaviors_.size(); + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @param index The index of the element to return. + * @return The behaviors at the given index. + */ + public java.lang.String getBehaviors(int index) { + return behaviors_.get(index); + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @param index The index of the value to return. + * @return The bytes of the behaviors at the given index. + */ + public com.google.protobuf.ByteString getBehaviorsBytes(int index) { + return behaviors_.getByteString(index); + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @param index The index to set the value at. + * @param value The behaviors to set. + * @return This builder for chaining. + */ + public Builder setBehaviors(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureBehaviorsIsMutable(); + behaviors_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @param value The behaviors to add. + * @return This builder for chaining. + */ + public Builder addBehaviors(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureBehaviorsIsMutable(); + behaviors_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @param values The behaviors to add. + * @return This builder for chaining. + */ + public Builder addAllBehaviors(java.lang.Iterable values) { + ensureBehaviorsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, behaviors_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @return This builder for chaining. + */ + public Builder clearBehaviors() { + behaviors_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * The behaviors of the client accessing the network.
+     * 
+ * + * repeated string behaviors = 1; + * + * @param value The bytes of the behaviors to add. + * @return This builder for chaining. + */ + public Builder addBehaviorsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureBehaviorsIsMutable(); + behaviors_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proxies_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProxiesIsMutable() { + if (!proxies_.isModifiable()) { + proxies_ = new com.google.protobuf.LazyStringArrayList(proxies_); + } + bitField0_ |= 0x00000002; + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @return A list containing the proxies. + */ + public com.google.protobuf.ProtocolStringList getProxiesList() { + proxies_.makeImmutable(); + return proxies_; + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @return The count of proxies. + */ + public int getProxiesCount() { + return proxies_.size(); + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @param index The index of the element to return. + * @return The proxies at the given index. + */ + public java.lang.String getProxies(int index) { + return proxies_.get(index); + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @param index The index of the value to return. + * @return The bytes of the proxies at the given index. + */ + public com.google.protobuf.ByteString getProxiesBytes(int index) { + return proxies_.getByteString(index); + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @param index The index to set the value at. + * @param value The proxies to set. + * @return This builder for chaining. + */ + public Builder setProxies(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProxiesIsMutable(); + proxies_.set(index, value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @param value The proxies to add. + * @return This builder for chaining. + */ + public Builder addProxies(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProxiesIsMutable(); + proxies_.add(value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @param values The proxies to add. + * @return This builder for chaining. + */ + public Builder addAllProxies(java.lang.Iterable values) { + ensureProxiesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proxies_); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @return This builder for chaining. + */ + public Builder clearProxies() { + proxies_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of proxies used by the client.
+     * 
+ * + * repeated string proxies = 2; + * + * @param value The bytes of the proxies to add. + * @return This builder for chaining. + */ + public Builder addProxiesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureProxiesIsMutable(); + proxies_.add(value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.ArtifactClient) + } + + // @@protoc_insertion_point(class_scope:google.backstory.ArtifactClient) + private static final com.google.backstory.ArtifactClient DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.ArtifactClient(); + } + + public static com.google.backstory.ArtifactClient getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ArtifactClient parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.ArtifactClient getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java new file mode 100644 index 000000000000..df59d6bb99f0 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java @@ -0,0 +1,121 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface ArtifactClientOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.ArtifactClient) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @return A list containing the behaviors. + */ + java.util.List getBehaviorsList(); + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @return The count of behaviors. + */ + int getBehaviorsCount(); + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @param index The index of the element to return. + * @return The behaviors at the given index. + */ + java.lang.String getBehaviors(int index); + + /** + * + * + *
+   * The behaviors of the client accessing the network.
+   * 
+ * + * repeated string behaviors = 1; + * + * @param index The index of the value to return. + * @return The bytes of the behaviors at the given index. + */ + com.google.protobuf.ByteString getBehaviorsBytes(int index); + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @return A list containing the proxies. + */ + java.util.List getProxiesList(); + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @return The count of proxies. + */ + int getProxiesCount(); + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @param index The index of the element to return. + * @return The proxies at the given index. + */ + java.lang.String getProxies(int index); + + /** + * + * + *
+   * The type of proxies used by the client.
+   * 
+ * + * repeated string proxies = 2; + * + * @param index The index of the value to return. + * @return The bytes of the proxies at the given index. + */ + com.google.protobuf.ByteString getProxiesBytes(int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java new file mode 100644 index 000000000000..73cba29c9976 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java @@ -0,0 +1,671 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface ArtifactOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Artifact) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * IP address of the artifact.
+   * This field can be used as an entity indicator for an external destination
+   * IP entity.
+   * 
+ * + * string ip = 1; + * + * @return The ip. + */ + java.lang.String getIp(); + + /** + * + * + *
+   * IP address of the artifact.
+   * This field can be used as an entity indicator for an external destination
+   * IP entity.
+   * 
+ * + * string ip = 1; + * + * @return The bytes for ip. + */ + com.google.protobuf.ByteString getIpBytes(); + + /** + * + * + *
+   * The prevalence of the artifact within the customer's environment.
+   * 
+ * + * .google.backstory.Prevalence prevalence = 2; + * + * @return Whether the prevalence field is set. + */ + boolean hasPrevalence(); + + /** + * + * + *
+   * The prevalence of the artifact within the customer's environment.
+   * 
+ * + * .google.backstory.Prevalence prevalence = 2; + * + * @return The prevalence. + */ + com.google.backstory.Prevalence getPrevalence(); + + /** + * + * + *
+   * The prevalence of the artifact within the customer's environment.
+   * 
+ * + * .google.backstory.Prevalence prevalence = 2; + */ + com.google.backstory.PrevalenceOrBuilder getPrevalenceOrBuilder(); + + /** + * + * + *
+   * First seen timestamp of the IP in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + * + * @return Whether the firstSeenTime field is set. + */ + boolean hasFirstSeenTime(); + + /** + * + * + *
+   * First seen timestamp of the IP in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + * + * @return The firstSeenTime. + */ + com.google.protobuf.Timestamp getFirstSeenTime(); + + /** + * + * + *
+   * First seen timestamp of the IP in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 3; + */ + com.google.protobuf.TimestampOrBuilder getFirstSeenTimeOrBuilder(); + + /** + * + * + *
+   * Last seen timestamp of the IP address in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + * + * @return Whether the lastSeenTime field is set. + */ + boolean hasLastSeenTime(); + + /** + * + * + *
+   * Last seen timestamp of the IP address in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + * + * @return The lastSeenTime. + */ + com.google.protobuf.Timestamp getLastSeenTime(); + + /** + * + * + *
+   * Last seen timestamp of the IP address in the customer's environment.
+   * 
+ * + * .google.protobuf.Timestamp last_seen_time = 4; + */ + com.google.protobuf.TimestampOrBuilder getLastSeenTimeOrBuilder(); + + /** + * + * + *
+   * Location of the Artifact's IP address.
+   * 
+ * + * .google.backstory.Location location = 5; + * + * @return Whether the location field is set. + */ + boolean hasLocation(); + + /** + * + * + *
+   * Location of the Artifact's IP address.
+   * 
+ * + * .google.backstory.Location location = 5; + * + * @return The location. + */ + com.google.backstory.Location getLocation(); + + /** + * + * + *
+   * Location of the Artifact's IP address.
+   * 
+ * + * .google.backstory.Location location = 5; + */ + com.google.backstory.LocationOrBuilder getLocationOrBuilder(); + + /** + * + * + *
+   * Network information related to the Artifact's IP address.
+   * 
+ * + * .google.backstory.Network network = 6; + * + * @return Whether the network field is set. + */ + boolean hasNetwork(); + + /** + * + * + *
+   * Network information related to the Artifact's IP address.
+   * 
+ * + * .google.backstory.Network network = 6; + * + * @return The network. + */ + com.google.backstory.Network getNetwork(); + + /** + * + * + *
+   * Network information related to the Artifact's IP address.
+   * 
+ * + * .google.backstory.Network network = 6; + */ + com.google.backstory.NetworkOrBuilder getNetworkOrBuilder(); + + /** + * + * + *
+   * Owner of the Autonomous System to which the IP address belongs.
+   * 
+ * + * string as_owner = 7; + * + * @return The asOwner. + */ + java.lang.String getAsOwner(); + + /** + * + * + *
+   * Owner of the Autonomous System to which the IP address belongs.
+   * 
+ * + * string as_owner = 7; + * + * @return The bytes for asOwner. + */ + com.google.protobuf.ByteString getAsOwnerBytes(); + + /** + * + * + *
+   * Autonomous System Number to which the IP address belongs.
+   * 
+ * + * int64 asn = 8; + * + * @return The asn. + */ + long getAsn(); + + /** + * + * + *
+   * The JARM hash for the IP address.
+   * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+   * 
+ * + * string jarm = 9; + * + * @return The jarm. + */ + java.lang.String getJarm(); + + /** + * + * + *
+   * The JARM hash for the IP address.
+   * (https://engineering.salesforce.com/easily-identify-malicious-servers-on-the-internet-with-jarm-e095edac525a).
+   * 
+ * + * string jarm = 9; + * + * @return The bytes for jarm. + */ + com.google.protobuf.ByteString getJarmBytes(); + + /** + * + * + *
+   * SSL certificate information about the IP address.
+   * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + * + * @return Whether the lastHttpsCertificate field is set. + */ + boolean hasLastHttpsCertificate(); + + /** + * + * + *
+   * SSL certificate information about the IP address.
+   * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + * + * @return The lastHttpsCertificate. + */ + com.google.backstory.SSLCertificate getLastHttpsCertificate(); + + /** + * + * + *
+   * SSL certificate information about the IP address.
+   * 
+ * + * .google.backstory.SSLCertificate last_https_certificate = 10; + */ + com.google.backstory.SSLCertificateOrBuilder getLastHttpsCertificateOrBuilder(); + + /** + * + * + *
+   * Most recent date for the certificate in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + * + * @return Whether the lastHttpsCertificateDate field is set. + */ + boolean hasLastHttpsCertificateDate(); + + /** + * + * + *
+   * Most recent date for the certificate in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + * + * @return The lastHttpsCertificateDate. + */ + com.google.protobuf.Timestamp getLastHttpsCertificateDate(); + + /** + * + * + *
+   * Most recent date for the certificate in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp last_https_certificate_date = 11; + */ + com.google.protobuf.TimestampOrBuilder getLastHttpsCertificateDateOrBuilder(); + + /** + * + * + *
+   * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+   * 
+ * + * string regional_internet_registry = 12; + * + * @return The regionalInternetRegistry. + */ + java.lang.String getRegionalInternetRegistry(); + + /** + * + * + *
+   * RIR (one of the current RIRs: AFRINIC, ARIN, APNIC, LACNIC or RIPE NCC).
+   * 
+ * + * string regional_internet_registry = 12; + * + * @return The bytes for regionalInternetRegistry. + */ + com.google.protobuf.ByteString getRegionalInternetRegistryBytes(); + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @return A list containing the tags. + */ + java.util.List getTagsList(); + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @return The count of tags. + */ + int getTagsCount(); + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @param index The index of the element to return. + * @return The tags at the given index. + */ + java.lang.String getTags(int index); + + /** + * + * + *
+   * Identification attributes
+   * 
+ * + * repeated string tags = 13; + * + * @param index The index of the value to return. + * @return The bytes of the tags at the given index. + */ + com.google.protobuf.ByteString getTagsBytes(int index); + + /** + * + * + *
+   * WHOIS information as returned from the pertinent WHOIS server.
+   * 
+ * + * string whois = 14; + * + * @return The whois. + */ + java.lang.String getWhois(); + + /** + * + * + *
+   * WHOIS information as returned from the pertinent WHOIS server.
+   * 
+ * + * string whois = 14; + * + * @return The bytes for whois. + */ + com.google.protobuf.ByteString getWhoisBytes(); + + /** + * + * + *
+   * Date of the last update of the WHOIS record in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + * + * @return Whether the whoisDate field is set. + */ + boolean hasWhoisDate(); + + /** + * + * + *
+   * Date of the last update of the WHOIS record in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + * + * @return The whoisDate. + */ + com.google.protobuf.Timestamp getWhoisDate(); + + /** + * + * + *
+   * Date of the last update of the WHOIS record in VirusTotal.
+   * 
+ * + * .google.protobuf.Timestamp whois_date = 15; + */ + com.google.protobuf.TimestampOrBuilder getWhoisDateOrBuilder(); + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + java.util.List getTunnelsList(); + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + com.google.backstory.Tunnels getTunnels(int index); + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + int getTunnelsCount(); + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + java.util.List getTunnelsOrBuilderList(); + + /** + * + * + *
+   * VPN tunnels.
+   * 
+ * + * repeated .google.backstory.Tunnels tunnels = 16; + */ + com.google.backstory.TunnelsOrBuilder getTunnelsOrBuilder(int index); + + /** + * + * + *
+   * Whether the VPN tunnels are configured for anonymous browsing or not.
+   * 
+ * + * bool anonymous = 17; + * + * @return The anonymous. + */ + boolean getAnonymous(); + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + * + * @return Whether the artifactClient field is set. + */ + boolean hasArtifactClient(); + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + * + * @return The artifactClient. + */ + com.google.backstory.ArtifactClient getArtifactClient(); + + /** + * + * + *
+   * Entity or software accessing or utilizing network resources.
+   * 
+ * + * .google.backstory.ArtifactClient artifact_client = 18; + */ + com.google.backstory.ArtifactClientOrBuilder getArtifactClientOrBuilder(); + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @return A list containing the risks. + */ + java.util.List getRisksList(); + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @return The count of risks. + */ + int getRisksCount(); + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @param index The index of the element to return. + * @return The risks at the given index. + */ + java.lang.String getRisks(int index); + + /** + * + * + *
+   * This field lists potential risks associated with the network activity.
+   * 
+ * + * repeated string risks = 19; + * + * @param index The index of the value to return. + * @return The bytes of the risks at the given index. + */ + com.google.protobuf.ByteString getRisksBytes(int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Asset.java b/java-backstory/src/main/java/com/google/backstory/Asset.java new file mode 100644 index 000000000000..fd71cad1c310 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Asset.java @@ -0,0 +1,8117 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Information about a compute asset such as a workstation, laptop, phone,
+ * virtual desktop, or VM.
+ * 
+ * + * Protobuf type {@code google.backstory.Asset} + */ +@com.google.protobuf.Generated +public final class Asset extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Asset) + AssetOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Asset"); + } + + // Use Asset.newBuilder() to construct. + private Asset(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Asset() { + productObjectId_ = ""; + hostname_ = ""; + assetId_ = ""; + ip_ = com.google.protobuf.LazyStringArrayList.emptyList(); + mac_ = com.google.protobuf.LazyStringArrayList.emptyList(); + natIp_ = com.google.protobuf.LazyStringArrayList.emptyList(); + hardware_ = java.util.Collections.emptyList(); + software_ = java.util.Collections.emptyList(); + category_ = ""; + type_ = 0; + networkDomain_ = ""; + labels_ = java.util.Collections.emptyList(); + deploymentStatus_ = 0; + vulnerabilities_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Asset_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Asset_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Asset.class, com.google.backstory.Asset.Builder.class); + } + + /** + * + * + *
+   * The role type of the asset.
+   * 
+ * + * Protobuf enum {@code google.backstory.Asset.AssetType} + */ + public enum AssetType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified asset role.
+     * 
+ * + * ROLE_UNSPECIFIED = 0; + */ + ROLE_UNSPECIFIED(0), + /** + * + * + *
+     * A workstation or desktop.
+     * 
+ * + * WORKSTATION = 1; + */ + WORKSTATION(1), + /** + * + * + *
+     * A laptop computer.
+     * 
+ * + * LAPTOP = 2; + */ + LAPTOP(2), + /** + * + * + *
+     * An IOT asset.
+     * 
+ * + * IOT = 3; + */ + IOT(3), + /** + * + * + *
+     * A network attached storage device.
+     * 
+ * + * NETWORK_ATTACHED_STORAGE = 4; + */ + NETWORK_ATTACHED_STORAGE(4), + /** + * + * + *
+     * A printer.
+     * 
+ * + * PRINTER = 5; + */ + PRINTER(5), + /** + * + * + *
+     * A scanner.
+     * 
+ * + * SCANNER = 6; + */ + SCANNER(6), + /** + * + * + *
+     * A server.
+     * 
+ * + * SERVER = 7; + */ + SERVER(7), + /** + * + * + *
+     * A tape library device.
+     * 
+ * + * TAPE_LIBRARY = 8; + */ + TAPE_LIBRARY(8), + /** + * + * + *
+     * A mobile device such as a mobile phone or PDA.
+     * 
+ * + * MOBILE = 9; + */ + MOBILE(9), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AssetType"); + } + + /** + * + * + *
+     * Unspecified asset role.
+     * 
+ * + * ROLE_UNSPECIFIED = 0; + */ + public static final int ROLE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * A workstation or desktop.
+     * 
+ * + * WORKSTATION = 1; + */ + public static final int WORKSTATION_VALUE = 1; + + /** + * + * + *
+     * A laptop computer.
+     * 
+ * + * LAPTOP = 2; + */ + public static final int LAPTOP_VALUE = 2; + + /** + * + * + *
+     * An IOT asset.
+     * 
+ * + * IOT = 3; + */ + public static final int IOT_VALUE = 3; + + /** + * + * + *
+     * A network attached storage device.
+     * 
+ * + * NETWORK_ATTACHED_STORAGE = 4; + */ + public static final int NETWORK_ATTACHED_STORAGE_VALUE = 4; + + /** + * + * + *
+     * A printer.
+     * 
+ * + * PRINTER = 5; + */ + public static final int PRINTER_VALUE = 5; + + /** + * + * + *
+     * A scanner.
+     * 
+ * + * SCANNER = 6; + */ + public static final int SCANNER_VALUE = 6; + + /** + * + * + *
+     * A server.
+     * 
+ * + * SERVER = 7; + */ + public static final int SERVER_VALUE = 7; + + /** + * + * + *
+     * A tape library device.
+     * 
+ * + * TAPE_LIBRARY = 8; + */ + public static final int TAPE_LIBRARY_VALUE = 8; + + /** + * + * + *
+     * A mobile device such as a mobile phone or PDA.
+     * 
+ * + * MOBILE = 9; + */ + public static final int MOBILE_VALUE = 9; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AssetType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AssetType forNumber(int value) { + switch (value) { + case 0: + return ROLE_UNSPECIFIED; + case 1: + return WORKSTATION; + case 2: + return LAPTOP; + case 3: + return IOT; + case 4: + return NETWORK_ATTACHED_STORAGE; + case 5: + return PRINTER; + case 6: + return SCANNER; + case 7: + return SERVER; + case 8: + return TAPE_LIBRARY; + case 9: + return MOBILE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AssetType findValueByNumber(int number) { + return AssetType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Asset.getDescriptor().getEnumTypes().get(0); + } + + private static final AssetType[] VALUES = values(); + + public static AssetType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AssetType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Asset.AssetType) + } + + /** + * + * + *
+   * Deployment status states.
+   * 
+ * + * Protobuf enum {@code google.backstory.Asset.DeploymentStatus} + */ + public enum DeploymentStatus implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified deployment status.
+     * 
+ * + * DEPLOYMENT_STATUS_UNSPECIFIED = 0; + */ + DEPLOYMENT_STATUS_UNSPECIFIED(0), + /** + * + * + *
+     * Asset is active, functional and deployed.
+     * 
+ * + * ACTIVE = 1; + */ + ACTIVE(1), + /** + * + * + *
+     * Asset is pending decommission and no longer deployed.
+     * 
+ * + * PENDING_DECOMISSION = 2; + */ + PENDING_DECOMISSION(2), + /** + * + * + *
+     * Asset is decommissioned.
+     * 
+ * + * DECOMISSIONED = 3; + */ + DECOMISSIONED(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DeploymentStatus"); + } + + /** + * + * + *
+     * Unspecified deployment status.
+     * 
+ * + * DEPLOYMENT_STATUS_UNSPECIFIED = 0; + */ + public static final int DEPLOYMENT_STATUS_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Asset is active, functional and deployed.
+     * 
+ * + * ACTIVE = 1; + */ + public static final int ACTIVE_VALUE = 1; + + /** + * + * + *
+     * Asset is pending decommission and no longer deployed.
+     * 
+ * + * PENDING_DECOMISSION = 2; + */ + public static final int PENDING_DECOMISSION_VALUE = 2; + + /** + * + * + *
+     * Asset is decommissioned.
+     * 
+ * + * DECOMISSIONED = 3; + */ + public static final int DECOMISSIONED_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DeploymentStatus valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static DeploymentStatus forNumber(int value) { + switch (value) { + case 0: + return DEPLOYMENT_STATUS_UNSPECIFIED; + case 1: + return ACTIVE; + case 2: + return PENDING_DECOMISSION; + case 3: + return DECOMISSIONED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public DeploymentStatus findValueByNumber(int number) { + return DeploymentStatus.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Asset.getDescriptor().getEnumTypes().get(1); + } + + private static final DeploymentStatus[] VALUES = values(); + + public static DeploymentStatus valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private DeploymentStatus(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Asset.DeploymentStatus) + } + + private int bitField0_; + public static final int PRODUCT_OBJECT_ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object productObjectId_ = ""; + + /** + * + * + *
+   * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+   * similar).
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string product_object_id = 1; + * + * @return The productObjectId. + */ + @java.lang.Override + public java.lang.String getProductObjectId() { + java.lang.Object ref = productObjectId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + productObjectId_ = s; + return s; + } + } + + /** + * + * + *
+   * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+   * similar).
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string product_object_id = 1; + * + * @return The bytes for productObjectId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getProductObjectIdBytes() { + java.lang.Object ref = productObjectId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + productObjectId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int HOSTNAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object hostname_ = ""; + + /** + * + * + *
+   * Asset hostname or domain name field.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string hostname = 2; + * + * @return The hostname. + */ + @java.lang.Override + public java.lang.String getHostname() { + java.lang.Object ref = hostname_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + hostname_ = s; + return s; + } + } + + /** + * + * + *
+   * Asset hostname or domain name field.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string hostname = 2; + * + * @return The bytes for hostname. + */ + @java.lang.Override + public com.google.protobuf.ByteString getHostnameBytes() { + java.lang.Object ref = hostname_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + hostname_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ASSET_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object assetId_ = ""; + + /** + * + * + *
+   * The asset ID. Value must contain the ':' character. For example,
+   * cs:abcdd23434.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string asset_id = 3; + * + * @return The assetId. + */ + @java.lang.Override + public java.lang.String getAssetId() { + java.lang.Object ref = assetId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + assetId_ = s; + return s; + } + } + + /** + * + * + *
+   * The asset ID. Value must contain the ':' character. For example,
+   * cs:abcdd23434.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string asset_id = 3; + * + * @return The bytes for assetId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAssetIdBytes() { + java.lang.Object ref = assetId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + assetId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int IP_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList ip_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @return A list containing the ip. + */ + public com.google.protobuf.ProtocolStringList getIpList() { + return ip_; + } + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @return The count of ip. + */ + public int getIpCount() { + return ip_.size(); + } + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @param index The index of the element to return. + * @return The ip at the given index. + */ + public java.lang.String getIp(int index) { + return ip_.get(index); + } + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @param index The index of the value to return. + * @return The bytes of the ip at the given index. + */ + public com.google.protobuf.ByteString getIpBytes(int index) { + return ip_.getByteString(index); + } + + public static final int MAC_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList mac_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @return A list containing the mac. + */ + public com.google.protobuf.ProtocolStringList getMacList() { + return mac_; + } + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @return The count of mac. + */ + public int getMacCount() { + return mac_.size(); + } + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @param index The index of the element to return. + * @return The mac at the given index. + */ + public java.lang.String getMac(int index) { + return mac_.get(index); + } + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @param index The index of the value to return. + * @return The bytes of the mac at the given index. + */ + public com.google.protobuf.ByteString getMacBytes(int index) { + return mac_.getByteString(index); + } + + public static final int NAT_IP_FIELD_NUMBER = 22; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList natIp_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @return A list containing the natIp. + */ + public com.google.protobuf.ProtocolStringList getNatIpList() { + return natIp_; + } + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @return The count of natIp. + */ + public int getNatIpCount() { + return natIp_.size(); + } + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index of the element to return. + * @return The natIp at the given index. + */ + public java.lang.String getNatIp(int index) { + return natIp_.get(index); + } + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index of the value to return. + * @return The bytes of the natIp at the given index. + */ + public com.google.protobuf.ByteString getNatIpBytes(int index) { + return natIp_.getByteString(index); + } + + public static final int FIRST_SEEN_TIME_FIELD_NUMBER = 23; + private com.google.protobuf.Timestamp firstSeenTime_; + + /** + * + * + *
+   * The first observed time for an asset.
+   * The value is calculated on the basis of the
+   * first time the identifier was observed.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + * + * @return Whether the firstSeenTime field is set. + */ + @java.lang.Override + public boolean hasFirstSeenTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The first observed time for an asset.
+   * The value is calculated on the basis of the
+   * first time the identifier was observed.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + * + * @return The firstSeenTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getFirstSeenTime() { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } + + /** + * + * + *
+   * The first observed time for an asset.
+   * The value is calculated on the basis of the
+   * first time the identifier was observed.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getFirstSeenTimeOrBuilder() { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } + + public static final int HARDWARE_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private java.util.List hardware_; + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + @java.lang.Override + public java.util.List getHardwareList() { + return hardware_; + } + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + @java.lang.Override + public java.util.List + getHardwareOrBuilderList() { + return hardware_; + } + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + @java.lang.Override + public int getHardwareCount() { + return hardware_.size(); + } + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + @java.lang.Override + public com.google.backstory.Hardware getHardware(int index) { + return hardware_.get(index); + } + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + @java.lang.Override + public com.google.backstory.HardwareOrBuilder getHardwareOrBuilder(int index) { + return hardware_.get(index); + } + + public static final int PLATFORM_SOFTWARE_FIELD_NUMBER = 7; + private com.google.backstory.PlatformSoftware platformSoftware_; + + /** + * + * + *
+   * The asset operating system platform software.
+   * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + * + * @return Whether the platformSoftware field is set. + */ + @java.lang.Override + public boolean hasPlatformSoftware() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The asset operating system platform software.
+   * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + * + * @return The platformSoftware. + */ + @java.lang.Override + public com.google.backstory.PlatformSoftware getPlatformSoftware() { + return platformSoftware_ == null + ? com.google.backstory.PlatformSoftware.getDefaultInstance() + : platformSoftware_; + } + + /** + * + * + *
+   * The asset operating system platform software.
+   * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + @java.lang.Override + public com.google.backstory.PlatformSoftwareOrBuilder getPlatformSoftwareOrBuilder() { + return platformSoftware_ == null + ? com.google.backstory.PlatformSoftware.getDefaultInstance() + : platformSoftware_; + } + + public static final int SOFTWARE_FIELD_NUMBER = 17; + + @SuppressWarnings("serial") + private java.util.List software_; + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + @java.lang.Override + public java.util.List getSoftwareList() { + return software_; + } + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + @java.lang.Override + public java.util.List + getSoftwareOrBuilderList() { + return software_; + } + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + @java.lang.Override + public int getSoftwareCount() { + return software_.size(); + } + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + @java.lang.Override + public com.google.backstory.Software getSoftware(int index) { + return software_.get(index); + } + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + @java.lang.Override + public com.google.backstory.SoftwareOrBuilder getSoftwareOrBuilder(int index) { + return software_.get(index); + } + + public static final int LOCATION_FIELD_NUMBER = 8; + private com.google.backstory.Location location_; + + /** + * + * + *
+   * Location of the asset.
+   * 
+ * + * .google.backstory.Location location = 8; + * + * @return Whether the location field is set. + */ + @java.lang.Override + public boolean hasLocation() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Location of the asset.
+   * 
+ * + * .google.backstory.Location location = 8; + * + * @return The location. + */ + @java.lang.Override + public com.google.backstory.Location getLocation() { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } + + /** + * + * + *
+   * Location of the asset.
+   * 
+ * + * .google.backstory.Location location = 8; + */ + @java.lang.Override + public com.google.backstory.LocationOrBuilder getLocationOrBuilder() { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } + + public static final int CATEGORY_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private volatile java.lang.Object category_ = ""; + + /** + * + * + *
+   * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+   * 
+ * + * string category = 9; + * + * @return The category. + */ + @java.lang.Override + public java.lang.String getCategory() { + java.lang.Object ref = category_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + category_ = s; + return s; + } + } + + /** + * + * + *
+   * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+   * 
+ * + * string category = 9; + * + * @return The bytes for category. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCategoryBytes() { + java.lang.Object ref = category_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + category_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TYPE_FIELD_NUMBER = 18; + private int type_ = 0; + + /** + * + * + *
+   * The type of the asset (e.g. workstation or laptop or server).
+   * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+   * The type of the asset (e.g. workstation or laptop or server).
+   * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return The type. + */ + @java.lang.Override + public com.google.backstory.Asset.AssetType getType() { + com.google.backstory.Asset.AssetType result = + com.google.backstory.Asset.AssetType.forNumber(type_); + return result == null ? com.google.backstory.Asset.AssetType.UNRECOGNIZED : result; + } + + public static final int NETWORK_DOMAIN_FIELD_NUMBER = 10; + + @SuppressWarnings("serial") + private volatile java.lang.Object networkDomain_ = ""; + + /** + * + * + *
+   * The network domain of the asset (e.g. "corp.acme.com")
+   * 
+ * + * string network_domain = 10; + * + * @return The networkDomain. + */ + @java.lang.Override + public java.lang.String getNetworkDomain() { + java.lang.Object ref = networkDomain_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + networkDomain_ = s; + return s; + } + } + + /** + * + * + *
+   * The network domain of the asset (e.g. "corp.acme.com")
+   * 
+ * + * string network_domain = 10; + * + * @return The bytes for networkDomain. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNetworkDomainBytes() { + java.lang.Object ref = networkDomain_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + networkDomain_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATION_TIME_FIELD_NUMBER = 11; + private com.google.protobuf.Timestamp creationTime_; + + /** + * + * + *
+   * Time the asset was created or provisioned.
+   * Deprecate: creation_time should be populated in Attribute as generic
+   * metadata.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + * + * @deprecated google.backstory.Asset.creation_time is deprecated. See backstory/udm.proto;l=4670 + * @return Whether the creationTime field is set. + */ + @java.lang.Override + @java.lang.Deprecated + public boolean hasCreationTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+   * Time the asset was created or provisioned.
+   * Deprecate: creation_time should be populated in Attribute as generic
+   * metadata.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + * + * @deprecated google.backstory.Asset.creation_time is deprecated. See backstory/udm.proto;l=4670 + * @return The creationTime. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.protobuf.Timestamp getCreationTime() { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } + + /** + * + * + *
+   * Time the asset was created or provisioned.
+   * Deprecate: creation_time should be populated in Attribute as generic
+   * metadata.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.protobuf.TimestampOrBuilder getCreationTimeOrBuilder() { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } + + public static final int FIRST_DISCOVER_TIME_FIELD_NUMBER = 12; + private com.google.protobuf.Timestamp firstDiscoverTime_; + + /** + * + * + *
+   * Time the asset was first discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + * + * @return Whether the firstDiscoverTime field is set. + */ + @java.lang.Override + public boolean hasFirstDiscoverTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+   * Time the asset was first discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + * + * @return The firstDiscoverTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getFirstDiscoverTime() { + return firstDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstDiscoverTime_; + } + + /** + * + * + *
+   * Time the asset was first discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getFirstDiscoverTimeOrBuilder() { + return firstDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstDiscoverTime_; + } + + public static final int LAST_DISCOVER_TIME_FIELD_NUMBER = 13; + private com.google.protobuf.Timestamp lastDiscoverTime_; + + /** + * + * + *
+   * Time the asset was last discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + * + * @return Whether the lastDiscoverTime field is set. + */ + @java.lang.Override + public boolean hasLastDiscoverTime() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+   * Time the asset was last discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + * + * @return The lastDiscoverTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastDiscoverTime() { + return lastDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastDiscoverTime_; + } + + /** + * + * + *
+   * Time the asset was last discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastDiscoverTimeOrBuilder() { + return lastDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastDiscoverTime_; + } + + public static final int SYSTEM_LAST_UPDATE_TIME_FIELD_NUMBER = 14; + private com.google.protobuf.Timestamp systemLastUpdateTime_; + + /** + * + * + *
+   * Time the asset system or OS was last updated.
+   * For all other operations that are not system updates (such as resizing a
+   * VM), use Attribute.last_update_time.
+   * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + * + * @return Whether the systemLastUpdateTime field is set. + */ + @java.lang.Override + public boolean hasSystemLastUpdateTime() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+   * Time the asset system or OS was last updated.
+   * For all other operations that are not system updates (such as resizing a
+   * VM), use Attribute.last_update_time.
+   * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + * + * @return The systemLastUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getSystemLastUpdateTime() { + return systemLastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : systemLastUpdateTime_; + } + + /** + * + * + *
+   * Time the asset system or OS was last updated.
+   * For all other operations that are not system updates (such as resizing a
+   * VM), use Attribute.last_update_time.
+   * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getSystemLastUpdateTimeOrBuilder() { + return systemLastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : systemLastUpdateTime_; + } + + public static final int LAST_BOOT_TIME_FIELD_NUMBER = 15; + private com.google.protobuf.Timestamp lastBootTime_; + + /** + * + * + *
+   * Time the asset was last boot started.
+   * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + * + * @return Whether the lastBootTime field is set. + */ + @java.lang.Override + public boolean hasLastBootTime() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
+   * Time the asset was last boot started.
+   * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + * + * @return The lastBootTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastBootTime() { + return lastBootTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastBootTime_; + } + + /** + * + * + *
+   * Time the asset was last boot started.
+   * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastBootTimeOrBuilder() { + return lastBootTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastBootTime_; + } + + public static final int LABELS_FIELD_NUMBER = 16; + + @SuppressWarnings("serial") + private java.util.List labels_; + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public java.util.List getLabelsList() { + return labels_; + } + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public java.util.List getLabelsOrBuilderList() { + return labels_; + } + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public int getLabelsCount() { + return labels_.size(); + } + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.backstory.Label getLabels(int index) { + return labels_.get(index); + } + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.backstory.LabelOrBuilder getLabelsOrBuilder(int index) { + return labels_.get(index); + } + + public static final int DEPLOYMENT_STATUS_FIELD_NUMBER = 19; + private int deploymentStatus_ = 0; + + /** + * + * + *
+   * The deployment status of the asset for device lifecycle purposes.
+   * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return The enum numeric value on the wire for deploymentStatus. + */ + @java.lang.Override + public int getDeploymentStatusValue() { + return deploymentStatus_; + } + + /** + * + * + *
+   * The deployment status of the asset for device lifecycle purposes.
+   * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return The deploymentStatus. + */ + @java.lang.Override + public com.google.backstory.Asset.DeploymentStatus getDeploymentStatus() { + com.google.backstory.Asset.DeploymentStatus result = + com.google.backstory.Asset.DeploymentStatus.forNumber(deploymentStatus_); + return result == null ? com.google.backstory.Asset.DeploymentStatus.UNRECOGNIZED : result; + } + + public static final int VULNERABILITIES_FIELD_NUMBER = 21; + + @SuppressWarnings("serial") + private java.util.List vulnerabilities_; + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + @java.lang.Override + public java.util.List getVulnerabilitiesList() { + return vulnerabilities_; + } + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + @java.lang.Override + public java.util.List + getVulnerabilitiesOrBuilderList() { + return vulnerabilities_; + } + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + @java.lang.Override + public int getVulnerabilitiesCount() { + return vulnerabilities_.size(); + } + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + @java.lang.Override + public com.google.backstory.Vulnerability getVulnerabilities(int index) { + return vulnerabilities_.get(index); + } + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + @java.lang.Override + public com.google.backstory.VulnerabilityOrBuilder getVulnerabilitiesOrBuilder(int index) { + return vulnerabilities_.get(index); + } + + public static final int ATTRIBUTE_FIELD_NUMBER = 20; + private com.google.backstory.Attribute attribute_; + + /** + * + * + *
+   * Generic entity metadata attributes of the asset.
+   * 
+ * + * .google.backstory.Attribute attribute = 20; + * + * @return Whether the attribute field is set. + */ + @java.lang.Override + public boolean hasAttribute() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+   * Generic entity metadata attributes of the asset.
+   * 
+ * + * .google.backstory.Attribute attribute = 20; + * + * @return The attribute. + */ + @java.lang.Override + public com.google.backstory.Attribute getAttribute() { + return attribute_ == null ? com.google.backstory.Attribute.getDefaultInstance() : attribute_; + } + + /** + * + * + *
+   * Generic entity metadata attributes of the asset.
+   * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + @java.lang.Override + public com.google.backstory.AttributeOrBuilder getAttributeOrBuilder() { + return attribute_ == null ? com.google.backstory.Attribute.getDefaultInstance() : attribute_; + } + + public static final int WMI_PERSISTENCE_ITEM_FIELD_NUMBER = 24; + private com.google.backstory.WmiPersistenceItem wmiPersistenceItem_; + + /** + * + * + *
+   * Information about a WMI persistence item.
+   * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + * + * @return Whether the wmiPersistenceItem field is set. + */ + @java.lang.Override + public boolean hasWmiPersistenceItem() { + return ((bitField0_ & 0x00000200) != 0); + } + + /** + * + * + *
+   * Information about a WMI persistence item.
+   * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + * + * @return The wmiPersistenceItem. + */ + @java.lang.Override + public com.google.backstory.WmiPersistenceItem getWmiPersistenceItem() { + return wmiPersistenceItem_ == null + ? com.google.backstory.WmiPersistenceItem.getDefaultInstance() + : wmiPersistenceItem_; + } + + /** + * + * + *
+   * Information about a WMI persistence item.
+   * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + @java.lang.Override + public com.google.backstory.WmiPersistenceItemOrBuilder getWmiPersistenceItemOrBuilder() { + return wmiPersistenceItem_ == null + ? com.google.backstory.WmiPersistenceItem.getDefaultInstance() + : wmiPersistenceItem_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(productObjectId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, productObjectId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(hostname_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, hostname_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(assetId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, assetId_); + } + for (int i = 0; i < ip_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, ip_.getRaw(i)); + } + for (int i = 0; i < mac_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, mac_.getRaw(i)); + } + for (int i = 0; i < hardware_.size(); i++) { + output.writeMessage(6, hardware_.get(i)); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(7, getPlatformSoftware()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(8, getLocation()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(category_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 9, category_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(networkDomain_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 10, networkDomain_); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(11, getCreationTime()); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(12, getFirstDiscoverTime()); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeMessage(13, getLastDiscoverTime()); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeMessage(14, getSystemLastUpdateTime()); + } + if (((bitField0_ & 0x00000080) != 0)) { + output.writeMessage(15, getLastBootTime()); + } + for (int i = 0; i < labels_.size(); i++) { + output.writeMessage(16, labels_.get(i)); + } + for (int i = 0; i < software_.size(); i++) { + output.writeMessage(17, software_.get(i)); + } + if (type_ != com.google.backstory.Asset.AssetType.ROLE_UNSPECIFIED.getNumber()) { + output.writeEnum(18, type_); + } + if (deploymentStatus_ + != com.google.backstory.Asset.DeploymentStatus.DEPLOYMENT_STATUS_UNSPECIFIED.getNumber()) { + output.writeEnum(19, deploymentStatus_); + } + if (((bitField0_ & 0x00000100) != 0)) { + output.writeMessage(20, getAttribute()); + } + for (int i = 0; i < vulnerabilities_.size(); i++) { + output.writeMessage(21, vulnerabilities_.get(i)); + } + for (int i = 0; i < natIp_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 22, natIp_.getRaw(i)); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(23, getFirstSeenTime()); + } + if (((bitField0_ & 0x00000200) != 0)) { + output.writeMessage(24, getWmiPersistenceItem()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(productObjectId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, productObjectId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(hostname_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, hostname_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(assetId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, assetId_); + } + { + int dataSize = 0; + for (int i = 0; i < ip_.size(); i++) { + dataSize += computeStringSizeNoTag(ip_.getRaw(i)); + } + size += dataSize; + size += 1 * getIpList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < mac_.size(); i++) { + dataSize += computeStringSizeNoTag(mac_.getRaw(i)); + } + size += dataSize; + size += 1 * getMacList().size(); + } + for (int i = 0; i < hardware_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, hardware_.get(i)); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getPlatformSoftware()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getLocation()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(category_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(9, category_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(networkDomain_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(10, networkDomain_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getCreationTime()); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, getFirstDiscoverTime()); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(13, getLastDiscoverTime()); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(14, getSystemLastUpdateTime()); + } + if (((bitField0_ & 0x00000080) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, getLastBootTime()); + } + for (int i = 0; i < labels_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(16, labels_.get(i)); + } + for (int i = 0; i < software_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(17, software_.get(i)); + } + if (type_ != com.google.backstory.Asset.AssetType.ROLE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(18, type_); + } + if (deploymentStatus_ + != com.google.backstory.Asset.DeploymentStatus.DEPLOYMENT_STATUS_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(19, deploymentStatus_); + } + if (((bitField0_ & 0x00000100) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(20, getAttribute()); + } + for (int i = 0; i < vulnerabilities_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(21, vulnerabilities_.get(i)); + } + { + int dataSize = 0; + for (int i = 0; i < natIp_.size(); i++) { + dataSize += computeStringSizeNoTag(natIp_.getRaw(i)); + } + size += dataSize; + size += 2 * getNatIpList().size(); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(23, getFirstSeenTime()); + } + if (((bitField0_ & 0x00000200) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(24, getWmiPersistenceItem()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Asset)) { + return super.equals(obj); + } + com.google.backstory.Asset other = (com.google.backstory.Asset) obj; + + if (!getProductObjectId().equals(other.getProductObjectId())) return false; + if (!getHostname().equals(other.getHostname())) return false; + if (!getAssetId().equals(other.getAssetId())) return false; + if (!getIpList().equals(other.getIpList())) return false; + if (!getMacList().equals(other.getMacList())) return false; + if (!getNatIpList().equals(other.getNatIpList())) return false; + if (hasFirstSeenTime() != other.hasFirstSeenTime()) return false; + if (hasFirstSeenTime()) { + if (!getFirstSeenTime().equals(other.getFirstSeenTime())) return false; + } + if (!getHardwareList().equals(other.getHardwareList())) return false; + if (hasPlatformSoftware() != other.hasPlatformSoftware()) return false; + if (hasPlatformSoftware()) { + if (!getPlatformSoftware().equals(other.getPlatformSoftware())) return false; + } + if (!getSoftwareList().equals(other.getSoftwareList())) return false; + if (hasLocation() != other.hasLocation()) return false; + if (hasLocation()) { + if (!getLocation().equals(other.getLocation())) return false; + } + if (!getCategory().equals(other.getCategory())) return false; + if (type_ != other.type_) return false; + if (!getNetworkDomain().equals(other.getNetworkDomain())) return false; + if (hasCreationTime() != other.hasCreationTime()) return false; + if (hasCreationTime()) { + if (!getCreationTime().equals(other.getCreationTime())) return false; + } + if (hasFirstDiscoverTime() != other.hasFirstDiscoverTime()) return false; + if (hasFirstDiscoverTime()) { + if (!getFirstDiscoverTime().equals(other.getFirstDiscoverTime())) return false; + } + if (hasLastDiscoverTime() != other.hasLastDiscoverTime()) return false; + if (hasLastDiscoverTime()) { + if (!getLastDiscoverTime().equals(other.getLastDiscoverTime())) return false; + } + if (hasSystemLastUpdateTime() != other.hasSystemLastUpdateTime()) return false; + if (hasSystemLastUpdateTime()) { + if (!getSystemLastUpdateTime().equals(other.getSystemLastUpdateTime())) return false; + } + if (hasLastBootTime() != other.hasLastBootTime()) return false; + if (hasLastBootTime()) { + if (!getLastBootTime().equals(other.getLastBootTime())) return false; + } + if (!getLabelsList().equals(other.getLabelsList())) return false; + if (deploymentStatus_ != other.deploymentStatus_) return false; + if (!getVulnerabilitiesList().equals(other.getVulnerabilitiesList())) return false; + if (hasAttribute() != other.hasAttribute()) return false; + if (hasAttribute()) { + if (!getAttribute().equals(other.getAttribute())) return false; + } + if (hasWmiPersistenceItem() != other.hasWmiPersistenceItem()) return false; + if (hasWmiPersistenceItem()) { + if (!getWmiPersistenceItem().equals(other.getWmiPersistenceItem())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PRODUCT_OBJECT_ID_FIELD_NUMBER; + hash = (53 * hash) + getProductObjectId().hashCode(); + hash = (37 * hash) + HOSTNAME_FIELD_NUMBER; + hash = (53 * hash) + getHostname().hashCode(); + hash = (37 * hash) + ASSET_ID_FIELD_NUMBER; + hash = (53 * hash) + getAssetId().hashCode(); + if (getIpCount() > 0) { + hash = (37 * hash) + IP_FIELD_NUMBER; + hash = (53 * hash) + getIpList().hashCode(); + } + if (getMacCount() > 0) { + hash = (37 * hash) + MAC_FIELD_NUMBER; + hash = (53 * hash) + getMacList().hashCode(); + } + if (getNatIpCount() > 0) { + hash = (37 * hash) + NAT_IP_FIELD_NUMBER; + hash = (53 * hash) + getNatIpList().hashCode(); + } + if (hasFirstSeenTime()) { + hash = (37 * hash) + FIRST_SEEN_TIME_FIELD_NUMBER; + hash = (53 * hash) + getFirstSeenTime().hashCode(); + } + if (getHardwareCount() > 0) { + hash = (37 * hash) + HARDWARE_FIELD_NUMBER; + hash = (53 * hash) + getHardwareList().hashCode(); + } + if (hasPlatformSoftware()) { + hash = (37 * hash) + PLATFORM_SOFTWARE_FIELD_NUMBER; + hash = (53 * hash) + getPlatformSoftware().hashCode(); + } + if (getSoftwareCount() > 0) { + hash = (37 * hash) + SOFTWARE_FIELD_NUMBER; + hash = (53 * hash) + getSoftwareList().hashCode(); + } + if (hasLocation()) { + hash = (37 * hash) + LOCATION_FIELD_NUMBER; + hash = (53 * hash) + getLocation().hashCode(); + } + hash = (37 * hash) + CATEGORY_FIELD_NUMBER; + hash = (53 * hash) + getCategory().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + hash = (37 * hash) + NETWORK_DOMAIN_FIELD_NUMBER; + hash = (53 * hash) + getNetworkDomain().hashCode(); + if (hasCreationTime()) { + hash = (37 * hash) + CREATION_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreationTime().hashCode(); + } + if (hasFirstDiscoverTime()) { + hash = (37 * hash) + FIRST_DISCOVER_TIME_FIELD_NUMBER; + hash = (53 * hash) + getFirstDiscoverTime().hashCode(); + } + if (hasLastDiscoverTime()) { + hash = (37 * hash) + LAST_DISCOVER_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastDiscoverTime().hashCode(); + } + if (hasSystemLastUpdateTime()) { + hash = (37 * hash) + SYSTEM_LAST_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getSystemLastUpdateTime().hashCode(); + } + if (hasLastBootTime()) { + hash = (37 * hash) + LAST_BOOT_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastBootTime().hashCode(); + } + if (getLabelsCount() > 0) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + getLabelsList().hashCode(); + } + hash = (37 * hash) + DEPLOYMENT_STATUS_FIELD_NUMBER; + hash = (53 * hash) + deploymentStatus_; + if (getVulnerabilitiesCount() > 0) { + hash = (37 * hash) + VULNERABILITIES_FIELD_NUMBER; + hash = (53 * hash) + getVulnerabilitiesList().hashCode(); + } + if (hasAttribute()) { + hash = (37 * hash) + ATTRIBUTE_FIELD_NUMBER; + hash = (53 * hash) + getAttribute().hashCode(); + } + if (hasWmiPersistenceItem()) { + hash = (37 * hash) + WMI_PERSISTENCE_ITEM_FIELD_NUMBER; + hash = (53 * hash) + getWmiPersistenceItem().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Asset parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Asset parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Asset parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Asset parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Asset parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Asset parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Asset parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Asset parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Asset parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Asset parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Asset parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Asset parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Asset prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Information about a compute asset such as a workstation, laptop, phone,
+   * virtual desktop, or VM.
+   * 
+ * + * Protobuf type {@code google.backstory.Asset} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Asset) + com.google.backstory.AssetOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Asset_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Asset_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Asset.class, com.google.backstory.Asset.Builder.class); + } + + // Construct using com.google.backstory.Asset.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetFirstSeenTimeFieldBuilder(); + internalGetHardwareFieldBuilder(); + internalGetPlatformSoftwareFieldBuilder(); + internalGetSoftwareFieldBuilder(); + internalGetLocationFieldBuilder(); + internalGetCreationTimeFieldBuilder(); + internalGetFirstDiscoverTimeFieldBuilder(); + internalGetLastDiscoverTimeFieldBuilder(); + internalGetSystemLastUpdateTimeFieldBuilder(); + internalGetLastBootTimeFieldBuilder(); + internalGetLabelsFieldBuilder(); + internalGetVulnerabilitiesFieldBuilder(); + internalGetAttributeFieldBuilder(); + internalGetWmiPersistenceItemFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + productObjectId_ = ""; + hostname_ = ""; + assetId_ = ""; + ip_ = com.google.protobuf.LazyStringArrayList.emptyList(); + mac_ = com.google.protobuf.LazyStringArrayList.emptyList(); + natIp_ = com.google.protobuf.LazyStringArrayList.emptyList(); + firstSeenTime_ = null; + if (firstSeenTimeBuilder_ != null) { + firstSeenTimeBuilder_.dispose(); + firstSeenTimeBuilder_ = null; + } + if (hardwareBuilder_ == null) { + hardware_ = java.util.Collections.emptyList(); + } else { + hardware_ = null; + hardwareBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000080); + platformSoftware_ = null; + if (platformSoftwareBuilder_ != null) { + platformSoftwareBuilder_.dispose(); + platformSoftwareBuilder_ = null; + } + if (softwareBuilder_ == null) { + software_ = java.util.Collections.emptyList(); + } else { + software_ = null; + softwareBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000200); + location_ = null; + if (locationBuilder_ != null) { + locationBuilder_.dispose(); + locationBuilder_ = null; + } + category_ = ""; + type_ = 0; + networkDomain_ = ""; + creationTime_ = null; + if (creationTimeBuilder_ != null) { + creationTimeBuilder_.dispose(); + creationTimeBuilder_ = null; + } + firstDiscoverTime_ = null; + if (firstDiscoverTimeBuilder_ != null) { + firstDiscoverTimeBuilder_.dispose(); + firstDiscoverTimeBuilder_ = null; + } + lastDiscoverTime_ = null; + if (lastDiscoverTimeBuilder_ != null) { + lastDiscoverTimeBuilder_.dispose(); + lastDiscoverTimeBuilder_ = null; + } + systemLastUpdateTime_ = null; + if (systemLastUpdateTimeBuilder_ != null) { + systemLastUpdateTimeBuilder_.dispose(); + systemLastUpdateTimeBuilder_ = null; + } + lastBootTime_ = null; + if (lastBootTimeBuilder_ != null) { + lastBootTimeBuilder_.dispose(); + lastBootTimeBuilder_ = null; + } + if (labelsBuilder_ == null) { + labels_ = java.util.Collections.emptyList(); + } else { + labels_ = null; + labelsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00080000); + deploymentStatus_ = 0; + if (vulnerabilitiesBuilder_ == null) { + vulnerabilities_ = java.util.Collections.emptyList(); + } else { + vulnerabilities_ = null; + vulnerabilitiesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00200000); + attribute_ = null; + if (attributeBuilder_ != null) { + attributeBuilder_.dispose(); + attributeBuilder_ = null; + } + wmiPersistenceItem_ = null; + if (wmiPersistenceItemBuilder_ != null) { + wmiPersistenceItemBuilder_.dispose(); + wmiPersistenceItemBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Asset_descriptor; + } + + @java.lang.Override + public com.google.backstory.Asset getDefaultInstanceForType() { + return com.google.backstory.Asset.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Asset build() { + com.google.backstory.Asset result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Asset buildPartial() { + com.google.backstory.Asset result = new com.google.backstory.Asset(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.Asset result) { + if (hardwareBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0)) { + hardware_ = java.util.Collections.unmodifiableList(hardware_); + bitField0_ = (bitField0_ & ~0x00000080); + } + result.hardware_ = hardware_; + } else { + result.hardware_ = hardwareBuilder_.build(); + } + if (softwareBuilder_ == null) { + if (((bitField0_ & 0x00000200) != 0)) { + software_ = java.util.Collections.unmodifiableList(software_); + bitField0_ = (bitField0_ & ~0x00000200); + } + result.software_ = software_; + } else { + result.software_ = softwareBuilder_.build(); + } + if (labelsBuilder_ == null) { + if (((bitField0_ & 0x00080000) != 0)) { + labels_ = java.util.Collections.unmodifiableList(labels_); + bitField0_ = (bitField0_ & ~0x00080000); + } + result.labels_ = labels_; + } else { + result.labels_ = labelsBuilder_.build(); + } + if (vulnerabilitiesBuilder_ == null) { + if (((bitField0_ & 0x00200000) != 0)) { + vulnerabilities_ = java.util.Collections.unmodifiableList(vulnerabilities_); + bitField0_ = (bitField0_ & ~0x00200000); + } + result.vulnerabilities_ = vulnerabilities_; + } else { + result.vulnerabilities_ = vulnerabilitiesBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.Asset result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.productObjectId_ = productObjectId_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.hostname_ = hostname_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.assetId_ = assetId_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + ip_.makeImmutable(); + result.ip_ = ip_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + mac_.makeImmutable(); + result.mac_ = mac_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + natIp_.makeImmutable(); + result.natIp_ = natIp_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000040) != 0)) { + result.firstSeenTime_ = + firstSeenTimeBuilder_ == null ? firstSeenTime_ : firstSeenTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.platformSoftware_ = + platformSoftwareBuilder_ == null ? platformSoftware_ : platformSoftwareBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.location_ = locationBuilder_ == null ? location_ : locationBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.category_ = category_; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.type_ = type_; + } + if (((from_bitField0_ & 0x00002000) != 0)) { + result.networkDomain_ = networkDomain_; + } + if (((from_bitField0_ & 0x00004000) != 0)) { + result.creationTime_ = + creationTimeBuilder_ == null ? creationTime_ : creationTimeBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00008000) != 0)) { + result.firstDiscoverTime_ = + firstDiscoverTimeBuilder_ == null + ? firstDiscoverTime_ + : firstDiscoverTimeBuilder_.build(); + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00010000) != 0)) { + result.lastDiscoverTime_ = + lastDiscoverTimeBuilder_ == null ? lastDiscoverTime_ : lastDiscoverTimeBuilder_.build(); + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00020000) != 0)) { + result.systemLastUpdateTime_ = + systemLastUpdateTimeBuilder_ == null + ? systemLastUpdateTime_ + : systemLastUpdateTimeBuilder_.build(); + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00040000) != 0)) { + result.lastBootTime_ = + lastBootTimeBuilder_ == null ? lastBootTime_ : lastBootTimeBuilder_.build(); + to_bitField0_ |= 0x00000080; + } + if (((from_bitField0_ & 0x00100000) != 0)) { + result.deploymentStatus_ = deploymentStatus_; + } + if (((from_bitField0_ & 0x00400000) != 0)) { + result.attribute_ = attributeBuilder_ == null ? attribute_ : attributeBuilder_.build(); + to_bitField0_ |= 0x00000100; + } + if (((from_bitField0_ & 0x00800000) != 0)) { + result.wmiPersistenceItem_ = + wmiPersistenceItemBuilder_ == null + ? wmiPersistenceItem_ + : wmiPersistenceItemBuilder_.build(); + to_bitField0_ |= 0x00000200; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Asset) { + return mergeFrom((com.google.backstory.Asset) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Asset other) { + if (other == com.google.backstory.Asset.getDefaultInstance()) return this; + if (!other.getProductObjectId().isEmpty()) { + productObjectId_ = other.productObjectId_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getHostname().isEmpty()) { + hostname_ = other.hostname_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getAssetId().isEmpty()) { + assetId_ = other.assetId_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.ip_.isEmpty()) { + if (ip_.isEmpty()) { + ip_ = other.ip_; + bitField0_ |= 0x00000008; + } else { + ensureIpIsMutable(); + ip_.addAll(other.ip_); + } + onChanged(); + } + if (!other.mac_.isEmpty()) { + if (mac_.isEmpty()) { + mac_ = other.mac_; + bitField0_ |= 0x00000010; + } else { + ensureMacIsMutable(); + mac_.addAll(other.mac_); + } + onChanged(); + } + if (!other.natIp_.isEmpty()) { + if (natIp_.isEmpty()) { + natIp_ = other.natIp_; + bitField0_ |= 0x00000020; + } else { + ensureNatIpIsMutable(); + natIp_.addAll(other.natIp_); + } + onChanged(); + } + if (other.hasFirstSeenTime()) { + mergeFirstSeenTime(other.getFirstSeenTime()); + } + if (hardwareBuilder_ == null) { + if (!other.hardware_.isEmpty()) { + if (hardware_.isEmpty()) { + hardware_ = other.hardware_; + bitField0_ = (bitField0_ & ~0x00000080); + } else { + ensureHardwareIsMutable(); + hardware_.addAll(other.hardware_); + } + onChanged(); + } + } else { + if (!other.hardware_.isEmpty()) { + if (hardwareBuilder_.isEmpty()) { + hardwareBuilder_.dispose(); + hardwareBuilder_ = null; + hardware_ = other.hardware_; + bitField0_ = (bitField0_ & ~0x00000080); + hardwareBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetHardwareFieldBuilder() + : null; + } else { + hardwareBuilder_.addAllMessages(other.hardware_); + } + } + } + if (other.hasPlatformSoftware()) { + mergePlatformSoftware(other.getPlatformSoftware()); + } + if (softwareBuilder_ == null) { + if (!other.software_.isEmpty()) { + if (software_.isEmpty()) { + software_ = other.software_; + bitField0_ = (bitField0_ & ~0x00000200); + } else { + ensureSoftwareIsMutable(); + software_.addAll(other.software_); + } + onChanged(); + } + } else { + if (!other.software_.isEmpty()) { + if (softwareBuilder_.isEmpty()) { + softwareBuilder_.dispose(); + softwareBuilder_ = null; + software_ = other.software_; + bitField0_ = (bitField0_ & ~0x00000200); + softwareBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetSoftwareFieldBuilder() + : null; + } else { + softwareBuilder_.addAllMessages(other.software_); + } + } + } + if (other.hasLocation()) { + mergeLocation(other.getLocation()); + } + if (!other.getCategory().isEmpty()) { + category_ = other.category_; + bitField0_ |= 0x00000800; + onChanged(); + } + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + if (!other.getNetworkDomain().isEmpty()) { + networkDomain_ = other.networkDomain_; + bitField0_ |= 0x00002000; + onChanged(); + } + if (other.hasCreationTime()) { + mergeCreationTime(other.getCreationTime()); + } + if (other.hasFirstDiscoverTime()) { + mergeFirstDiscoverTime(other.getFirstDiscoverTime()); + } + if (other.hasLastDiscoverTime()) { + mergeLastDiscoverTime(other.getLastDiscoverTime()); + } + if (other.hasSystemLastUpdateTime()) { + mergeSystemLastUpdateTime(other.getSystemLastUpdateTime()); + } + if (other.hasLastBootTime()) { + mergeLastBootTime(other.getLastBootTime()); + } + if (labelsBuilder_ == null) { + if (!other.labels_.isEmpty()) { + if (labels_.isEmpty()) { + labels_ = other.labels_; + bitField0_ = (bitField0_ & ~0x00080000); + } else { + ensureLabelsIsMutable(); + labels_.addAll(other.labels_); + } + onChanged(); + } + } else { + if (!other.labels_.isEmpty()) { + if (labelsBuilder_.isEmpty()) { + labelsBuilder_.dispose(); + labelsBuilder_ = null; + labels_ = other.labels_; + bitField0_ = (bitField0_ & ~0x00080000); + labelsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetLabelsFieldBuilder() + : null; + } else { + labelsBuilder_.addAllMessages(other.labels_); + } + } + } + if (other.deploymentStatus_ != 0) { + setDeploymentStatusValue(other.getDeploymentStatusValue()); + } + if (vulnerabilitiesBuilder_ == null) { + if (!other.vulnerabilities_.isEmpty()) { + if (vulnerabilities_.isEmpty()) { + vulnerabilities_ = other.vulnerabilities_; + bitField0_ = (bitField0_ & ~0x00200000); + } else { + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.addAll(other.vulnerabilities_); + } + onChanged(); + } + } else { + if (!other.vulnerabilities_.isEmpty()) { + if (vulnerabilitiesBuilder_.isEmpty()) { + vulnerabilitiesBuilder_.dispose(); + vulnerabilitiesBuilder_ = null; + vulnerabilities_ = other.vulnerabilities_; + bitField0_ = (bitField0_ & ~0x00200000); + vulnerabilitiesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetVulnerabilitiesFieldBuilder() + : null; + } else { + vulnerabilitiesBuilder_.addAllMessages(other.vulnerabilities_); + } + } + } + if (other.hasAttribute()) { + mergeAttribute(other.getAttribute()); + } + if (other.hasWmiPersistenceItem()) { + mergeWmiPersistenceItem(other.getWmiPersistenceItem()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + productObjectId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + hostname_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + assetId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIpIsMutable(); + ip_.add(s); + break; + } // case 34 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureMacIsMutable(); + mac_.add(s); + break; + } // case 42 + case 50: + { + com.google.backstory.Hardware m = + input.readMessage(com.google.backstory.Hardware.parser(), extensionRegistry); + if (hardwareBuilder_ == null) { + ensureHardwareIsMutable(); + hardware_.add(m); + } else { + hardwareBuilder_.addMessage(m); + } + break; + } // case 50 + case 58: + { + input.readMessage( + internalGetPlatformSoftwareFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 58 + case 66: + { + input.readMessage( + internalGetLocationFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000400; + break; + } // case 66 + case 74: + { + category_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000800; + break; + } // case 74 + case 82: + { + networkDomain_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00002000; + break; + } // case 82 + case 90: + { + input.readMessage( + internalGetCreationTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00004000; + break; + } // case 90 + case 98: + { + input.readMessage( + internalGetFirstDiscoverTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00008000; + break; + } // case 98 + case 106: + { + input.readMessage( + internalGetLastDiscoverTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00010000; + break; + } // case 106 + case 114: + { + input.readMessage( + internalGetSystemLastUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00020000; + break; + } // case 114 + case 122: + { + input.readMessage( + internalGetLastBootTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00040000; + break; + } // case 122 + case 130: + { + com.google.backstory.Label m = + input.readMessage(com.google.backstory.Label.parser(), extensionRegistry); + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.add(m); + } else { + labelsBuilder_.addMessage(m); + } + break; + } // case 130 + case 138: + { + com.google.backstory.Software m = + input.readMessage(com.google.backstory.Software.parser(), extensionRegistry); + if (softwareBuilder_ == null) { + ensureSoftwareIsMutable(); + software_.add(m); + } else { + softwareBuilder_.addMessage(m); + } + break; + } // case 138 + case 144: + { + type_ = input.readEnum(); + bitField0_ |= 0x00001000; + break; + } // case 144 + case 152: + { + deploymentStatus_ = input.readEnum(); + bitField0_ |= 0x00100000; + break; + } // case 152 + case 162: + { + input.readMessage( + internalGetAttributeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00400000; + break; + } // case 162 + case 170: + { + com.google.backstory.Vulnerability m = + input.readMessage( + com.google.backstory.Vulnerability.parser(), extensionRegistry); + if (vulnerabilitiesBuilder_ == null) { + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.add(m); + } else { + vulnerabilitiesBuilder_.addMessage(m); + } + break; + } // case 170 + case 178: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureNatIpIsMutable(); + natIp_.add(s); + break; + } // case 178 + case 186: + { + input.readMessage( + internalGetFirstSeenTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 186 + case 194: + { + input.readMessage( + internalGetWmiPersistenceItemFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00800000; + break; + } // case 194 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object productObjectId_ = ""; + + /** + * + * + *
+     * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+     * similar).
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string product_object_id = 1; + * + * @return The productObjectId. + */ + public java.lang.String getProductObjectId() { + java.lang.Object ref = productObjectId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + productObjectId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+     * similar).
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string product_object_id = 1; + * + * @return The bytes for productObjectId. + */ + public com.google.protobuf.ByteString getProductObjectIdBytes() { + java.lang.Object ref = productObjectId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + productObjectId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+     * similar).
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string product_object_id = 1; + * + * @param value The productObjectId to set. + * @return This builder for chaining. + */ + public Builder setProductObjectId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + productObjectId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+     * similar).
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string product_object_id = 1; + * + * @return This builder for chaining. + */ + public Builder clearProductObjectId() { + productObjectId_ = getDefaultInstance().getProductObjectId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+     * similar).
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string product_object_id = 1; + * + * @param value The bytes for productObjectId to set. + * @return This builder for chaining. + */ + public Builder setProductObjectIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + productObjectId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object hostname_ = ""; + + /** + * + * + *
+     * Asset hostname or domain name field.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string hostname = 2; + * + * @return The hostname. + */ + public java.lang.String getHostname() { + java.lang.Object ref = hostname_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + hostname_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Asset hostname or domain name field.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string hostname = 2; + * + * @return The bytes for hostname. + */ + public com.google.protobuf.ByteString getHostnameBytes() { + java.lang.Object ref = hostname_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + hostname_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Asset hostname or domain name field.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string hostname = 2; + * + * @param value The hostname to set. + * @return This builder for chaining. + */ + public Builder setHostname(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + hostname_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Asset hostname or domain name field.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string hostname = 2; + * + * @return This builder for chaining. + */ + public Builder clearHostname() { + hostname_ = getDefaultInstance().getHostname(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Asset hostname or domain name field.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string hostname = 2; + * + * @param value The bytes for hostname to set. + * @return This builder for chaining. + */ + public Builder setHostnameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + hostname_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object assetId_ = ""; + + /** + * + * + *
+     * The asset ID. Value must contain the ':' character. For example,
+     * cs:abcdd23434.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string asset_id = 3; + * + * @return The assetId. + */ + public java.lang.String getAssetId() { + java.lang.Object ref = assetId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + assetId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The asset ID. Value must contain the ':' character. For example,
+     * cs:abcdd23434.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string asset_id = 3; + * + * @return The bytes for assetId. + */ + public com.google.protobuf.ByteString getAssetIdBytes() { + java.lang.Object ref = assetId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + assetId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The asset ID. Value must contain the ':' character. For example,
+     * cs:abcdd23434.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string asset_id = 3; + * + * @param value The assetId to set. + * @return This builder for chaining. + */ + public Builder setAssetId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + assetId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The asset ID. Value must contain the ':' character. For example,
+     * cs:abcdd23434.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string asset_id = 3; + * + * @return This builder for chaining. + */ + public Builder clearAssetId() { + assetId_ = getDefaultInstance().getAssetId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * The asset ID. Value must contain the ':' character. For example,
+     * cs:abcdd23434.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * string asset_id = 3; + * + * @param value The bytes for assetId to set. + * @return This builder for chaining. + */ + public Builder setAssetIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + assetId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList ip_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIpIsMutable() { + if (!ip_.isModifiable()) { + ip_ = new com.google.protobuf.LazyStringArrayList(ip_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @return A list containing the ip. + */ + public com.google.protobuf.ProtocolStringList getIpList() { + ip_.makeImmutable(); + return ip_; + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @return The count of ip. + */ + public int getIpCount() { + return ip_.size(); + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @param index The index of the element to return. + * @return The ip at the given index. + */ + public java.lang.String getIp(int index) { + return ip_.get(index); + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @param index The index of the value to return. + * @return The bytes of the ip at the given index. + */ + public com.google.protobuf.ByteString getIpBytes(int index) { + return ip_.getByteString(index); + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @param index The index to set the value at. + * @param value The ip to set. + * @return This builder for chaining. + */ + public Builder setIp(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIpIsMutable(); + ip_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @param value The ip to add. + * @return This builder for chaining. + */ + public Builder addIp(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIpIsMutable(); + ip_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @param values The ip to add. + * @return This builder for chaining. + */ + public Builder addAllIp(java.lang.Iterable values) { + ensureIpIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, ip_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @return This builder for chaining. + */ + public Builder clearIp() { + ip_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * A list of IP addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string ip = 4; + * + * @param value The bytes of the ip to add. + * @return This builder for chaining. + */ + public Builder addIpBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIpIsMutable(); + ip_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList mac_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureMacIsMutable() { + if (!mac_.isModifiable()) { + mac_ = new com.google.protobuf.LazyStringArrayList(mac_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @return A list containing the mac. + */ + public com.google.protobuf.ProtocolStringList getMacList() { + mac_.makeImmutable(); + return mac_; + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @return The count of mac. + */ + public int getMacCount() { + return mac_.size(); + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @param index The index of the element to return. + * @return The mac at the given index. + */ + public java.lang.String getMac(int index) { + return mac_.get(index); + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @param index The index of the value to return. + * @return The bytes of the mac at the given index. + */ + public com.google.protobuf.ByteString getMacBytes(int index) { + return mac_.getByteString(index); + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @param index The index to set the value at. + * @param value The mac to set. + * @return This builder for chaining. + */ + public Builder setMac(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureMacIsMutable(); + mac_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @param value The mac to add. + * @return This builder for chaining. + */ + public Builder addMac(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureMacIsMutable(); + mac_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @param values The mac to add. + * @return This builder for chaining. + */ + public Builder addAllMac(java.lang.Iterable values) { + ensureMacIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, mac_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @return This builder for chaining. + */ + public Builder clearMac() { + mac_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of MAC addresses associated with an asset.
+     * This field can be used as an entity indicator for asset entities.
+     * 
+ * + * repeated string mac = 5; + * + * @param value The bytes of the mac to add. + * @return This builder for chaining. + */ + public Builder addMacBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureMacIsMutable(); + mac_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList natIp_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureNatIpIsMutable() { + if (!natIp_.isModifiable()) { + natIp_ = new com.google.protobuf.LazyStringArrayList(natIp_); + } + bitField0_ |= 0x00000020; + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @return A list containing the natIp. + */ + public com.google.protobuf.ProtocolStringList getNatIpList() { + natIp_.makeImmutable(); + return natIp_; + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @return The count of natIp. + */ + public int getNatIpCount() { + return natIp_.size(); + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index of the element to return. + * @return The natIp at the given index. + */ + public java.lang.String getNatIp(int index) { + return natIp_.get(index); + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index of the value to return. + * @return The bytes of the natIp at the given index. + */ + public com.google.protobuf.ByteString getNatIpBytes(int index) { + return natIp_.getByteString(index); + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index to set the value at. + * @param value The natIp to set. + * @return This builder for chaining. + */ + public Builder setNatIp(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureNatIpIsMutable(); + natIp_.set(index, value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @param value The natIp to add. + * @return This builder for chaining. + */ + public Builder addNatIp(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureNatIpIsMutable(); + natIp_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @param values The natIp to add. + * @return This builder for chaining. + */ + public Builder addAllNatIp(java.lang.Iterable values) { + ensureNatIpIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, natIp_); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @return This builder for chaining. + */ + public Builder clearNatIp() { + natIp_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000020); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * List of NAT IP addresses associated with an asset.
+     * 
+ * + * repeated string nat_ip = 22; + * + * @param value The bytes of the natIp to add. + * @return This builder for chaining. + */ + public Builder addNatIpBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureNatIpIsMutable(); + natIp_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp firstSeenTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + firstSeenTimeBuilder_; + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + * + * @return Whether the firstSeenTime field is set. + */ + public boolean hasFirstSeenTime() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + * + * @return The firstSeenTime. + */ + public com.google.protobuf.Timestamp getFirstSeenTime() { + if (firstSeenTimeBuilder_ == null) { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } else { + return firstSeenTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + public Builder setFirstSeenTime(com.google.protobuf.Timestamp value) { + if (firstSeenTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + firstSeenTime_ = value; + } else { + firstSeenTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + public Builder setFirstSeenTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (firstSeenTimeBuilder_ == null) { + firstSeenTime_ = builderForValue.build(); + } else { + firstSeenTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + public Builder mergeFirstSeenTime(com.google.protobuf.Timestamp value) { + if (firstSeenTimeBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && firstSeenTime_ != null + && firstSeenTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getFirstSeenTimeBuilder().mergeFrom(value); + } else { + firstSeenTime_ = value; + } + } else { + firstSeenTimeBuilder_.mergeFrom(value); + } + if (firstSeenTime_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + public Builder clearFirstSeenTime() { + bitField0_ = (bitField0_ & ~0x00000040); + firstSeenTime_ = null; + if (firstSeenTimeBuilder_ != null) { + firstSeenTimeBuilder_.dispose(); + firstSeenTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + public com.google.protobuf.Timestamp.Builder getFirstSeenTimeBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetFirstSeenTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + public com.google.protobuf.TimestampOrBuilder getFirstSeenTimeOrBuilder() { + if (firstSeenTimeBuilder_ != null) { + return firstSeenTimeBuilder_.getMessageOrBuilder(); + } else { + return firstSeenTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstSeenTime_; + } + } + + /** + * + * + *
+     * The first observed time for an asset.
+     * The value is calculated on the basis of the
+     * first time the identifier was observed.
+     * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetFirstSeenTimeFieldBuilder() { + if (firstSeenTimeBuilder_ == null) { + firstSeenTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getFirstSeenTime(), getParentForChildren(), isClean()); + firstSeenTime_ = null; + } + return firstSeenTimeBuilder_; + } + + private java.util.List hardware_ = + java.util.Collections.emptyList(); + + private void ensureHardwareIsMutable() { + if (!((bitField0_ & 0x00000080) != 0)) { + hardware_ = new java.util.ArrayList(hardware_); + bitField0_ |= 0x00000080; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Hardware, + com.google.backstory.Hardware.Builder, + com.google.backstory.HardwareOrBuilder> + hardwareBuilder_; + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public java.util.List getHardwareList() { + if (hardwareBuilder_ == null) { + return java.util.Collections.unmodifiableList(hardware_); + } else { + return hardwareBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public int getHardwareCount() { + if (hardwareBuilder_ == null) { + return hardware_.size(); + } else { + return hardwareBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public com.google.backstory.Hardware getHardware(int index) { + if (hardwareBuilder_ == null) { + return hardware_.get(index); + } else { + return hardwareBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder setHardware(int index, com.google.backstory.Hardware value) { + if (hardwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureHardwareIsMutable(); + hardware_.set(index, value); + onChanged(); + } else { + hardwareBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder setHardware(int index, com.google.backstory.Hardware.Builder builderForValue) { + if (hardwareBuilder_ == null) { + ensureHardwareIsMutable(); + hardware_.set(index, builderForValue.build()); + onChanged(); + } else { + hardwareBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder addHardware(com.google.backstory.Hardware value) { + if (hardwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureHardwareIsMutable(); + hardware_.add(value); + onChanged(); + } else { + hardwareBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder addHardware(int index, com.google.backstory.Hardware value) { + if (hardwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureHardwareIsMutable(); + hardware_.add(index, value); + onChanged(); + } else { + hardwareBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder addHardware(com.google.backstory.Hardware.Builder builderForValue) { + if (hardwareBuilder_ == null) { + ensureHardwareIsMutable(); + hardware_.add(builderForValue.build()); + onChanged(); + } else { + hardwareBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder addHardware(int index, com.google.backstory.Hardware.Builder builderForValue) { + if (hardwareBuilder_ == null) { + ensureHardwareIsMutable(); + hardware_.add(index, builderForValue.build()); + onChanged(); + } else { + hardwareBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder addAllHardware( + java.lang.Iterable values) { + if (hardwareBuilder_ == null) { + ensureHardwareIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, hardware_); + onChanged(); + } else { + hardwareBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder clearHardware() { + if (hardwareBuilder_ == null) { + hardware_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + } else { + hardwareBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public Builder removeHardware(int index) { + if (hardwareBuilder_ == null) { + ensureHardwareIsMutable(); + hardware_.remove(index); + onChanged(); + } else { + hardwareBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public com.google.backstory.Hardware.Builder getHardwareBuilder(int index) { + return internalGetHardwareFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public com.google.backstory.HardwareOrBuilder getHardwareOrBuilder(int index) { + if (hardwareBuilder_ == null) { + return hardware_.get(index); + } else { + return hardwareBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public java.util.List + getHardwareOrBuilderList() { + if (hardwareBuilder_ != null) { + return hardwareBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(hardware_); + } + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public com.google.backstory.Hardware.Builder addHardwareBuilder() { + return internalGetHardwareFieldBuilder() + .addBuilder(com.google.backstory.Hardware.getDefaultInstance()); + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public com.google.backstory.Hardware.Builder addHardwareBuilder(int index) { + return internalGetHardwareFieldBuilder() + .addBuilder(index, com.google.backstory.Hardware.getDefaultInstance()); + } + + /** + * + * + *
+     * The asset hardware specifications.
+     * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + public java.util.List getHardwareBuilderList() { + return internalGetHardwareFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Hardware, + com.google.backstory.Hardware.Builder, + com.google.backstory.HardwareOrBuilder> + internalGetHardwareFieldBuilder() { + if (hardwareBuilder_ == null) { + hardwareBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Hardware, + com.google.backstory.Hardware.Builder, + com.google.backstory.HardwareOrBuilder>( + hardware_, ((bitField0_ & 0x00000080) != 0), getParentForChildren(), isClean()); + hardware_ = null; + } + return hardwareBuilder_; + } + + private com.google.backstory.PlatformSoftware platformSoftware_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.PlatformSoftware, + com.google.backstory.PlatformSoftware.Builder, + com.google.backstory.PlatformSoftwareOrBuilder> + platformSoftwareBuilder_; + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + * + * @return Whether the platformSoftware field is set. + */ + public boolean hasPlatformSoftware() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + * + * @return The platformSoftware. + */ + public com.google.backstory.PlatformSoftware getPlatformSoftware() { + if (platformSoftwareBuilder_ == null) { + return platformSoftware_ == null + ? com.google.backstory.PlatformSoftware.getDefaultInstance() + : platformSoftware_; + } else { + return platformSoftwareBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + public Builder setPlatformSoftware(com.google.backstory.PlatformSoftware value) { + if (platformSoftwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + platformSoftware_ = value; + } else { + platformSoftwareBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + public Builder setPlatformSoftware( + com.google.backstory.PlatformSoftware.Builder builderForValue) { + if (platformSoftwareBuilder_ == null) { + platformSoftware_ = builderForValue.build(); + } else { + platformSoftwareBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + public Builder mergePlatformSoftware(com.google.backstory.PlatformSoftware value) { + if (platformSoftwareBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && platformSoftware_ != null + && platformSoftware_ != com.google.backstory.PlatformSoftware.getDefaultInstance()) { + getPlatformSoftwareBuilder().mergeFrom(value); + } else { + platformSoftware_ = value; + } + } else { + platformSoftwareBuilder_.mergeFrom(value); + } + if (platformSoftware_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + public Builder clearPlatformSoftware() { + bitField0_ = (bitField0_ & ~0x00000100); + platformSoftware_ = null; + if (platformSoftwareBuilder_ != null) { + platformSoftwareBuilder_.dispose(); + platformSoftwareBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + public com.google.backstory.PlatformSoftware.Builder getPlatformSoftwareBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return internalGetPlatformSoftwareFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + public com.google.backstory.PlatformSoftwareOrBuilder getPlatformSoftwareOrBuilder() { + if (platformSoftwareBuilder_ != null) { + return platformSoftwareBuilder_.getMessageOrBuilder(); + } else { + return platformSoftware_ == null + ? com.google.backstory.PlatformSoftware.getDefaultInstance() + : platformSoftware_; + } + } + + /** + * + * + *
+     * The asset operating system platform software.
+     * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.PlatformSoftware, + com.google.backstory.PlatformSoftware.Builder, + com.google.backstory.PlatformSoftwareOrBuilder> + internalGetPlatformSoftwareFieldBuilder() { + if (platformSoftwareBuilder_ == null) { + platformSoftwareBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.PlatformSoftware, + com.google.backstory.PlatformSoftware.Builder, + com.google.backstory.PlatformSoftwareOrBuilder>( + getPlatformSoftware(), getParentForChildren(), isClean()); + platformSoftware_ = null; + } + return platformSoftwareBuilder_; + } + + private java.util.List software_ = + java.util.Collections.emptyList(); + + private void ensureSoftwareIsMutable() { + if (!((bitField0_ & 0x00000200) != 0)) { + software_ = new java.util.ArrayList(software_); + bitField0_ |= 0x00000200; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Software, + com.google.backstory.Software.Builder, + com.google.backstory.SoftwareOrBuilder> + softwareBuilder_; + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public java.util.List getSoftwareList() { + if (softwareBuilder_ == null) { + return java.util.Collections.unmodifiableList(software_); + } else { + return softwareBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public int getSoftwareCount() { + if (softwareBuilder_ == null) { + return software_.size(); + } else { + return softwareBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public com.google.backstory.Software getSoftware(int index) { + if (softwareBuilder_ == null) { + return software_.get(index); + } else { + return softwareBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder setSoftware(int index, com.google.backstory.Software value) { + if (softwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSoftwareIsMutable(); + software_.set(index, value); + onChanged(); + } else { + softwareBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder setSoftware(int index, com.google.backstory.Software.Builder builderForValue) { + if (softwareBuilder_ == null) { + ensureSoftwareIsMutable(); + software_.set(index, builderForValue.build()); + onChanged(); + } else { + softwareBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder addSoftware(com.google.backstory.Software value) { + if (softwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSoftwareIsMutable(); + software_.add(value); + onChanged(); + } else { + softwareBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder addSoftware(int index, com.google.backstory.Software value) { + if (softwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSoftwareIsMutable(); + software_.add(index, value); + onChanged(); + } else { + softwareBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder addSoftware(com.google.backstory.Software.Builder builderForValue) { + if (softwareBuilder_ == null) { + ensureSoftwareIsMutable(); + software_.add(builderForValue.build()); + onChanged(); + } else { + softwareBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder addSoftware(int index, com.google.backstory.Software.Builder builderForValue) { + if (softwareBuilder_ == null) { + ensureSoftwareIsMutable(); + software_.add(index, builderForValue.build()); + onChanged(); + } else { + softwareBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder addAllSoftware( + java.lang.Iterable values) { + if (softwareBuilder_ == null) { + ensureSoftwareIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, software_); + onChanged(); + } else { + softwareBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder clearSoftware() { + if (softwareBuilder_ == null) { + software_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000200); + onChanged(); + } else { + softwareBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public Builder removeSoftware(int index) { + if (softwareBuilder_ == null) { + ensureSoftwareIsMutable(); + software_.remove(index); + onChanged(); + } else { + softwareBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public com.google.backstory.Software.Builder getSoftwareBuilder(int index) { + return internalGetSoftwareFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public com.google.backstory.SoftwareOrBuilder getSoftwareOrBuilder(int index) { + if (softwareBuilder_ == null) { + return software_.get(index); + } else { + return softwareBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public java.util.List + getSoftwareOrBuilderList() { + if (softwareBuilder_ != null) { + return softwareBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(software_); + } + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public com.google.backstory.Software.Builder addSoftwareBuilder() { + return internalGetSoftwareFieldBuilder() + .addBuilder(com.google.backstory.Software.getDefaultInstance()); + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public com.google.backstory.Software.Builder addSoftwareBuilder(int index) { + return internalGetSoftwareFieldBuilder() + .addBuilder(index, com.google.backstory.Software.getDefaultInstance()); + } + + /** + * + * + *
+     * The asset software details.
+     * 
+ * + * repeated .google.backstory.Software software = 17; + */ + public java.util.List getSoftwareBuilderList() { + return internalGetSoftwareFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Software, + com.google.backstory.Software.Builder, + com.google.backstory.SoftwareOrBuilder> + internalGetSoftwareFieldBuilder() { + if (softwareBuilder_ == null) { + softwareBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Software, + com.google.backstory.Software.Builder, + com.google.backstory.SoftwareOrBuilder>( + software_, ((bitField0_ & 0x00000200) != 0), getParentForChildren(), isClean()); + software_ = null; + } + return softwareBuilder_; + } + + private com.google.backstory.Location location_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Location, + com.google.backstory.Location.Builder, + com.google.backstory.LocationOrBuilder> + locationBuilder_; + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + * + * @return Whether the location field is set. + */ + public boolean hasLocation() { + return ((bitField0_ & 0x00000400) != 0); + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + * + * @return The location. + */ + public com.google.backstory.Location getLocation() { + if (locationBuilder_ == null) { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } else { + return locationBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + public Builder setLocation(com.google.backstory.Location value) { + if (locationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + location_ = value; + } else { + locationBuilder_.setMessage(value); + } + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + public Builder setLocation(com.google.backstory.Location.Builder builderForValue) { + if (locationBuilder_ == null) { + location_ = builderForValue.build(); + } else { + locationBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + public Builder mergeLocation(com.google.backstory.Location value) { + if (locationBuilder_ == null) { + if (((bitField0_ & 0x00000400) != 0) + && location_ != null + && location_ != com.google.backstory.Location.getDefaultInstance()) { + getLocationBuilder().mergeFrom(value); + } else { + location_ = value; + } + } else { + locationBuilder_.mergeFrom(value); + } + if (location_ != null) { + bitField0_ |= 0x00000400; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + public Builder clearLocation() { + bitField0_ = (bitField0_ & ~0x00000400); + location_ = null; + if (locationBuilder_ != null) { + locationBuilder_.dispose(); + locationBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + public com.google.backstory.Location.Builder getLocationBuilder() { + bitField0_ |= 0x00000400; + onChanged(); + return internalGetLocationFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + public com.google.backstory.LocationOrBuilder getLocationOrBuilder() { + if (locationBuilder_ != null) { + return locationBuilder_.getMessageOrBuilder(); + } else { + return location_ == null ? com.google.backstory.Location.getDefaultInstance() : location_; + } + } + + /** + * + * + *
+     * Location of the asset.
+     * 
+ * + * .google.backstory.Location location = 8; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Location, + com.google.backstory.Location.Builder, + com.google.backstory.LocationOrBuilder> + internalGetLocationFieldBuilder() { + if (locationBuilder_ == null) { + locationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Location, + com.google.backstory.Location.Builder, + com.google.backstory.LocationOrBuilder>( + getLocation(), getParentForChildren(), isClean()); + location_ = null; + } + return locationBuilder_; + } + + private java.lang.Object category_ = ""; + + /** + * + * + *
+     * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+     * 
+ * + * string category = 9; + * + * @return The category. + */ + public java.lang.String getCategory() { + java.lang.Object ref = category_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + category_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+     * 
+ * + * string category = 9; + * + * @return The bytes for category. + */ + public com.google.protobuf.ByteString getCategoryBytes() { + java.lang.Object ref = category_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + category_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+     * 
+ * + * string category = 9; + * + * @param value The category to set. + * @return This builder for chaining. + */ + public Builder setCategory(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + category_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+     * 
+ * + * string category = 9; + * + * @return This builder for chaining. + */ + public Builder clearCategory() { + category_ = getDefaultInstance().getCategory(); + bitField0_ = (bitField0_ & ~0x00000800); + onChanged(); + return this; + } + + /** + * + * + *
+     * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+     * 
+ * + * string category = 9; + * + * @param value The bytes for category to set. + * @return This builder for chaining. + */ + public Builder setCategoryBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + category_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + private int type_ = 0; + + /** + * + * + *
+     * The type of the asset (e.g. workstation or laptop or server).
+     * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+     * The type of the asset (e.g. workstation or laptop or server).
+     * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @param value The enum numeric value on the wire for type to set. + * @return This builder for chaining. + */ + public Builder setTypeValue(int value) { + type_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of the asset (e.g. workstation or laptop or server).
+     * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return The type. + */ + @java.lang.Override + public com.google.backstory.Asset.AssetType getType() { + com.google.backstory.Asset.AssetType result = + com.google.backstory.Asset.AssetType.forNumber(type_); + return result == null ? com.google.backstory.Asset.AssetType.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The type of the asset (e.g. workstation or laptop or server).
+     * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.backstory.Asset.AssetType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00001000; + type_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of the asset (e.g. workstation or laptop or server).
+     * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return This builder for chaining. + */ + public Builder clearType() { + bitField0_ = (bitField0_ & ~0x00001000); + type_ = 0; + onChanged(); + return this; + } + + private java.lang.Object networkDomain_ = ""; + + /** + * + * + *
+     * The network domain of the asset (e.g. "corp.acme.com")
+     * 
+ * + * string network_domain = 10; + * + * @return The networkDomain. + */ + public java.lang.String getNetworkDomain() { + java.lang.Object ref = networkDomain_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + networkDomain_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The network domain of the asset (e.g. "corp.acme.com")
+     * 
+ * + * string network_domain = 10; + * + * @return The bytes for networkDomain. + */ + public com.google.protobuf.ByteString getNetworkDomainBytes() { + java.lang.Object ref = networkDomain_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + networkDomain_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The network domain of the asset (e.g. "corp.acme.com")
+     * 
+ * + * string network_domain = 10; + * + * @param value The networkDomain to set. + * @return This builder for chaining. + */ + public Builder setNetworkDomain(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + networkDomain_ = value; + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The network domain of the asset (e.g. "corp.acme.com")
+     * 
+ * + * string network_domain = 10; + * + * @return This builder for chaining. + */ + public Builder clearNetworkDomain() { + networkDomain_ = getDefaultInstance().getNetworkDomain(); + bitField0_ = (bitField0_ & ~0x00002000); + onChanged(); + return this; + } + + /** + * + * + *
+     * The network domain of the asset (e.g. "corp.acme.com")
+     * 
+ * + * string network_domain = 10; + * + * @param value The bytes for networkDomain to set. + * @return This builder for chaining. + */ + public Builder setNetworkDomainBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + networkDomain_ = value; + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp creationTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + creationTimeBuilder_; + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + * + * @deprecated google.backstory.Asset.creation_time is deprecated. See + * backstory/udm.proto;l=4670 + * @return Whether the creationTime field is set. + */ + @java.lang.Deprecated + public boolean hasCreationTime() { + return ((bitField0_ & 0x00004000) != 0); + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + * + * @deprecated google.backstory.Asset.creation_time is deprecated. See + * backstory/udm.proto;l=4670 + * @return The creationTime. + */ + @java.lang.Deprecated + public com.google.protobuf.Timestamp getCreationTime() { + if (creationTimeBuilder_ == null) { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } else { + return creationTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setCreationTime(com.google.protobuf.Timestamp value) { + if (creationTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + creationTime_ = value; + } else { + creationTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setCreationTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (creationTimeBuilder_ == null) { + creationTime_ = builderForValue.build(); + } else { + creationTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder mergeCreationTime(com.google.protobuf.Timestamp value) { + if (creationTimeBuilder_ == null) { + if (((bitField0_ & 0x00004000) != 0) + && creationTime_ != null + && creationTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreationTimeBuilder().mergeFrom(value); + } else { + creationTime_ = value; + } + } else { + creationTimeBuilder_.mergeFrom(value); + } + if (creationTime_ != null) { + bitField0_ |= 0x00004000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder clearCreationTime() { + bitField0_ = (bitField0_ & ~0x00004000); + creationTime_ = null; + if (creationTimeBuilder_ != null) { + creationTimeBuilder_.dispose(); + creationTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.protobuf.Timestamp.Builder getCreationTimeBuilder() { + bitField0_ |= 0x00004000; + onChanged(); + return internalGetCreationTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.protobuf.TimestampOrBuilder getCreationTimeOrBuilder() { + if (creationTimeBuilder_ != null) { + return creationTimeBuilder_.getMessageOrBuilder(); + } else { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } + } + + /** + * + * + *
+     * Time the asset was created or provisioned.
+     * Deprecate: creation_time should be populated in Attribute as generic
+     * metadata.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreationTimeFieldBuilder() { + if (creationTimeBuilder_ == null) { + creationTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreationTime(), getParentForChildren(), isClean()); + creationTime_ = null; + } + return creationTimeBuilder_; + } + + private com.google.protobuf.Timestamp firstDiscoverTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + firstDiscoverTimeBuilder_; + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + * + * @return Whether the firstDiscoverTime field is set. + */ + public boolean hasFirstDiscoverTime() { + return ((bitField0_ & 0x00008000) != 0); + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + * + * @return The firstDiscoverTime. + */ + public com.google.protobuf.Timestamp getFirstDiscoverTime() { + if (firstDiscoverTimeBuilder_ == null) { + return firstDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstDiscoverTime_; + } else { + return firstDiscoverTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + public Builder setFirstDiscoverTime(com.google.protobuf.Timestamp value) { + if (firstDiscoverTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + firstDiscoverTime_ = value; + } else { + firstDiscoverTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00008000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + public Builder setFirstDiscoverTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (firstDiscoverTimeBuilder_ == null) { + firstDiscoverTime_ = builderForValue.build(); + } else { + firstDiscoverTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00008000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + public Builder mergeFirstDiscoverTime(com.google.protobuf.Timestamp value) { + if (firstDiscoverTimeBuilder_ == null) { + if (((bitField0_ & 0x00008000) != 0) + && firstDiscoverTime_ != null + && firstDiscoverTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getFirstDiscoverTimeBuilder().mergeFrom(value); + } else { + firstDiscoverTime_ = value; + } + } else { + firstDiscoverTimeBuilder_.mergeFrom(value); + } + if (firstDiscoverTime_ != null) { + bitField0_ |= 0x00008000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + public Builder clearFirstDiscoverTime() { + bitField0_ = (bitField0_ & ~0x00008000); + firstDiscoverTime_ = null; + if (firstDiscoverTimeBuilder_ != null) { + firstDiscoverTimeBuilder_.dispose(); + firstDiscoverTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + public com.google.protobuf.Timestamp.Builder getFirstDiscoverTimeBuilder() { + bitField0_ |= 0x00008000; + onChanged(); + return internalGetFirstDiscoverTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + public com.google.protobuf.TimestampOrBuilder getFirstDiscoverTimeOrBuilder() { + if (firstDiscoverTimeBuilder_ != null) { + return firstDiscoverTimeBuilder_.getMessageOrBuilder(); + } else { + return firstDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstDiscoverTime_; + } + } + + /** + * + * + *
+     * Time the asset was first discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetFirstDiscoverTimeFieldBuilder() { + if (firstDiscoverTimeBuilder_ == null) { + firstDiscoverTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getFirstDiscoverTime(), getParentForChildren(), isClean()); + firstDiscoverTime_ = null; + } + return firstDiscoverTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastDiscoverTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastDiscoverTimeBuilder_; + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + * + * @return Whether the lastDiscoverTime field is set. + */ + public boolean hasLastDiscoverTime() { + return ((bitField0_ & 0x00010000) != 0); + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + * + * @return The lastDiscoverTime. + */ + public com.google.protobuf.Timestamp getLastDiscoverTime() { + if (lastDiscoverTimeBuilder_ == null) { + return lastDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastDiscoverTime_; + } else { + return lastDiscoverTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + public Builder setLastDiscoverTime(com.google.protobuf.Timestamp value) { + if (lastDiscoverTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastDiscoverTime_ = value; + } else { + lastDiscoverTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + public Builder setLastDiscoverTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastDiscoverTimeBuilder_ == null) { + lastDiscoverTime_ = builderForValue.build(); + } else { + lastDiscoverTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + public Builder mergeLastDiscoverTime(com.google.protobuf.Timestamp value) { + if (lastDiscoverTimeBuilder_ == null) { + if (((bitField0_ & 0x00010000) != 0) + && lastDiscoverTime_ != null + && lastDiscoverTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastDiscoverTimeBuilder().mergeFrom(value); + } else { + lastDiscoverTime_ = value; + } + } else { + lastDiscoverTimeBuilder_.mergeFrom(value); + } + if (lastDiscoverTime_ != null) { + bitField0_ |= 0x00010000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + public Builder clearLastDiscoverTime() { + bitField0_ = (bitField0_ & ~0x00010000); + lastDiscoverTime_ = null; + if (lastDiscoverTimeBuilder_ != null) { + lastDiscoverTimeBuilder_.dispose(); + lastDiscoverTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + public com.google.protobuf.Timestamp.Builder getLastDiscoverTimeBuilder() { + bitField0_ |= 0x00010000; + onChanged(); + return internalGetLastDiscoverTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + public com.google.protobuf.TimestampOrBuilder getLastDiscoverTimeOrBuilder() { + if (lastDiscoverTimeBuilder_ != null) { + return lastDiscoverTimeBuilder_.getMessageOrBuilder(); + } else { + return lastDiscoverTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastDiscoverTime_; + } + } + + /** + * + * + *
+     * Time the asset was last discovered (by asset management/discoverability
+     * software).
+     * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastDiscoverTimeFieldBuilder() { + if (lastDiscoverTimeBuilder_ == null) { + lastDiscoverTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastDiscoverTime(), getParentForChildren(), isClean()); + lastDiscoverTime_ = null; + } + return lastDiscoverTimeBuilder_; + } + + private com.google.protobuf.Timestamp systemLastUpdateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + systemLastUpdateTimeBuilder_; + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + * + * @return Whether the systemLastUpdateTime field is set. + */ + public boolean hasSystemLastUpdateTime() { + return ((bitField0_ & 0x00020000) != 0); + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + * + * @return The systemLastUpdateTime. + */ + public com.google.protobuf.Timestamp getSystemLastUpdateTime() { + if (systemLastUpdateTimeBuilder_ == null) { + return systemLastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : systemLastUpdateTime_; + } else { + return systemLastUpdateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + public Builder setSystemLastUpdateTime(com.google.protobuf.Timestamp value) { + if (systemLastUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + systemLastUpdateTime_ = value; + } else { + systemLastUpdateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00020000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + public Builder setSystemLastUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (systemLastUpdateTimeBuilder_ == null) { + systemLastUpdateTime_ = builderForValue.build(); + } else { + systemLastUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00020000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + public Builder mergeSystemLastUpdateTime(com.google.protobuf.Timestamp value) { + if (systemLastUpdateTimeBuilder_ == null) { + if (((bitField0_ & 0x00020000) != 0) + && systemLastUpdateTime_ != null + && systemLastUpdateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getSystemLastUpdateTimeBuilder().mergeFrom(value); + } else { + systemLastUpdateTime_ = value; + } + } else { + systemLastUpdateTimeBuilder_.mergeFrom(value); + } + if (systemLastUpdateTime_ != null) { + bitField0_ |= 0x00020000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + public Builder clearSystemLastUpdateTime() { + bitField0_ = (bitField0_ & ~0x00020000); + systemLastUpdateTime_ = null; + if (systemLastUpdateTimeBuilder_ != null) { + systemLastUpdateTimeBuilder_.dispose(); + systemLastUpdateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + public com.google.protobuf.Timestamp.Builder getSystemLastUpdateTimeBuilder() { + bitField0_ |= 0x00020000; + onChanged(); + return internalGetSystemLastUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + public com.google.protobuf.TimestampOrBuilder getSystemLastUpdateTimeOrBuilder() { + if (systemLastUpdateTimeBuilder_ != null) { + return systemLastUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return systemLastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : systemLastUpdateTime_; + } + } + + /** + * + * + *
+     * Time the asset system or OS was last updated.
+     * For all other operations that are not system updates (such as resizing a
+     * VM), use Attribute.last_update_time.
+     * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetSystemLastUpdateTimeFieldBuilder() { + if (systemLastUpdateTimeBuilder_ == null) { + systemLastUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getSystemLastUpdateTime(), getParentForChildren(), isClean()); + systemLastUpdateTime_ = null; + } + return systemLastUpdateTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastBootTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastBootTimeBuilder_; + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + * + * @return Whether the lastBootTime field is set. + */ + public boolean hasLastBootTime() { + return ((bitField0_ & 0x00040000) != 0); + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + * + * @return The lastBootTime. + */ + public com.google.protobuf.Timestamp getLastBootTime() { + if (lastBootTimeBuilder_ == null) { + return lastBootTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastBootTime_; + } else { + return lastBootTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + public Builder setLastBootTime(com.google.protobuf.Timestamp value) { + if (lastBootTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastBootTime_ = value; + } else { + lastBootTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + public Builder setLastBootTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastBootTimeBuilder_ == null) { + lastBootTime_ = builderForValue.build(); + } else { + lastBootTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + public Builder mergeLastBootTime(com.google.protobuf.Timestamp value) { + if (lastBootTimeBuilder_ == null) { + if (((bitField0_ & 0x00040000) != 0) + && lastBootTime_ != null + && lastBootTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastBootTimeBuilder().mergeFrom(value); + } else { + lastBootTime_ = value; + } + } else { + lastBootTimeBuilder_.mergeFrom(value); + } + if (lastBootTime_ != null) { + bitField0_ |= 0x00040000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + public Builder clearLastBootTime() { + bitField0_ = (bitField0_ & ~0x00040000); + lastBootTime_ = null; + if (lastBootTimeBuilder_ != null) { + lastBootTimeBuilder_.dispose(); + lastBootTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + public com.google.protobuf.Timestamp.Builder getLastBootTimeBuilder() { + bitField0_ |= 0x00040000; + onChanged(); + return internalGetLastBootTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + public com.google.protobuf.TimestampOrBuilder getLastBootTimeOrBuilder() { + if (lastBootTimeBuilder_ != null) { + return lastBootTimeBuilder_.getMessageOrBuilder(); + } else { + return lastBootTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastBootTime_; + } + } + + /** + * + * + *
+     * Time the asset was last boot started.
+     * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastBootTimeFieldBuilder() { + if (lastBootTimeBuilder_ == null) { + lastBootTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastBootTime(), getParentForChildren(), isClean()); + lastBootTime_ = null; + } + return lastBootTimeBuilder_; + } + + private java.util.List labels_ = java.util.Collections.emptyList(); + + private void ensureLabelsIsMutable() { + if (!((bitField0_ & 0x00080000) != 0)) { + labels_ = new java.util.ArrayList(labels_); + bitField0_ |= 0x00080000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Label, + com.google.backstory.Label.Builder, + com.google.backstory.LabelOrBuilder> + labelsBuilder_; + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public java.util.List getLabelsList() { + if (labelsBuilder_ == null) { + return java.util.Collections.unmodifiableList(labels_); + } else { + return labelsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public int getLabelsCount() { + if (labelsBuilder_ == null) { + return labels_.size(); + } else { + return labelsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.Label getLabels(int index) { + if (labelsBuilder_ == null) { + return labels_.get(index); + } else { + return labelsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setLabels(int index, com.google.backstory.Label value) { + if (labelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureLabelsIsMutable(); + labels_.set(index, value); + onChanged(); + } else { + labelsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setLabels(int index, com.google.backstory.Label.Builder builderForValue) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.set(index, builderForValue.build()); + onChanged(); + } else { + labelsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder addLabels(com.google.backstory.Label value) { + if (labelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureLabelsIsMutable(); + labels_.add(value); + onChanged(); + } else { + labelsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder addLabels(int index, com.google.backstory.Label value) { + if (labelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureLabelsIsMutable(); + labels_.add(index, value); + onChanged(); + } else { + labelsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder addLabels(com.google.backstory.Label.Builder builderForValue) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.add(builderForValue.build()); + onChanged(); + } else { + labelsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder addLabels(int index, com.google.backstory.Label.Builder builderForValue) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.add(index, builderForValue.build()); + onChanged(); + } else { + labelsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder addAllLabels(java.lang.Iterable values) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, labels_); + onChanged(); + } else { + labelsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder clearLabels() { + if (labelsBuilder_ == null) { + labels_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00080000); + onChanged(); + } else { + labelsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder removeLabels(int index) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.remove(index); + onChanged(); + } else { + labelsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.Label.Builder getLabelsBuilder(int index) { + return internalGetLabelsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.LabelOrBuilder getLabelsOrBuilder(int index) { + if (labelsBuilder_ == null) { + return labels_.get(index); + } else { + return labelsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public java.util.List getLabelsOrBuilderList() { + if (labelsBuilder_ != null) { + return labelsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(labels_); + } + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.Label.Builder addLabelsBuilder() { + return internalGetLabelsFieldBuilder() + .addBuilder(com.google.backstory.Label.getDefaultInstance()); + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.Label.Builder addLabelsBuilder(int index) { + return internalGetLabelsFieldBuilder() + .addBuilder(index, com.google.backstory.Label.getDefaultInstance()); + } + + /** + * + * + *
+     * Metadata labels for the asset.
+     * Deprecated: labels should be populated in Attribute as generic metadata.
+     * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + public java.util.List getLabelsBuilderList() { + return internalGetLabelsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Label, + com.google.backstory.Label.Builder, + com.google.backstory.LabelOrBuilder> + internalGetLabelsFieldBuilder() { + if (labelsBuilder_ == null) { + labelsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Label, + com.google.backstory.Label.Builder, + com.google.backstory.LabelOrBuilder>( + labels_, ((bitField0_ & 0x00080000) != 0), getParentForChildren(), isClean()); + labels_ = null; + } + return labelsBuilder_; + } + + private int deploymentStatus_ = 0; + + /** + * + * + *
+     * The deployment status of the asset for device lifecycle purposes.
+     * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return The enum numeric value on the wire for deploymentStatus. + */ + @java.lang.Override + public int getDeploymentStatusValue() { + return deploymentStatus_; + } + + /** + * + * + *
+     * The deployment status of the asset for device lifecycle purposes.
+     * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @param value The enum numeric value on the wire for deploymentStatus to set. + * @return This builder for chaining. + */ + public Builder setDeploymentStatusValue(int value) { + deploymentStatus_ = value; + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The deployment status of the asset for device lifecycle purposes.
+     * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return The deploymentStatus. + */ + @java.lang.Override + public com.google.backstory.Asset.DeploymentStatus getDeploymentStatus() { + com.google.backstory.Asset.DeploymentStatus result = + com.google.backstory.Asset.DeploymentStatus.forNumber(deploymentStatus_); + return result == null ? com.google.backstory.Asset.DeploymentStatus.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The deployment status of the asset for device lifecycle purposes.
+     * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @param value The deploymentStatus to set. + * @return This builder for chaining. + */ + public Builder setDeploymentStatus(com.google.backstory.Asset.DeploymentStatus value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00100000; + deploymentStatus_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The deployment status of the asset for device lifecycle purposes.
+     * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return This builder for chaining. + */ + public Builder clearDeploymentStatus() { + bitField0_ = (bitField0_ & ~0x00100000); + deploymentStatus_ = 0; + onChanged(); + return this; + } + + private java.util.List vulnerabilities_ = + java.util.Collections.emptyList(); + + private void ensureVulnerabilitiesIsMutable() { + if (!((bitField0_ & 0x00200000) != 0)) { + vulnerabilities_ = + new java.util.ArrayList(vulnerabilities_); + bitField0_ |= 0x00200000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Vulnerability, + com.google.backstory.Vulnerability.Builder, + com.google.backstory.VulnerabilityOrBuilder> + vulnerabilitiesBuilder_; + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public java.util.List getVulnerabilitiesList() { + if (vulnerabilitiesBuilder_ == null) { + return java.util.Collections.unmodifiableList(vulnerabilities_); + } else { + return vulnerabilitiesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public int getVulnerabilitiesCount() { + if (vulnerabilitiesBuilder_ == null) { + return vulnerabilities_.size(); + } else { + return vulnerabilitiesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public com.google.backstory.Vulnerability getVulnerabilities(int index) { + if (vulnerabilitiesBuilder_ == null) { + return vulnerabilities_.get(index); + } else { + return vulnerabilitiesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder setVulnerabilities(int index, com.google.backstory.Vulnerability value) { + if (vulnerabilitiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.set(index, value); + onChanged(); + } else { + vulnerabilitiesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder setVulnerabilities( + int index, com.google.backstory.Vulnerability.Builder builderForValue) { + if (vulnerabilitiesBuilder_ == null) { + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.set(index, builderForValue.build()); + onChanged(); + } else { + vulnerabilitiesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder addVulnerabilities(com.google.backstory.Vulnerability value) { + if (vulnerabilitiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.add(value); + onChanged(); + } else { + vulnerabilitiesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder addVulnerabilities(int index, com.google.backstory.Vulnerability value) { + if (vulnerabilitiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.add(index, value); + onChanged(); + } else { + vulnerabilitiesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder addVulnerabilities(com.google.backstory.Vulnerability.Builder builderForValue) { + if (vulnerabilitiesBuilder_ == null) { + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.add(builderForValue.build()); + onChanged(); + } else { + vulnerabilitiesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder addVulnerabilities( + int index, com.google.backstory.Vulnerability.Builder builderForValue) { + if (vulnerabilitiesBuilder_ == null) { + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.add(index, builderForValue.build()); + onChanged(); + } else { + vulnerabilitiesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder addAllVulnerabilities( + java.lang.Iterable values) { + if (vulnerabilitiesBuilder_ == null) { + ensureVulnerabilitiesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, vulnerabilities_); + onChanged(); + } else { + vulnerabilitiesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder clearVulnerabilities() { + if (vulnerabilitiesBuilder_ == null) { + vulnerabilities_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00200000); + onChanged(); + } else { + vulnerabilitiesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public Builder removeVulnerabilities(int index) { + if (vulnerabilitiesBuilder_ == null) { + ensureVulnerabilitiesIsMutable(); + vulnerabilities_.remove(index); + onChanged(); + } else { + vulnerabilitiesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public com.google.backstory.Vulnerability.Builder getVulnerabilitiesBuilder(int index) { + return internalGetVulnerabilitiesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public com.google.backstory.VulnerabilityOrBuilder getVulnerabilitiesOrBuilder(int index) { + if (vulnerabilitiesBuilder_ == null) { + return vulnerabilities_.get(index); + } else { + return vulnerabilitiesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public java.util.List + getVulnerabilitiesOrBuilderList() { + if (vulnerabilitiesBuilder_ != null) { + return vulnerabilitiesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(vulnerabilities_); + } + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public com.google.backstory.Vulnerability.Builder addVulnerabilitiesBuilder() { + return internalGetVulnerabilitiesFieldBuilder() + .addBuilder(com.google.backstory.Vulnerability.getDefaultInstance()); + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public com.google.backstory.Vulnerability.Builder addVulnerabilitiesBuilder(int index) { + return internalGetVulnerabilitiesFieldBuilder() + .addBuilder(index, com.google.backstory.Vulnerability.getDefaultInstance()); + } + + /** + * + * + *
+     * Vulnerabilities discovered on asset.
+     * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + public java.util.List + getVulnerabilitiesBuilderList() { + return internalGetVulnerabilitiesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Vulnerability, + com.google.backstory.Vulnerability.Builder, + com.google.backstory.VulnerabilityOrBuilder> + internalGetVulnerabilitiesFieldBuilder() { + if (vulnerabilitiesBuilder_ == null) { + vulnerabilitiesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Vulnerability, + com.google.backstory.Vulnerability.Builder, + com.google.backstory.VulnerabilityOrBuilder>( + vulnerabilities_, + ((bitField0_ & 0x00200000) != 0), + getParentForChildren(), + isClean()); + vulnerabilities_ = null; + } + return vulnerabilitiesBuilder_; + } + + private com.google.backstory.Attribute attribute_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Attribute, + com.google.backstory.Attribute.Builder, + com.google.backstory.AttributeOrBuilder> + attributeBuilder_; + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + * + * @return Whether the attribute field is set. + */ + public boolean hasAttribute() { + return ((bitField0_ & 0x00400000) != 0); + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + * + * @return The attribute. + */ + public com.google.backstory.Attribute getAttribute() { + if (attributeBuilder_ == null) { + return attribute_ == null + ? com.google.backstory.Attribute.getDefaultInstance() + : attribute_; + } else { + return attributeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + public Builder setAttribute(com.google.backstory.Attribute value) { + if (attributeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + attribute_ = value; + } else { + attributeBuilder_.setMessage(value); + } + bitField0_ |= 0x00400000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + public Builder setAttribute(com.google.backstory.Attribute.Builder builderForValue) { + if (attributeBuilder_ == null) { + attribute_ = builderForValue.build(); + } else { + attributeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00400000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + public Builder mergeAttribute(com.google.backstory.Attribute value) { + if (attributeBuilder_ == null) { + if (((bitField0_ & 0x00400000) != 0) + && attribute_ != null + && attribute_ != com.google.backstory.Attribute.getDefaultInstance()) { + getAttributeBuilder().mergeFrom(value); + } else { + attribute_ = value; + } + } else { + attributeBuilder_.mergeFrom(value); + } + if (attribute_ != null) { + bitField0_ |= 0x00400000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + public Builder clearAttribute() { + bitField0_ = (bitField0_ & ~0x00400000); + attribute_ = null; + if (attributeBuilder_ != null) { + attributeBuilder_.dispose(); + attributeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + public com.google.backstory.Attribute.Builder getAttributeBuilder() { + bitField0_ |= 0x00400000; + onChanged(); + return internalGetAttributeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + public com.google.backstory.AttributeOrBuilder getAttributeOrBuilder() { + if (attributeBuilder_ != null) { + return attributeBuilder_.getMessageOrBuilder(); + } else { + return attribute_ == null + ? com.google.backstory.Attribute.getDefaultInstance() + : attribute_; + } + } + + /** + * + * + *
+     * Generic entity metadata attributes of the asset.
+     * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Attribute, + com.google.backstory.Attribute.Builder, + com.google.backstory.AttributeOrBuilder> + internalGetAttributeFieldBuilder() { + if (attributeBuilder_ == null) { + attributeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Attribute, + com.google.backstory.Attribute.Builder, + com.google.backstory.AttributeOrBuilder>( + getAttribute(), getParentForChildren(), isClean()); + attribute_ = null; + } + return attributeBuilder_; + } + + private com.google.backstory.WmiPersistenceItem wmiPersistenceItem_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.WmiPersistenceItem, + com.google.backstory.WmiPersistenceItem.Builder, + com.google.backstory.WmiPersistenceItemOrBuilder> + wmiPersistenceItemBuilder_; + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + * + * @return Whether the wmiPersistenceItem field is set. + */ + public boolean hasWmiPersistenceItem() { + return ((bitField0_ & 0x00800000) != 0); + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + * + * @return The wmiPersistenceItem. + */ + public com.google.backstory.WmiPersistenceItem getWmiPersistenceItem() { + if (wmiPersistenceItemBuilder_ == null) { + return wmiPersistenceItem_ == null + ? com.google.backstory.WmiPersistenceItem.getDefaultInstance() + : wmiPersistenceItem_; + } else { + return wmiPersistenceItemBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + public Builder setWmiPersistenceItem(com.google.backstory.WmiPersistenceItem value) { + if (wmiPersistenceItemBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + wmiPersistenceItem_ = value; + } else { + wmiPersistenceItemBuilder_.setMessage(value); + } + bitField0_ |= 0x00800000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + public Builder setWmiPersistenceItem( + com.google.backstory.WmiPersistenceItem.Builder builderForValue) { + if (wmiPersistenceItemBuilder_ == null) { + wmiPersistenceItem_ = builderForValue.build(); + } else { + wmiPersistenceItemBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00800000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + public Builder mergeWmiPersistenceItem(com.google.backstory.WmiPersistenceItem value) { + if (wmiPersistenceItemBuilder_ == null) { + if (((bitField0_ & 0x00800000) != 0) + && wmiPersistenceItem_ != null + && wmiPersistenceItem_ + != com.google.backstory.WmiPersistenceItem.getDefaultInstance()) { + getWmiPersistenceItemBuilder().mergeFrom(value); + } else { + wmiPersistenceItem_ = value; + } + } else { + wmiPersistenceItemBuilder_.mergeFrom(value); + } + if (wmiPersistenceItem_ != null) { + bitField0_ |= 0x00800000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + public Builder clearWmiPersistenceItem() { + bitField0_ = (bitField0_ & ~0x00800000); + wmiPersistenceItem_ = null; + if (wmiPersistenceItemBuilder_ != null) { + wmiPersistenceItemBuilder_.dispose(); + wmiPersistenceItemBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + public com.google.backstory.WmiPersistenceItem.Builder getWmiPersistenceItemBuilder() { + bitField0_ |= 0x00800000; + onChanged(); + return internalGetWmiPersistenceItemFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + public com.google.backstory.WmiPersistenceItemOrBuilder getWmiPersistenceItemOrBuilder() { + if (wmiPersistenceItemBuilder_ != null) { + return wmiPersistenceItemBuilder_.getMessageOrBuilder(); + } else { + return wmiPersistenceItem_ == null + ? com.google.backstory.WmiPersistenceItem.getDefaultInstance() + : wmiPersistenceItem_; + } + } + + /** + * + * + *
+     * Information about a WMI persistence item.
+     * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.WmiPersistenceItem, + com.google.backstory.WmiPersistenceItem.Builder, + com.google.backstory.WmiPersistenceItemOrBuilder> + internalGetWmiPersistenceItemFieldBuilder() { + if (wmiPersistenceItemBuilder_ == null) { + wmiPersistenceItemBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.WmiPersistenceItem, + com.google.backstory.WmiPersistenceItem.Builder, + com.google.backstory.WmiPersistenceItemOrBuilder>( + getWmiPersistenceItem(), getParentForChildren(), isClean()); + wmiPersistenceItem_ = null; + } + return wmiPersistenceItemBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Asset) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Asset) + private static final com.google.backstory.Asset DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Asset(); + } + + public static com.google.backstory.Asset getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Asset parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Asset getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java new file mode 100644 index 000000000000..7d349dc17049 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java @@ -0,0 +1,1005 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AssetOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Asset) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+   * similar).
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string product_object_id = 1; + * + * @return The productObjectId. + */ + java.lang.String getProductObjectId(); + + /** + * + * + *
+   * A vendor-specific identifier to uniquely identify the entity (a GUID  or
+   * similar).
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string product_object_id = 1; + * + * @return The bytes for productObjectId. + */ + com.google.protobuf.ByteString getProductObjectIdBytes(); + + /** + * + * + *
+   * Asset hostname or domain name field.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string hostname = 2; + * + * @return The hostname. + */ + java.lang.String getHostname(); + + /** + * + * + *
+   * Asset hostname or domain name field.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string hostname = 2; + * + * @return The bytes for hostname. + */ + com.google.protobuf.ByteString getHostnameBytes(); + + /** + * + * + *
+   * The asset ID. Value must contain the ':' character. For example,
+   * cs:abcdd23434.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string asset_id = 3; + * + * @return The assetId. + */ + java.lang.String getAssetId(); + + /** + * + * + *
+   * The asset ID. Value must contain the ':' character. For example,
+   * cs:abcdd23434.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * string asset_id = 3; + * + * @return The bytes for assetId. + */ + com.google.protobuf.ByteString getAssetIdBytes(); + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @return A list containing the ip. + */ + java.util.List getIpList(); + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @return The count of ip. + */ + int getIpCount(); + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @param index The index of the element to return. + * @return The ip at the given index. + */ + java.lang.String getIp(int index); + + /** + * + * + *
+   * A list of IP addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string ip = 4; + * + * @param index The index of the value to return. + * @return The bytes of the ip at the given index. + */ + com.google.protobuf.ByteString getIpBytes(int index); + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @return A list containing the mac. + */ + java.util.List getMacList(); + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @return The count of mac. + */ + int getMacCount(); + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @param index The index of the element to return. + * @return The mac at the given index. + */ + java.lang.String getMac(int index); + + /** + * + * + *
+   * List of MAC addresses associated with an asset.
+   * This field can be used as an entity indicator for asset entities.
+   * 
+ * + * repeated string mac = 5; + * + * @param index The index of the value to return. + * @return The bytes of the mac at the given index. + */ + com.google.protobuf.ByteString getMacBytes(int index); + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @return A list containing the natIp. + */ + java.util.List getNatIpList(); + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @return The count of natIp. + */ + int getNatIpCount(); + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index of the element to return. + * @return The natIp at the given index. + */ + java.lang.String getNatIp(int index); + + /** + * + * + *
+   * List of NAT IP addresses associated with an asset.
+   * 
+ * + * repeated string nat_ip = 22; + * + * @param index The index of the value to return. + * @return The bytes of the natIp at the given index. + */ + com.google.protobuf.ByteString getNatIpBytes(int index); + + /** + * + * + *
+   * The first observed time for an asset.
+   * The value is calculated on the basis of the
+   * first time the identifier was observed.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + * + * @return Whether the firstSeenTime field is set. + */ + boolean hasFirstSeenTime(); + + /** + * + * + *
+   * The first observed time for an asset.
+   * The value is calculated on the basis of the
+   * first time the identifier was observed.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + * + * @return The firstSeenTime. + */ + com.google.protobuf.Timestamp getFirstSeenTime(); + + /** + * + * + *
+   * The first observed time for an asset.
+   * The value is calculated on the basis of the
+   * first time the identifier was observed.
+   * 
+ * + * .google.protobuf.Timestamp first_seen_time = 23; + */ + com.google.protobuf.TimestampOrBuilder getFirstSeenTimeOrBuilder(); + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + java.util.List getHardwareList(); + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + com.google.backstory.Hardware getHardware(int index); + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + int getHardwareCount(); + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + java.util.List getHardwareOrBuilderList(); + + /** + * + * + *
+   * The asset hardware specifications.
+   * 
+ * + * repeated .google.backstory.Hardware hardware = 6; + */ + com.google.backstory.HardwareOrBuilder getHardwareOrBuilder(int index); + + /** + * + * + *
+   * The asset operating system platform software.
+   * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + * + * @return Whether the platformSoftware field is set. + */ + boolean hasPlatformSoftware(); + + /** + * + * + *
+   * The asset operating system platform software.
+   * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + * + * @return The platformSoftware. + */ + com.google.backstory.PlatformSoftware getPlatformSoftware(); + + /** + * + * + *
+   * The asset operating system platform software.
+   * 
+ * + * .google.backstory.PlatformSoftware platform_software = 7; + */ + com.google.backstory.PlatformSoftwareOrBuilder getPlatformSoftwareOrBuilder(); + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + java.util.List getSoftwareList(); + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + com.google.backstory.Software getSoftware(int index); + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + int getSoftwareCount(); + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + java.util.List getSoftwareOrBuilderList(); + + /** + * + * + *
+   * The asset software details.
+   * 
+ * + * repeated .google.backstory.Software software = 17; + */ + com.google.backstory.SoftwareOrBuilder getSoftwareOrBuilder(int index); + + /** + * + * + *
+   * Location of the asset.
+   * 
+ * + * .google.backstory.Location location = 8; + * + * @return Whether the location field is set. + */ + boolean hasLocation(); + + /** + * + * + *
+   * Location of the asset.
+   * 
+ * + * .google.backstory.Location location = 8; + * + * @return The location. + */ + com.google.backstory.Location getLocation(); + + /** + * + * + *
+   * Location of the asset.
+   * 
+ * + * .google.backstory.Location location = 8; + */ + com.google.backstory.LocationOrBuilder getLocationOrBuilder(); + + /** + * + * + *
+   * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+   * 
+ * + * string category = 9; + * + * @return The category. + */ + java.lang.String getCategory(); + + /** + * + * + *
+   * The category of the asset (e.g. "End User Asset", "Workstation", "Server").
+   * 
+ * + * string category = 9; + * + * @return The bytes for category. + */ + com.google.protobuf.ByteString getCategoryBytes(); + + /** + * + * + *
+   * The type of the asset (e.g. workstation or laptop or server).
+   * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + + /** + * + * + *
+   * The type of the asset (e.g. workstation or laptop or server).
+   * 
+ * + * .google.backstory.Asset.AssetType type = 18; + * + * @return The type. + */ + com.google.backstory.Asset.AssetType getType(); + + /** + * + * + *
+   * The network domain of the asset (e.g. "corp.acme.com")
+   * 
+ * + * string network_domain = 10; + * + * @return The networkDomain. + */ + java.lang.String getNetworkDomain(); + + /** + * + * + *
+   * The network domain of the asset (e.g. "corp.acme.com")
+   * 
+ * + * string network_domain = 10; + * + * @return The bytes for networkDomain. + */ + com.google.protobuf.ByteString getNetworkDomainBytes(); + + /** + * + * + *
+   * Time the asset was created or provisioned.
+   * Deprecate: creation_time should be populated in Attribute as generic
+   * metadata.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + * + * @deprecated google.backstory.Asset.creation_time is deprecated. See backstory/udm.proto;l=4670 + * @return Whether the creationTime field is set. + */ + @java.lang.Deprecated + boolean hasCreationTime(); + + /** + * + * + *
+   * Time the asset was created or provisioned.
+   * Deprecate: creation_time should be populated in Attribute as generic
+   * metadata.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + * + * @deprecated google.backstory.Asset.creation_time is deprecated. See backstory/udm.proto;l=4670 + * @return The creationTime. + */ + @java.lang.Deprecated + com.google.protobuf.Timestamp getCreationTime(); + + /** + * + * + *
+   * Time the asset was created or provisioned.
+   * Deprecate: creation_time should be populated in Attribute as generic
+   * metadata.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 11 [deprecated = true]; + */ + @java.lang.Deprecated + com.google.protobuf.TimestampOrBuilder getCreationTimeOrBuilder(); + + /** + * + * + *
+   * Time the asset was first discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + * + * @return Whether the firstDiscoverTime field is set. + */ + boolean hasFirstDiscoverTime(); + + /** + * + * + *
+   * Time the asset was first discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + * + * @return The firstDiscoverTime. + */ + com.google.protobuf.Timestamp getFirstDiscoverTime(); + + /** + * + * + *
+   * Time the asset was first discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp first_discover_time = 12; + */ + com.google.protobuf.TimestampOrBuilder getFirstDiscoverTimeOrBuilder(); + + /** + * + * + *
+   * Time the asset was last discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + * + * @return Whether the lastDiscoverTime field is set. + */ + boolean hasLastDiscoverTime(); + + /** + * + * + *
+   * Time the asset was last discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + * + * @return The lastDiscoverTime. + */ + com.google.protobuf.Timestamp getLastDiscoverTime(); + + /** + * + * + *
+   * Time the asset was last discovered (by asset management/discoverability
+   * software).
+   * 
+ * + * .google.protobuf.Timestamp last_discover_time = 13; + */ + com.google.protobuf.TimestampOrBuilder getLastDiscoverTimeOrBuilder(); + + /** + * + * + *
+   * Time the asset system or OS was last updated.
+   * For all other operations that are not system updates (such as resizing a
+   * VM), use Attribute.last_update_time.
+   * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + * + * @return Whether the systemLastUpdateTime field is set. + */ + boolean hasSystemLastUpdateTime(); + + /** + * + * + *
+   * Time the asset system or OS was last updated.
+   * For all other operations that are not system updates (such as resizing a
+   * VM), use Attribute.last_update_time.
+   * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + * + * @return The systemLastUpdateTime. + */ + com.google.protobuf.Timestamp getSystemLastUpdateTime(); + + /** + * + * + *
+   * Time the asset system or OS was last updated.
+   * For all other operations that are not system updates (such as resizing a
+   * VM), use Attribute.last_update_time.
+   * 
+ * + * .google.protobuf.Timestamp system_last_update_time = 14; + */ + com.google.protobuf.TimestampOrBuilder getSystemLastUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Time the asset was last boot started.
+   * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + * + * @return Whether the lastBootTime field is set. + */ + boolean hasLastBootTime(); + + /** + * + * + *
+   * Time the asset was last boot started.
+   * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + * + * @return The lastBootTime. + */ + com.google.protobuf.Timestamp getLastBootTime(); + + /** + * + * + *
+   * Time the asset was last boot started.
+   * 
+ * + * .google.protobuf.Timestamp last_boot_time = 15; + */ + com.google.protobuf.TimestampOrBuilder getLastBootTimeOrBuilder(); + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + java.util.List getLabelsList(); + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + com.google.backstory.Label getLabels(int index); + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + int getLabelsCount(); + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + java.util.List getLabelsOrBuilderList(); + + /** + * + * + *
+   * Metadata labels for the asset.
+   * Deprecated: labels should be populated in Attribute as generic metadata.
+   * 
+ * + * repeated .google.backstory.Label labels = 16 [deprecated = true]; + */ + @java.lang.Deprecated + com.google.backstory.LabelOrBuilder getLabelsOrBuilder(int index); + + /** + * + * + *
+   * The deployment status of the asset for device lifecycle purposes.
+   * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return The enum numeric value on the wire for deploymentStatus. + */ + int getDeploymentStatusValue(); + + /** + * + * + *
+   * The deployment status of the asset for device lifecycle purposes.
+   * 
+ * + * .google.backstory.Asset.DeploymentStatus deployment_status = 19; + * + * @return The deploymentStatus. + */ + com.google.backstory.Asset.DeploymentStatus getDeploymentStatus(); + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + java.util.List getVulnerabilitiesList(); + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + com.google.backstory.Vulnerability getVulnerabilities(int index); + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + int getVulnerabilitiesCount(); + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + java.util.List + getVulnerabilitiesOrBuilderList(); + + /** + * + * + *
+   * Vulnerabilities discovered on asset.
+   * 
+ * + * repeated .google.backstory.Vulnerability vulnerabilities = 21; + */ + com.google.backstory.VulnerabilityOrBuilder getVulnerabilitiesOrBuilder(int index); + + /** + * + * + *
+   * Generic entity metadata attributes of the asset.
+   * 
+ * + * .google.backstory.Attribute attribute = 20; + * + * @return Whether the attribute field is set. + */ + boolean hasAttribute(); + + /** + * + * + *
+   * Generic entity metadata attributes of the asset.
+   * 
+ * + * .google.backstory.Attribute attribute = 20; + * + * @return The attribute. + */ + com.google.backstory.Attribute getAttribute(); + + /** + * + * + *
+   * Generic entity metadata attributes of the asset.
+   * 
+ * + * .google.backstory.Attribute attribute = 20; + */ + com.google.backstory.AttributeOrBuilder getAttributeOrBuilder(); + + /** + * + * + *
+   * Information about a WMI persistence item.
+   * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + * + * @return Whether the wmiPersistenceItem field is set. + */ + boolean hasWmiPersistenceItem(); + + /** + * + * + *
+   * Information about a WMI persistence item.
+   * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + * + * @return The wmiPersistenceItem. + */ + com.google.backstory.WmiPersistenceItem getWmiPersistenceItem(); + + /** + * + * + *
+   * Information about a WMI persistence item.
+   * 
+ * + * .google.backstory.WmiPersistenceItem wmi_persistence_item = 24; + */ + com.google.backstory.WmiPersistenceItemOrBuilder getWmiPersistenceItemOrBuilder(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/AtiPrioritization.java b/java-backstory/src/main/java/com/google/backstory/AtiPrioritization.java new file mode 100644 index 000000000000..a79d259ab51c --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AtiPrioritization.java @@ -0,0 +1,3128 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/entity.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * AtiPrioritization contains various fields used to calculate a priority score
+ * for an entity identified as a threat.
+ * 
+ * + * Protobuf type {@code google.backstory.AtiPrioritization} + */ +@com.google.protobuf.Generated +public final class AtiPrioritization extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.AtiPrioritization) + AtiPrioritizationOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AtiPrioritization"); + } + + // Use AtiPrioritization.newBuilder() to construct. + private AtiPrioritization(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AtiPrioritization() { + attributedMalware_ = java.util.Collections.emptyList(); + attributedThreatActors_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.EntityProto + .internal_static_google_backstory_AtiPrioritization_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.EntityProto + .internal_static_google_backstory_AtiPrioritization_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AtiPrioritization.class, + com.google.backstory.AtiPrioritization.Builder.class); + } + + private int bitField0_; + public static final int GTI_VERDICT_FIELD_NUMBER = 1; + private int gtiVerdict_ = 0; + + /** + * + * + *
+   * The confidence score from "GTI verdict" source.
+   * 
+ * + * int32 gti_verdict = 1; + * + * @return The gtiVerdict. + */ + @java.lang.Override + public int getGtiVerdict() { + return gtiVerdict_; + } + + public static final int GTI_SEVERITY_FIELD_NUMBER = 2; + private int gtiSeverity_ = 0; + + /** + * + * + *
+   * The confidence score from "GTI severity" source.
+   * 
+ * + * int32 gti_severity = 2; + * + * @return The gtiSeverity. + */ + @java.lang.Override + public int getGtiSeverity() { + return gtiSeverity_; + } + + public static final int GTI_THREAT_SCORE_FIELD_NUMBER = 3; + private int gtiThreatScore_ = 0; + + /** + * + * + *
+   * The confidence score from "GTI threat score" source.
+   * 
+ * + * int32 gti_threat_score = 3; + * + * @return The gtiThreatScore. + */ + @java.lang.Override + public int getGtiThreatScore() { + return gtiThreatScore_; + } + + public static final int MANDIANT_ANALYST_CONFIDENCE_FIELD_NUMBER = 4; + private int mandiantAnalystConfidence_ = 0; + + /** + * + * + *
+   * The confidence score from "Mandiant Analyst Intel" source.
+   * 
+ * + * int32 mandiant_analyst_confidence = 4; + * + * @return The mandiantAnalystConfidence. + */ + @java.lang.Override + public int getMandiantAnalystConfidence() { + return mandiantAnalystConfidence_; + } + + public static final int GTI_UPDATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp gtiUpdateTime_; + + /** + * + * + *
+   * Timestamp of the latest update for GTI verdict, severity, or threat score.
+   * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + * + * @return Whether the gtiUpdateTime field is set. + */ + @java.lang.Override + public boolean hasGtiUpdateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Timestamp of the latest update for GTI verdict, severity, or threat score.
+   * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + * + * @return The gtiUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getGtiUpdateTime() { + return gtiUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : gtiUpdateTime_; + } + + /** + * + * + *
+   * Timestamp of the latest update for GTI verdict, severity, or threat score.
+   * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getGtiUpdateTimeOrBuilder() { + return gtiUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : gtiUpdateTime_; + } + + public static final int ACTIVE_IR_FIELD_NUMBER = 6; + private boolean activeIr_ = false; + + /** + * + * + *
+   * Whether one or more Mandiant incident response customers had this indicator
+   * in their environment.
+   * 
+ * + * bool active_ir = 6; + * + * @return The activeIr. + */ + @java.lang.Override + public boolean getActiveIr() { + return activeIr_; + } + + public static final int ACTIVE_IR_FIRST_TAGGED_TIME_FIELD_NUMBER = 7; + private com.google.protobuf.Timestamp activeIrFirstTaggedTime_; + + /** + * + * + *
+   * The timestamp of the first time an active IR was applied to this entity.
+   * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + * + * @return Whether the activeIrFirstTaggedTime field is set. + */ + @java.lang.Override + public boolean hasActiveIrFirstTaggedTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The timestamp of the first time an active IR was applied to this entity.
+   * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + * + * @return The activeIrFirstTaggedTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getActiveIrFirstTaggedTime() { + return activeIrFirstTaggedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : activeIrFirstTaggedTime_; + } + + /** + * + * + *
+   * The timestamp of the first time an active IR was applied to this entity.
+   * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getActiveIrFirstTaggedTimeOrBuilder() { + return activeIrFirstTaggedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : activeIrFirstTaggedTime_; + } + + public static final int GLOBAL_CUSTOMER_COUNT_FIELD_NUMBER = 8; + private long globalCustomerCount_ = 0L; + + /** + * + * + *
+   * Global customer count over the last 30 days
+   * 
+ * + * int64 global_customer_count = 8; + * + * @return The globalCustomerCount. + */ + @java.lang.Override + public long getGlobalCustomerCount() { + return globalCustomerCount_; + } + + public static final int GLOBAL_HIT_COUNT_FIELD_NUMBER = 9; + private long globalHitCount_ = 0L; + + /** + * + * + *
+   * Global hit count over the last 30 days
+   * 
+ * + * int64 global_hit_count = 9; + * + * @return The globalHitCount. + */ + @java.lang.Override + public long getGlobalHitCount() { + return globalHitCount_; + } + + public static final int EXCLUSIVE_FIELD_NUMBER = 10; + private boolean exclusive_ = false; + + /** + * + * + *
+   * Whether the indicator is being used by a maximum of one threat actor.
+   * 
+ * + * bool exclusive = 10; + * + * @return The exclusive. + */ + @java.lang.Override + public boolean getExclusive() { + return exclusive_; + } + + public static final int OSINT_FIELD_NUMBER = 11; + private boolean osint_ = false; + + /** + * + * + *
+   * Whether the indicator details are available in open source.
+   * 
+ * + * bool osint = 11; + * + * @return The osint. + */ + @java.lang.Override + public boolean getOsint() { + return osint_; + } + + public static final int SCANNER_FIELD_NUMBER = 12; + private boolean scanner_ = false; + + /** + * + * + *
+   * Whether the indicator is a scanner.
+   * 
+ * + * bool scanner = 12; + * + * @return The scanner. + */ + @java.lang.Override + public boolean getScanner() { + return scanner_; + } + + public static final int REVIEWED_FIELD_NUMBER = 13; + private boolean reviewed_ = false; + + /** + * + * + *
+   * Whether the indicator verdict has passed review.
+   * 
+ * + * bool reviewed = 13; + * + * @return The reviewed. + */ + @java.lang.Override + public boolean getReviewed() { + return reviewed_; + } + + public static final int ATTRIBUTED_MALWARE_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private java.util.List attributedMalware_; + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + @java.lang.Override + public java.util.List + getAttributedMalwareList() { + return attributedMalware_; + } + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + @java.lang.Override + public java.util.List + getAttributedMalwareOrBuilderList() { + return attributedMalware_; + } + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + @java.lang.Override + public int getAttributedMalwareCount() { + return attributedMalware_.size(); + } + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + @java.lang.Override + public com.google.backstory.SecurityResult.Association getAttributedMalware(int index) { + return attributedMalware_.get(index); + } + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + @java.lang.Override + public com.google.backstory.SecurityResult.AssociationOrBuilder getAttributedMalwareOrBuilder( + int index) { + return attributedMalware_.get(index); + } + + public static final int ATTRIBUTED_THREAT_ACTORS_FIELD_NUMBER = 15; + + @SuppressWarnings("serial") + private java.util.List attributedThreatActors_; + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + @java.lang.Override + public java.util.List + getAttributedThreatActorsList() { + return attributedThreatActors_; + } + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + @java.lang.Override + public java.util.List + getAttributedThreatActorsOrBuilderList() { + return attributedThreatActors_; + } + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + @java.lang.Override + public int getAttributedThreatActorsCount() { + return attributedThreatActors_.size(); + } + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + @java.lang.Override + public com.google.backstory.SecurityResult.Association getAttributedThreatActors(int index) { + return attributedThreatActors_.get(index); + } + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + @java.lang.Override + public com.google.backstory.SecurityResult.AssociationOrBuilder + getAttributedThreatActorsOrBuilder(int index) { + return attributedThreatActors_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (gtiVerdict_ != 0) { + output.writeInt32(1, gtiVerdict_); + } + if (gtiSeverity_ != 0) { + output.writeInt32(2, gtiSeverity_); + } + if (gtiThreatScore_ != 0) { + output.writeInt32(3, gtiThreatScore_); + } + if (mandiantAnalystConfidence_ != 0) { + output.writeInt32(4, mandiantAnalystConfidence_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getGtiUpdateTime()); + } + if (activeIr_ != false) { + output.writeBool(6, activeIr_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(7, getActiveIrFirstTaggedTime()); + } + if (globalCustomerCount_ != 0L) { + output.writeInt64(8, globalCustomerCount_); + } + if (globalHitCount_ != 0L) { + output.writeInt64(9, globalHitCount_); + } + if (exclusive_ != false) { + output.writeBool(10, exclusive_); + } + if (osint_ != false) { + output.writeBool(11, osint_); + } + if (scanner_ != false) { + output.writeBool(12, scanner_); + } + if (reviewed_ != false) { + output.writeBool(13, reviewed_); + } + for (int i = 0; i < attributedMalware_.size(); i++) { + output.writeMessage(14, attributedMalware_.get(i)); + } + for (int i = 0; i < attributedThreatActors_.size(); i++) { + output.writeMessage(15, attributedThreatActors_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (gtiVerdict_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, gtiVerdict_); + } + if (gtiSeverity_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, gtiSeverity_); + } + if (gtiThreatScore_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, gtiThreatScore_); + } + if (mandiantAnalystConfidence_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(4, mandiantAnalystConfidence_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getGtiUpdateTime()); + } + if (activeIr_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, activeIr_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(7, getActiveIrFirstTaggedTime()); + } + if (globalCustomerCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, globalCustomerCount_); + } + if (globalHitCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(9, globalHitCount_); + } + if (exclusive_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(10, exclusive_); + } + if (osint_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, osint_); + } + if (scanner_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(12, scanner_); + } + if (reviewed_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(13, reviewed_); + } + for (int i = 0; i < attributedMalware_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(14, attributedMalware_.get(i)); + } + for (int i = 0; i < attributedThreatActors_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 15, attributedThreatActors_.get(i)); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.AtiPrioritization)) { + return super.equals(obj); + } + com.google.backstory.AtiPrioritization other = (com.google.backstory.AtiPrioritization) obj; + + if (getGtiVerdict() != other.getGtiVerdict()) return false; + if (getGtiSeverity() != other.getGtiSeverity()) return false; + if (getGtiThreatScore() != other.getGtiThreatScore()) return false; + if (getMandiantAnalystConfidence() != other.getMandiantAnalystConfidence()) return false; + if (hasGtiUpdateTime() != other.hasGtiUpdateTime()) return false; + if (hasGtiUpdateTime()) { + if (!getGtiUpdateTime().equals(other.getGtiUpdateTime())) return false; + } + if (getActiveIr() != other.getActiveIr()) return false; + if (hasActiveIrFirstTaggedTime() != other.hasActiveIrFirstTaggedTime()) return false; + if (hasActiveIrFirstTaggedTime()) { + if (!getActiveIrFirstTaggedTime().equals(other.getActiveIrFirstTaggedTime())) return false; + } + if (getGlobalCustomerCount() != other.getGlobalCustomerCount()) return false; + if (getGlobalHitCount() != other.getGlobalHitCount()) return false; + if (getExclusive() != other.getExclusive()) return false; + if (getOsint() != other.getOsint()) return false; + if (getScanner() != other.getScanner()) return false; + if (getReviewed() != other.getReviewed()) return false; + if (!getAttributedMalwareList().equals(other.getAttributedMalwareList())) return false; + if (!getAttributedThreatActorsList().equals(other.getAttributedThreatActorsList())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + GTI_VERDICT_FIELD_NUMBER; + hash = (53 * hash) + getGtiVerdict(); + hash = (37 * hash) + GTI_SEVERITY_FIELD_NUMBER; + hash = (53 * hash) + getGtiSeverity(); + hash = (37 * hash) + GTI_THREAT_SCORE_FIELD_NUMBER; + hash = (53 * hash) + getGtiThreatScore(); + hash = (37 * hash) + MANDIANT_ANALYST_CONFIDENCE_FIELD_NUMBER; + hash = (53 * hash) + getMandiantAnalystConfidence(); + if (hasGtiUpdateTime()) { + hash = (37 * hash) + GTI_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getGtiUpdateTime().hashCode(); + } + hash = (37 * hash) + ACTIVE_IR_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getActiveIr()); + if (hasActiveIrFirstTaggedTime()) { + hash = (37 * hash) + ACTIVE_IR_FIRST_TAGGED_TIME_FIELD_NUMBER; + hash = (53 * hash) + getActiveIrFirstTaggedTime().hashCode(); + } + hash = (37 * hash) + GLOBAL_CUSTOMER_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGlobalCustomerCount()); + hash = (37 * hash) + GLOBAL_HIT_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGlobalHitCount()); + hash = (37 * hash) + EXCLUSIVE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getExclusive()); + hash = (37 * hash) + OSINT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getOsint()); + hash = (37 * hash) + SCANNER_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getScanner()); + hash = (37 * hash) + REVIEWED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getReviewed()); + if (getAttributedMalwareCount() > 0) { + hash = (37 * hash) + ATTRIBUTED_MALWARE_FIELD_NUMBER; + hash = (53 * hash) + getAttributedMalwareList().hashCode(); + } + if (getAttributedThreatActorsCount() > 0) { + hash = (37 * hash) + ATTRIBUTED_THREAT_ACTORS_FIELD_NUMBER; + hash = (53 * hash) + getAttributedThreatActorsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.AtiPrioritization parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AtiPrioritization parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AtiPrioritization parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AtiPrioritization parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.AtiPrioritization parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AtiPrioritization parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.AtiPrioritization prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * AtiPrioritization contains various fields used to calculate a priority score
+   * for an entity identified as a threat.
+   * 
+ * + * Protobuf type {@code google.backstory.AtiPrioritization} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.AtiPrioritization) + com.google.backstory.AtiPrioritizationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.EntityProto + .internal_static_google_backstory_AtiPrioritization_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.EntityProto + .internal_static_google_backstory_AtiPrioritization_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AtiPrioritization.class, + com.google.backstory.AtiPrioritization.Builder.class); + } + + // Construct using com.google.backstory.AtiPrioritization.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGtiUpdateTimeFieldBuilder(); + internalGetActiveIrFirstTaggedTimeFieldBuilder(); + internalGetAttributedMalwareFieldBuilder(); + internalGetAttributedThreatActorsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + gtiVerdict_ = 0; + gtiSeverity_ = 0; + gtiThreatScore_ = 0; + mandiantAnalystConfidence_ = 0; + gtiUpdateTime_ = null; + if (gtiUpdateTimeBuilder_ != null) { + gtiUpdateTimeBuilder_.dispose(); + gtiUpdateTimeBuilder_ = null; + } + activeIr_ = false; + activeIrFirstTaggedTime_ = null; + if (activeIrFirstTaggedTimeBuilder_ != null) { + activeIrFirstTaggedTimeBuilder_.dispose(); + activeIrFirstTaggedTimeBuilder_ = null; + } + globalCustomerCount_ = 0L; + globalHitCount_ = 0L; + exclusive_ = false; + osint_ = false; + scanner_ = false; + reviewed_ = false; + if (attributedMalwareBuilder_ == null) { + attributedMalware_ = java.util.Collections.emptyList(); + } else { + attributedMalware_ = null; + attributedMalwareBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00002000); + if (attributedThreatActorsBuilder_ == null) { + attributedThreatActors_ = java.util.Collections.emptyList(); + } else { + attributedThreatActors_ = null; + attributedThreatActorsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00004000); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.EntityProto + .internal_static_google_backstory_AtiPrioritization_descriptor; + } + + @java.lang.Override + public com.google.backstory.AtiPrioritization getDefaultInstanceForType() { + return com.google.backstory.AtiPrioritization.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.AtiPrioritization build() { + com.google.backstory.AtiPrioritization result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.AtiPrioritization buildPartial() { + com.google.backstory.AtiPrioritization result = + new com.google.backstory.AtiPrioritization(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.AtiPrioritization result) { + if (attributedMalwareBuilder_ == null) { + if (((bitField0_ & 0x00002000) != 0)) { + attributedMalware_ = java.util.Collections.unmodifiableList(attributedMalware_); + bitField0_ = (bitField0_ & ~0x00002000); + } + result.attributedMalware_ = attributedMalware_; + } else { + result.attributedMalware_ = attributedMalwareBuilder_.build(); + } + if (attributedThreatActorsBuilder_ == null) { + if (((bitField0_ & 0x00004000) != 0)) { + attributedThreatActors_ = java.util.Collections.unmodifiableList(attributedThreatActors_); + bitField0_ = (bitField0_ & ~0x00004000); + } + result.attributedThreatActors_ = attributedThreatActors_; + } else { + result.attributedThreatActors_ = attributedThreatActorsBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.AtiPrioritization result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.gtiVerdict_ = gtiVerdict_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.gtiSeverity_ = gtiSeverity_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.gtiThreatScore_ = gtiThreatScore_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.mandiantAnalystConfidence_ = mandiantAnalystConfidence_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.gtiUpdateTime_ = + gtiUpdateTimeBuilder_ == null ? gtiUpdateTime_ : gtiUpdateTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.activeIr_ = activeIr_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.activeIrFirstTaggedTime_ = + activeIrFirstTaggedTimeBuilder_ == null + ? activeIrFirstTaggedTime_ + : activeIrFirstTaggedTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.globalCustomerCount_ = globalCustomerCount_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.globalHitCount_ = globalHitCount_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.exclusive_ = exclusive_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.osint_ = osint_; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.scanner_ = scanner_; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.reviewed_ = reviewed_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.AtiPrioritization) { + return mergeFrom((com.google.backstory.AtiPrioritization) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.AtiPrioritization other) { + if (other == com.google.backstory.AtiPrioritization.getDefaultInstance()) return this; + if (other.getGtiVerdict() != 0) { + setGtiVerdict(other.getGtiVerdict()); + } + if (other.getGtiSeverity() != 0) { + setGtiSeverity(other.getGtiSeverity()); + } + if (other.getGtiThreatScore() != 0) { + setGtiThreatScore(other.getGtiThreatScore()); + } + if (other.getMandiantAnalystConfidence() != 0) { + setMandiantAnalystConfidence(other.getMandiantAnalystConfidence()); + } + if (other.hasGtiUpdateTime()) { + mergeGtiUpdateTime(other.getGtiUpdateTime()); + } + if (other.getActiveIr() != false) { + setActiveIr(other.getActiveIr()); + } + if (other.hasActiveIrFirstTaggedTime()) { + mergeActiveIrFirstTaggedTime(other.getActiveIrFirstTaggedTime()); + } + if (other.getGlobalCustomerCount() != 0L) { + setGlobalCustomerCount(other.getGlobalCustomerCount()); + } + if (other.getGlobalHitCount() != 0L) { + setGlobalHitCount(other.getGlobalHitCount()); + } + if (other.getExclusive() != false) { + setExclusive(other.getExclusive()); + } + if (other.getOsint() != false) { + setOsint(other.getOsint()); + } + if (other.getScanner() != false) { + setScanner(other.getScanner()); + } + if (other.getReviewed() != false) { + setReviewed(other.getReviewed()); + } + if (attributedMalwareBuilder_ == null) { + if (!other.attributedMalware_.isEmpty()) { + if (attributedMalware_.isEmpty()) { + attributedMalware_ = other.attributedMalware_; + bitField0_ = (bitField0_ & ~0x00002000); + } else { + ensureAttributedMalwareIsMutable(); + attributedMalware_.addAll(other.attributedMalware_); + } + onChanged(); + } + } else { + if (!other.attributedMalware_.isEmpty()) { + if (attributedMalwareBuilder_.isEmpty()) { + attributedMalwareBuilder_.dispose(); + attributedMalwareBuilder_ = null; + attributedMalware_ = other.attributedMalware_; + bitField0_ = (bitField0_ & ~0x00002000); + attributedMalwareBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAttributedMalwareFieldBuilder() + : null; + } else { + attributedMalwareBuilder_.addAllMessages(other.attributedMalware_); + } + } + } + if (attributedThreatActorsBuilder_ == null) { + if (!other.attributedThreatActors_.isEmpty()) { + if (attributedThreatActors_.isEmpty()) { + attributedThreatActors_ = other.attributedThreatActors_; + bitField0_ = (bitField0_ & ~0x00004000); + } else { + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.addAll(other.attributedThreatActors_); + } + onChanged(); + } + } else { + if (!other.attributedThreatActors_.isEmpty()) { + if (attributedThreatActorsBuilder_.isEmpty()) { + attributedThreatActorsBuilder_.dispose(); + attributedThreatActorsBuilder_ = null; + attributedThreatActors_ = other.attributedThreatActors_; + bitField0_ = (bitField0_ & ~0x00004000); + attributedThreatActorsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAttributedThreatActorsFieldBuilder() + : null; + } else { + attributedThreatActorsBuilder_.addAllMessages(other.attributedThreatActors_); + } + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + gtiVerdict_ = input.readInt32(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 16: + { + gtiSeverity_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 24: + { + gtiThreatScore_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 32: + { + mandiantAnalystConfidence_ = input.readInt32(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 42: + { + input.readMessage( + internalGetGtiUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 48: + { + activeIr_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 58: + { + input.readMessage( + internalGetActiveIrFirstTaggedTimeFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 64: + { + globalCustomerCount_ = input.readInt64(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 72: + { + globalHitCount_ = input.readInt64(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 80: + { + exclusive_ = input.readBool(); + bitField0_ |= 0x00000200; + break; + } // case 80 + case 88: + { + osint_ = input.readBool(); + bitField0_ |= 0x00000400; + break; + } // case 88 + case 96: + { + scanner_ = input.readBool(); + bitField0_ |= 0x00000800; + break; + } // case 96 + case 104: + { + reviewed_ = input.readBool(); + bitField0_ |= 0x00001000; + break; + } // case 104 + case 114: + { + com.google.backstory.SecurityResult.Association m = + input.readMessage( + com.google.backstory.SecurityResult.Association.parser(), + extensionRegistry); + if (attributedMalwareBuilder_ == null) { + ensureAttributedMalwareIsMutable(); + attributedMalware_.add(m); + } else { + attributedMalwareBuilder_.addMessage(m); + } + break; + } // case 114 + case 122: + { + com.google.backstory.SecurityResult.Association m = + input.readMessage( + com.google.backstory.SecurityResult.Association.parser(), + extensionRegistry); + if (attributedThreatActorsBuilder_ == null) { + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.add(m); + } else { + attributedThreatActorsBuilder_.addMessage(m); + } + break; + } // case 122 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int gtiVerdict_; + + /** + * + * + *
+     * The confidence score from "GTI verdict" source.
+     * 
+ * + * int32 gti_verdict = 1; + * + * @return The gtiVerdict. + */ + @java.lang.Override + public int getGtiVerdict() { + return gtiVerdict_; + } + + /** + * + * + *
+     * The confidence score from "GTI verdict" source.
+     * 
+ * + * int32 gti_verdict = 1; + * + * @param value The gtiVerdict to set. + * @return This builder for chaining. + */ + public Builder setGtiVerdict(int value) { + + gtiVerdict_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The confidence score from "GTI verdict" source.
+     * 
+ * + * int32 gti_verdict = 1; + * + * @return This builder for chaining. + */ + public Builder clearGtiVerdict() { + bitField0_ = (bitField0_ & ~0x00000001); + gtiVerdict_ = 0; + onChanged(); + return this; + } + + private int gtiSeverity_; + + /** + * + * + *
+     * The confidence score from "GTI severity" source.
+     * 
+ * + * int32 gti_severity = 2; + * + * @return The gtiSeverity. + */ + @java.lang.Override + public int getGtiSeverity() { + return gtiSeverity_; + } + + /** + * + * + *
+     * The confidence score from "GTI severity" source.
+     * 
+ * + * int32 gti_severity = 2; + * + * @param value The gtiSeverity to set. + * @return This builder for chaining. + */ + public Builder setGtiSeverity(int value) { + + gtiSeverity_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The confidence score from "GTI severity" source.
+     * 
+ * + * int32 gti_severity = 2; + * + * @return This builder for chaining. + */ + public Builder clearGtiSeverity() { + bitField0_ = (bitField0_ & ~0x00000002); + gtiSeverity_ = 0; + onChanged(); + return this; + } + + private int gtiThreatScore_; + + /** + * + * + *
+     * The confidence score from "GTI threat score" source.
+     * 
+ * + * int32 gti_threat_score = 3; + * + * @return The gtiThreatScore. + */ + @java.lang.Override + public int getGtiThreatScore() { + return gtiThreatScore_; + } + + /** + * + * + *
+     * The confidence score from "GTI threat score" source.
+     * 
+ * + * int32 gti_threat_score = 3; + * + * @param value The gtiThreatScore to set. + * @return This builder for chaining. + */ + public Builder setGtiThreatScore(int value) { + + gtiThreatScore_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The confidence score from "GTI threat score" source.
+     * 
+ * + * int32 gti_threat_score = 3; + * + * @return This builder for chaining. + */ + public Builder clearGtiThreatScore() { + bitField0_ = (bitField0_ & ~0x00000004); + gtiThreatScore_ = 0; + onChanged(); + return this; + } + + private int mandiantAnalystConfidence_; + + /** + * + * + *
+     * The confidence score from "Mandiant Analyst Intel" source.
+     * 
+ * + * int32 mandiant_analyst_confidence = 4; + * + * @return The mandiantAnalystConfidence. + */ + @java.lang.Override + public int getMandiantAnalystConfidence() { + return mandiantAnalystConfidence_; + } + + /** + * + * + *
+     * The confidence score from "Mandiant Analyst Intel" source.
+     * 
+ * + * int32 mandiant_analyst_confidence = 4; + * + * @param value The mandiantAnalystConfidence to set. + * @return This builder for chaining. + */ + public Builder setMandiantAnalystConfidence(int value) { + + mandiantAnalystConfidence_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * The confidence score from "Mandiant Analyst Intel" source.
+     * 
+ * + * int32 mandiant_analyst_confidence = 4; + * + * @return This builder for chaining. + */ + public Builder clearMandiantAnalystConfidence() { + bitField0_ = (bitField0_ & ~0x00000008); + mandiantAnalystConfidence_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp gtiUpdateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + gtiUpdateTimeBuilder_; + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + * + * @return Whether the gtiUpdateTime field is set. + */ + public boolean hasGtiUpdateTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + * + * @return The gtiUpdateTime. + */ + public com.google.protobuf.Timestamp getGtiUpdateTime() { + if (gtiUpdateTimeBuilder_ == null) { + return gtiUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : gtiUpdateTime_; + } else { + return gtiUpdateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + public Builder setGtiUpdateTime(com.google.protobuf.Timestamp value) { + if (gtiUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + gtiUpdateTime_ = value; + } else { + gtiUpdateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + public Builder setGtiUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (gtiUpdateTimeBuilder_ == null) { + gtiUpdateTime_ = builderForValue.build(); + } else { + gtiUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + public Builder mergeGtiUpdateTime(com.google.protobuf.Timestamp value) { + if (gtiUpdateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && gtiUpdateTime_ != null + && gtiUpdateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getGtiUpdateTimeBuilder().mergeFrom(value); + } else { + gtiUpdateTime_ = value; + } + } else { + gtiUpdateTimeBuilder_.mergeFrom(value); + } + if (gtiUpdateTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + public Builder clearGtiUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000010); + gtiUpdateTime_ = null; + if (gtiUpdateTimeBuilder_ != null) { + gtiUpdateTimeBuilder_.dispose(); + gtiUpdateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getGtiUpdateTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetGtiUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getGtiUpdateTimeOrBuilder() { + if (gtiUpdateTimeBuilder_ != null) { + return gtiUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return gtiUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : gtiUpdateTime_; + } + } + + /** + * + * + *
+     * Timestamp of the latest update for GTI verdict, severity, or threat score.
+     * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetGtiUpdateTimeFieldBuilder() { + if (gtiUpdateTimeBuilder_ == null) { + gtiUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getGtiUpdateTime(), getParentForChildren(), isClean()); + gtiUpdateTime_ = null; + } + return gtiUpdateTimeBuilder_; + } + + private boolean activeIr_; + + /** + * + * + *
+     * Whether one or more Mandiant incident response customers had this indicator
+     * in their environment.
+     * 
+ * + * bool active_ir = 6; + * + * @return The activeIr. + */ + @java.lang.Override + public boolean getActiveIr() { + return activeIr_; + } + + /** + * + * + *
+     * Whether one or more Mandiant incident response customers had this indicator
+     * in their environment.
+     * 
+ * + * bool active_ir = 6; + * + * @param value The activeIr to set. + * @return This builder for chaining. + */ + public Builder setActiveIr(boolean value) { + + activeIr_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Whether one or more Mandiant incident response customers had this indicator
+     * in their environment.
+     * 
+ * + * bool active_ir = 6; + * + * @return This builder for chaining. + */ + public Builder clearActiveIr() { + bitField0_ = (bitField0_ & ~0x00000020); + activeIr_ = false; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp activeIrFirstTaggedTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + activeIrFirstTaggedTimeBuilder_; + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + * + * @return Whether the activeIrFirstTaggedTime field is set. + */ + public boolean hasActiveIrFirstTaggedTime() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + * + * @return The activeIrFirstTaggedTime. + */ + public com.google.protobuf.Timestamp getActiveIrFirstTaggedTime() { + if (activeIrFirstTaggedTimeBuilder_ == null) { + return activeIrFirstTaggedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : activeIrFirstTaggedTime_; + } else { + return activeIrFirstTaggedTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + public Builder setActiveIrFirstTaggedTime(com.google.protobuf.Timestamp value) { + if (activeIrFirstTaggedTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + activeIrFirstTaggedTime_ = value; + } else { + activeIrFirstTaggedTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + public Builder setActiveIrFirstTaggedTime( + com.google.protobuf.Timestamp.Builder builderForValue) { + if (activeIrFirstTaggedTimeBuilder_ == null) { + activeIrFirstTaggedTime_ = builderForValue.build(); + } else { + activeIrFirstTaggedTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + public Builder mergeActiveIrFirstTaggedTime(com.google.protobuf.Timestamp value) { + if (activeIrFirstTaggedTimeBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && activeIrFirstTaggedTime_ != null + && activeIrFirstTaggedTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getActiveIrFirstTaggedTimeBuilder().mergeFrom(value); + } else { + activeIrFirstTaggedTime_ = value; + } + } else { + activeIrFirstTaggedTimeBuilder_.mergeFrom(value); + } + if (activeIrFirstTaggedTime_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + public Builder clearActiveIrFirstTaggedTime() { + bitField0_ = (bitField0_ & ~0x00000040); + activeIrFirstTaggedTime_ = null; + if (activeIrFirstTaggedTimeBuilder_ != null) { + activeIrFirstTaggedTimeBuilder_.dispose(); + activeIrFirstTaggedTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + public com.google.protobuf.Timestamp.Builder getActiveIrFirstTaggedTimeBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetActiveIrFirstTaggedTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + public com.google.protobuf.TimestampOrBuilder getActiveIrFirstTaggedTimeOrBuilder() { + if (activeIrFirstTaggedTimeBuilder_ != null) { + return activeIrFirstTaggedTimeBuilder_.getMessageOrBuilder(); + } else { + return activeIrFirstTaggedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : activeIrFirstTaggedTime_; + } + } + + /** + * + * + *
+     * The timestamp of the first time an active IR was applied to this entity.
+     * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetActiveIrFirstTaggedTimeFieldBuilder() { + if (activeIrFirstTaggedTimeBuilder_ == null) { + activeIrFirstTaggedTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getActiveIrFirstTaggedTime(), getParentForChildren(), isClean()); + activeIrFirstTaggedTime_ = null; + } + return activeIrFirstTaggedTimeBuilder_; + } + + private long globalCustomerCount_; + + /** + * + * + *
+     * Global customer count over the last 30 days
+     * 
+ * + * int64 global_customer_count = 8; + * + * @return The globalCustomerCount. + */ + @java.lang.Override + public long getGlobalCustomerCount() { + return globalCustomerCount_; + } + + /** + * + * + *
+     * Global customer count over the last 30 days
+     * 
+ * + * int64 global_customer_count = 8; + * + * @param value The globalCustomerCount to set. + * @return This builder for chaining. + */ + public Builder setGlobalCustomerCount(long value) { + + globalCustomerCount_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Global customer count over the last 30 days
+     * 
+ * + * int64 global_customer_count = 8; + * + * @return This builder for chaining. + */ + public Builder clearGlobalCustomerCount() { + bitField0_ = (bitField0_ & ~0x00000080); + globalCustomerCount_ = 0L; + onChanged(); + return this; + } + + private long globalHitCount_; + + /** + * + * + *
+     * Global hit count over the last 30 days
+     * 
+ * + * int64 global_hit_count = 9; + * + * @return The globalHitCount. + */ + @java.lang.Override + public long getGlobalHitCount() { + return globalHitCount_; + } + + /** + * + * + *
+     * Global hit count over the last 30 days
+     * 
+ * + * int64 global_hit_count = 9; + * + * @param value The globalHitCount to set. + * @return This builder for chaining. + */ + public Builder setGlobalHitCount(long value) { + + globalHitCount_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Global hit count over the last 30 days
+     * 
+ * + * int64 global_hit_count = 9; + * + * @return This builder for chaining. + */ + public Builder clearGlobalHitCount() { + bitField0_ = (bitField0_ & ~0x00000100); + globalHitCount_ = 0L; + onChanged(); + return this; + } + + private boolean exclusive_; + + /** + * + * + *
+     * Whether the indicator is being used by a maximum of one threat actor.
+     * 
+ * + * bool exclusive = 10; + * + * @return The exclusive. + */ + @java.lang.Override + public boolean getExclusive() { + return exclusive_; + } + + /** + * + * + *
+     * Whether the indicator is being used by a maximum of one threat actor.
+     * 
+ * + * bool exclusive = 10; + * + * @param value The exclusive to set. + * @return This builder for chaining. + */ + public Builder setExclusive(boolean value) { + + exclusive_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Whether the indicator is being used by a maximum of one threat actor.
+     * 
+ * + * bool exclusive = 10; + * + * @return This builder for chaining. + */ + public Builder clearExclusive() { + bitField0_ = (bitField0_ & ~0x00000200); + exclusive_ = false; + onChanged(); + return this; + } + + private boolean osint_; + + /** + * + * + *
+     * Whether the indicator details are available in open source.
+     * 
+ * + * bool osint = 11; + * + * @return The osint. + */ + @java.lang.Override + public boolean getOsint() { + return osint_; + } + + /** + * + * + *
+     * Whether the indicator details are available in open source.
+     * 
+ * + * bool osint = 11; + * + * @param value The osint to set. + * @return This builder for chaining. + */ + public Builder setOsint(boolean value) { + + osint_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Whether the indicator details are available in open source.
+     * 
+ * + * bool osint = 11; + * + * @return This builder for chaining. + */ + public Builder clearOsint() { + bitField0_ = (bitField0_ & ~0x00000400); + osint_ = false; + onChanged(); + return this; + } + + private boolean scanner_; + + /** + * + * + *
+     * Whether the indicator is a scanner.
+     * 
+ * + * bool scanner = 12; + * + * @return The scanner. + */ + @java.lang.Override + public boolean getScanner() { + return scanner_; + } + + /** + * + * + *
+     * Whether the indicator is a scanner.
+     * 
+ * + * bool scanner = 12; + * + * @param value The scanner to set. + * @return This builder for chaining. + */ + public Builder setScanner(boolean value) { + + scanner_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Whether the indicator is a scanner.
+     * 
+ * + * bool scanner = 12; + * + * @return This builder for chaining. + */ + public Builder clearScanner() { + bitField0_ = (bitField0_ & ~0x00000800); + scanner_ = false; + onChanged(); + return this; + } + + private boolean reviewed_; + + /** + * + * + *
+     * Whether the indicator verdict has passed review.
+     * 
+ * + * bool reviewed = 13; + * + * @return The reviewed. + */ + @java.lang.Override + public boolean getReviewed() { + return reviewed_; + } + + /** + * + * + *
+     * Whether the indicator verdict has passed review.
+     * 
+ * + * bool reviewed = 13; + * + * @param value The reviewed to set. + * @return This builder for chaining. + */ + public Builder setReviewed(boolean value) { + + reviewed_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Whether the indicator verdict has passed review.
+     * 
+ * + * bool reviewed = 13; + * + * @return This builder for chaining. + */ + public Builder clearReviewed() { + bitField0_ = (bitField0_ & ~0x00001000); + reviewed_ = false; + onChanged(); + return this; + } + + private java.util.List attributedMalware_ = + java.util.Collections.emptyList(); + + private void ensureAttributedMalwareIsMutable() { + if (!((bitField0_ & 0x00002000) != 0)) { + attributedMalware_ = + new java.util.ArrayList( + attributedMalware_); + bitField0_ |= 0x00002000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult.Association, + com.google.backstory.SecurityResult.Association.Builder, + com.google.backstory.SecurityResult.AssociationOrBuilder> + attributedMalwareBuilder_; + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public java.util.List + getAttributedMalwareList() { + if (attributedMalwareBuilder_ == null) { + return java.util.Collections.unmodifiableList(attributedMalware_); + } else { + return attributedMalwareBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public int getAttributedMalwareCount() { + if (attributedMalwareBuilder_ == null) { + return attributedMalware_.size(); + } else { + return attributedMalwareBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public com.google.backstory.SecurityResult.Association getAttributedMalware(int index) { + if (attributedMalwareBuilder_ == null) { + return attributedMalware_.get(index); + } else { + return attributedMalwareBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder setAttributedMalware( + int index, com.google.backstory.SecurityResult.Association value) { + if (attributedMalwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAttributedMalwareIsMutable(); + attributedMalware_.set(index, value); + onChanged(); + } else { + attributedMalwareBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder setAttributedMalware( + int index, com.google.backstory.SecurityResult.Association.Builder builderForValue) { + if (attributedMalwareBuilder_ == null) { + ensureAttributedMalwareIsMutable(); + attributedMalware_.set(index, builderForValue.build()); + onChanged(); + } else { + attributedMalwareBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder addAttributedMalware(com.google.backstory.SecurityResult.Association value) { + if (attributedMalwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAttributedMalwareIsMutable(); + attributedMalware_.add(value); + onChanged(); + } else { + attributedMalwareBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder addAttributedMalware( + int index, com.google.backstory.SecurityResult.Association value) { + if (attributedMalwareBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAttributedMalwareIsMutable(); + attributedMalware_.add(index, value); + onChanged(); + } else { + attributedMalwareBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder addAttributedMalware( + com.google.backstory.SecurityResult.Association.Builder builderForValue) { + if (attributedMalwareBuilder_ == null) { + ensureAttributedMalwareIsMutable(); + attributedMalware_.add(builderForValue.build()); + onChanged(); + } else { + attributedMalwareBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder addAttributedMalware( + int index, com.google.backstory.SecurityResult.Association.Builder builderForValue) { + if (attributedMalwareBuilder_ == null) { + ensureAttributedMalwareIsMutable(); + attributedMalware_.add(index, builderForValue.build()); + onChanged(); + } else { + attributedMalwareBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder addAllAttributedMalware( + java.lang.Iterable values) { + if (attributedMalwareBuilder_ == null) { + ensureAttributedMalwareIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, attributedMalware_); + onChanged(); + } else { + attributedMalwareBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder clearAttributedMalware() { + if (attributedMalwareBuilder_ == null) { + attributedMalware_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00002000); + onChanged(); + } else { + attributedMalwareBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public Builder removeAttributedMalware(int index) { + if (attributedMalwareBuilder_ == null) { + ensureAttributedMalwareIsMutable(); + attributedMalware_.remove(index); + onChanged(); + } else { + attributedMalwareBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public com.google.backstory.SecurityResult.Association.Builder getAttributedMalwareBuilder( + int index) { + return internalGetAttributedMalwareFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public com.google.backstory.SecurityResult.AssociationOrBuilder getAttributedMalwareOrBuilder( + int index) { + if (attributedMalwareBuilder_ == null) { + return attributedMalware_.get(index); + } else { + return attributedMalwareBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public java.util.List + getAttributedMalwareOrBuilderList() { + if (attributedMalwareBuilder_ != null) { + return attributedMalwareBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(attributedMalware_); + } + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public com.google.backstory.SecurityResult.Association.Builder addAttributedMalwareBuilder() { + return internalGetAttributedMalwareFieldBuilder() + .addBuilder(com.google.backstory.SecurityResult.Association.getDefaultInstance()); + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public com.google.backstory.SecurityResult.Association.Builder addAttributedMalwareBuilder( + int index) { + return internalGetAttributedMalwareFieldBuilder() + .addBuilder(index, com.google.backstory.SecurityResult.Association.getDefaultInstance()); + } + + /** + * + * + *
+     * Malware families associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + public java.util.List + getAttributedMalwareBuilderList() { + return internalGetAttributedMalwareFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult.Association, + com.google.backstory.SecurityResult.Association.Builder, + com.google.backstory.SecurityResult.AssociationOrBuilder> + internalGetAttributedMalwareFieldBuilder() { + if (attributedMalwareBuilder_ == null) { + attributedMalwareBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult.Association, + com.google.backstory.SecurityResult.Association.Builder, + com.google.backstory.SecurityResult.AssociationOrBuilder>( + attributedMalware_, + ((bitField0_ & 0x00002000) != 0), + getParentForChildren(), + isClean()); + attributedMalware_ = null; + } + return attributedMalwareBuilder_; + } + + private java.util.List + attributedThreatActors_ = java.util.Collections.emptyList(); + + private void ensureAttributedThreatActorsIsMutable() { + if (!((bitField0_ & 0x00004000) != 0)) { + attributedThreatActors_ = + new java.util.ArrayList( + attributedThreatActors_); + bitField0_ |= 0x00004000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult.Association, + com.google.backstory.SecurityResult.Association.Builder, + com.google.backstory.SecurityResult.AssociationOrBuilder> + attributedThreatActorsBuilder_; + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public java.util.List + getAttributedThreatActorsList() { + if (attributedThreatActorsBuilder_ == null) { + return java.util.Collections.unmodifiableList(attributedThreatActors_); + } else { + return attributedThreatActorsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public int getAttributedThreatActorsCount() { + if (attributedThreatActorsBuilder_ == null) { + return attributedThreatActors_.size(); + } else { + return attributedThreatActorsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public com.google.backstory.SecurityResult.Association getAttributedThreatActors(int index) { + if (attributedThreatActorsBuilder_ == null) { + return attributedThreatActors_.get(index); + } else { + return attributedThreatActorsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder setAttributedThreatActors( + int index, com.google.backstory.SecurityResult.Association value) { + if (attributedThreatActorsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.set(index, value); + onChanged(); + } else { + attributedThreatActorsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder setAttributedThreatActors( + int index, com.google.backstory.SecurityResult.Association.Builder builderForValue) { + if (attributedThreatActorsBuilder_ == null) { + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.set(index, builderForValue.build()); + onChanged(); + } else { + attributedThreatActorsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder addAttributedThreatActors( + com.google.backstory.SecurityResult.Association value) { + if (attributedThreatActorsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.add(value); + onChanged(); + } else { + attributedThreatActorsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder addAttributedThreatActors( + int index, com.google.backstory.SecurityResult.Association value) { + if (attributedThreatActorsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.add(index, value); + onChanged(); + } else { + attributedThreatActorsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder addAttributedThreatActors( + com.google.backstory.SecurityResult.Association.Builder builderForValue) { + if (attributedThreatActorsBuilder_ == null) { + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.add(builderForValue.build()); + onChanged(); + } else { + attributedThreatActorsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder addAttributedThreatActors( + int index, com.google.backstory.SecurityResult.Association.Builder builderForValue) { + if (attributedThreatActorsBuilder_ == null) { + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.add(index, builderForValue.build()); + onChanged(); + } else { + attributedThreatActorsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder addAllAttributedThreatActors( + java.lang.Iterable values) { + if (attributedThreatActorsBuilder_ == null) { + ensureAttributedThreatActorsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, attributedThreatActors_); + onChanged(); + } else { + attributedThreatActorsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder clearAttributedThreatActors() { + if (attributedThreatActorsBuilder_ == null) { + attributedThreatActors_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00004000); + onChanged(); + } else { + attributedThreatActorsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public Builder removeAttributedThreatActors(int index) { + if (attributedThreatActorsBuilder_ == null) { + ensureAttributedThreatActorsIsMutable(); + attributedThreatActors_.remove(index); + onChanged(); + } else { + attributedThreatActorsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public com.google.backstory.SecurityResult.Association.Builder getAttributedThreatActorsBuilder( + int index) { + return internalGetAttributedThreatActorsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public com.google.backstory.SecurityResult.AssociationOrBuilder + getAttributedThreatActorsOrBuilder(int index) { + if (attributedThreatActorsBuilder_ == null) { + return attributedThreatActors_.get(index); + } else { + return attributedThreatActorsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public java.util.List + getAttributedThreatActorsOrBuilderList() { + if (attributedThreatActorsBuilder_ != null) { + return attributedThreatActorsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(attributedThreatActors_); + } + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public com.google.backstory.SecurityResult.Association.Builder + addAttributedThreatActorsBuilder() { + return internalGetAttributedThreatActorsFieldBuilder() + .addBuilder(com.google.backstory.SecurityResult.Association.getDefaultInstance()); + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public com.google.backstory.SecurityResult.Association.Builder addAttributedThreatActorsBuilder( + int index) { + return internalGetAttributedThreatActorsFieldBuilder() + .addBuilder(index, com.google.backstory.SecurityResult.Association.getDefaultInstance()); + } + + /** + * + * + *
+     * Threat actors associated with this indicator.
+     * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + public java.util.List + getAttributedThreatActorsBuilderList() { + return internalGetAttributedThreatActorsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult.Association, + com.google.backstory.SecurityResult.Association.Builder, + com.google.backstory.SecurityResult.AssociationOrBuilder> + internalGetAttributedThreatActorsFieldBuilder() { + if (attributedThreatActorsBuilder_ == null) { + attributedThreatActorsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult.Association, + com.google.backstory.SecurityResult.Association.Builder, + com.google.backstory.SecurityResult.AssociationOrBuilder>( + attributedThreatActors_, + ((bitField0_ & 0x00004000) != 0), + getParentForChildren(), + isClean()); + attributedThreatActors_ = null; + } + return attributedThreatActorsBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.AtiPrioritization) + } + + // @@protoc_insertion_point(class_scope:google.backstory.AtiPrioritization) + private static final com.google.backstory.AtiPrioritization DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.AtiPrioritization(); + } + + public static com.google.backstory.AtiPrioritization getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AtiPrioritization parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.AtiPrioritization getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java new file mode 100644 index 000000000000..5bf28a9278b2 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java @@ -0,0 +1,349 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/entity.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AtiPrioritizationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.AtiPrioritization) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The confidence score from "GTI verdict" source.
+   * 
+ * + * int32 gti_verdict = 1; + * + * @return The gtiVerdict. + */ + int getGtiVerdict(); + + /** + * + * + *
+   * The confidence score from "GTI severity" source.
+   * 
+ * + * int32 gti_severity = 2; + * + * @return The gtiSeverity. + */ + int getGtiSeverity(); + + /** + * + * + *
+   * The confidence score from "GTI threat score" source.
+   * 
+ * + * int32 gti_threat_score = 3; + * + * @return The gtiThreatScore. + */ + int getGtiThreatScore(); + + /** + * + * + *
+   * The confidence score from "Mandiant Analyst Intel" source.
+   * 
+ * + * int32 mandiant_analyst_confidence = 4; + * + * @return The mandiantAnalystConfidence. + */ + int getMandiantAnalystConfidence(); + + /** + * + * + *
+   * Timestamp of the latest update for GTI verdict, severity, or threat score.
+   * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + * + * @return Whether the gtiUpdateTime field is set. + */ + boolean hasGtiUpdateTime(); + + /** + * + * + *
+   * Timestamp of the latest update for GTI verdict, severity, or threat score.
+   * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + * + * @return The gtiUpdateTime. + */ + com.google.protobuf.Timestamp getGtiUpdateTime(); + + /** + * + * + *
+   * Timestamp of the latest update for GTI verdict, severity, or threat score.
+   * 
+ * + * .google.protobuf.Timestamp gti_update_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getGtiUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Whether one or more Mandiant incident response customers had this indicator
+   * in their environment.
+   * 
+ * + * bool active_ir = 6; + * + * @return The activeIr. + */ + boolean getActiveIr(); + + /** + * + * + *
+   * The timestamp of the first time an active IR was applied to this entity.
+   * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + * + * @return Whether the activeIrFirstTaggedTime field is set. + */ + boolean hasActiveIrFirstTaggedTime(); + + /** + * + * + *
+   * The timestamp of the first time an active IR was applied to this entity.
+   * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + * + * @return The activeIrFirstTaggedTime. + */ + com.google.protobuf.Timestamp getActiveIrFirstTaggedTime(); + + /** + * + * + *
+   * The timestamp of the first time an active IR was applied to this entity.
+   * 
+ * + * .google.protobuf.Timestamp active_ir_first_tagged_time = 7; + */ + com.google.protobuf.TimestampOrBuilder getActiveIrFirstTaggedTimeOrBuilder(); + + /** + * + * + *
+   * Global customer count over the last 30 days
+   * 
+ * + * int64 global_customer_count = 8; + * + * @return The globalCustomerCount. + */ + long getGlobalCustomerCount(); + + /** + * + * + *
+   * Global hit count over the last 30 days
+   * 
+ * + * int64 global_hit_count = 9; + * + * @return The globalHitCount. + */ + long getGlobalHitCount(); + + /** + * + * + *
+   * Whether the indicator is being used by a maximum of one threat actor.
+   * 
+ * + * bool exclusive = 10; + * + * @return The exclusive. + */ + boolean getExclusive(); + + /** + * + * + *
+   * Whether the indicator details are available in open source.
+   * 
+ * + * bool osint = 11; + * + * @return The osint. + */ + boolean getOsint(); + + /** + * + * + *
+   * Whether the indicator is a scanner.
+   * 
+ * + * bool scanner = 12; + * + * @return The scanner. + */ + boolean getScanner(); + + /** + * + * + *
+   * Whether the indicator verdict has passed review.
+   * 
+ * + * bool reviewed = 13; + * + * @return The reviewed. + */ + boolean getReviewed(); + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + java.util.List getAttributedMalwareList(); + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + com.google.backstory.SecurityResult.Association getAttributedMalware(int index); + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + int getAttributedMalwareCount(); + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + java.util.List + getAttributedMalwareOrBuilderList(); + + /** + * + * + *
+   * Malware families associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_malware = 14; + */ + com.google.backstory.SecurityResult.AssociationOrBuilder getAttributedMalwareOrBuilder(int index); + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + java.util.List getAttributedThreatActorsList(); + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + com.google.backstory.SecurityResult.Association getAttributedThreatActors(int index); + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + int getAttributedThreatActorsCount(); + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + java.util.List + getAttributedThreatActorsOrBuilderList(); + + /** + * + * + *
+   * Threat actors associated with this indicator.
+   * 
+ * + * repeated .google.backstory.SecurityResult.Association attributed_threat_actors = 15; + * + */ + com.google.backstory.SecurityResult.AssociationOrBuilder getAttributedThreatActorsOrBuilder( + int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/AttackDetails.java b/java-backstory/src/main/java/com/google/backstory/AttackDetails.java new file mode 100644 index 000000000000..9e28d54575e8 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AttackDetails.java @@ -0,0 +1,3672 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * MITRE ATT&CK details.
+ * 
+ * + * Protobuf type {@code google.backstory.AttackDetails} + */ +@com.google.protobuf.Generated +public final class AttackDetails extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.AttackDetails) + AttackDetailsOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AttackDetails"); + } + + // Use AttackDetails.newBuilder() to construct. + private AttackDetails(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AttackDetails() { + version_ = ""; + tactics_ = java.util.Collections.emptyList(); + techniques_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_AttackDetails_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AttackDetails.class, + com.google.backstory.AttackDetails.Builder.class); + } + + public interface TacticOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.AttackDetails.Tactic) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Tactic ID (e.g. "TA0043").
+     * 
+ * + * string id = 1; + * + * @return The id. + */ + java.lang.String getId(); + + /** + * + * + *
+     * Tactic ID (e.g. "TA0043").
+     * 
+ * + * string id = 1; + * + * @return The bytes for id. + */ + com.google.protobuf.ByteString getIdBytes(); + + /** + * + * + *
+     * Tactic Name (e.g. "Reconnaissance")
+     * 
+ * + * string name = 2; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+     * Tactic Name (e.g. "Reconnaissance")
+     * 
+ * + * string name = 2; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + } + + /** + * + * + *
+   * Tactic information related to an attack or threat.
+   * 
+ * + * Protobuf type {@code google.backstory.AttackDetails.Tactic} + */ + public static final class Tactic extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.AttackDetails.Tactic) + TacticOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Tactic"); + } + + // Use Tactic.newBuilder() to construct. + private Tactic(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Tactic() { + id_ = ""; + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Tactic_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Tactic_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AttackDetails.Tactic.class, + com.google.backstory.AttackDetails.Tactic.Builder.class); + } + + public static final int ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object id_ = ""; + + /** + * + * + *
+     * Tactic ID (e.g. "TA0043").
+     * 
+ * + * string id = 1; + * + * @return The id. + */ + @java.lang.Override + public java.lang.String getId() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } + } + + /** + * + * + *
+     * Tactic ID (e.g. "TA0043").
+     * 
+ * + * string id = 1; + * + * @return The bytes for id. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+     * Tactic Name (e.g. "Reconnaissance")
+     * 
+ * + * string name = 2; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+     * Tactic Name (e.g. "Reconnaissance")
+     * 
+ * + * string name = 2; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.AttackDetails.Tactic)) { + return super.equals(obj); + } + com.google.backstory.AttackDetails.Tactic other = + (com.google.backstory.AttackDetails.Tactic) obj; + + if (!getId().equals(other.getId())) return false; + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ID_FIELD_NUMBER; + hash = (53 * hash) + getId().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Tactic parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails.Tactic parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails.Tactic parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.AttackDetails.Tactic prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * Tactic information related to an attack or threat.
+     * 
+ * + * Protobuf type {@code google.backstory.AttackDetails.Tactic} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.AttackDetails.Tactic) + com.google.backstory.AttackDetails.TacticOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Tactic_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Tactic_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AttackDetails.Tactic.class, + com.google.backstory.AttackDetails.Tactic.Builder.class); + } + + // Construct using com.google.backstory.AttackDetails.Tactic.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + id_ = ""; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Tactic_descriptor; + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Tactic getDefaultInstanceForType() { + return com.google.backstory.AttackDetails.Tactic.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Tactic build() { + com.google.backstory.AttackDetails.Tactic result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Tactic buildPartial() { + com.google.backstory.AttackDetails.Tactic result = + new com.google.backstory.AttackDetails.Tactic(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.AttackDetails.Tactic result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.id_ = id_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.AttackDetails.Tactic) { + return mergeFrom((com.google.backstory.AttackDetails.Tactic) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.AttackDetails.Tactic other) { + if (other == com.google.backstory.AttackDetails.Tactic.getDefaultInstance()) return this; + if (!other.getId().isEmpty()) { + id_ = other.id_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object id_ = ""; + + /** + * + * + *
+       * Tactic ID (e.g. "TA0043").
+       * 
+ * + * string id = 1; + * + * @return The id. + */ + public java.lang.String getId() { + java.lang.Object ref = id_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Tactic ID (e.g. "TA0043").
+       * 
+ * + * string id = 1; + * + * @return The bytes for id. + */ + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Tactic ID (e.g. "TA0043").
+       * 
+ * + * string id = 1; + * + * @param value The id to set. + * @return This builder for chaining. + */ + public Builder setId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + id_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * Tactic ID (e.g. "TA0043").
+       * 
+ * + * string id = 1; + * + * @return This builder for chaining. + */ + public Builder clearId() { + id_ = getDefaultInstance().getId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+       * Tactic ID (e.g. "TA0043").
+       * 
+ * + * string id = 1; + * + * @param value The bytes for id to set. + * @return This builder for chaining. + */ + public Builder setIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + id_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object name_ = ""; + + /** + * + * + *
+       * Tactic Name (e.g. "Reconnaissance")
+       * 
+ * + * string name = 2; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Tactic Name (e.g. "Reconnaissance")
+       * 
+ * + * string name = 2; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Tactic Name (e.g. "Reconnaissance")
+       * 
+ * + * string name = 2; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Tactic Name (e.g. "Reconnaissance")
+       * 
+ * + * string name = 2; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+       * Tactic Name (e.g. "Reconnaissance")
+       * 
+ * + * string name = 2; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.AttackDetails.Tactic) + } + + // @@protoc_insertion_point(class_scope:google.backstory.AttackDetails.Tactic) + private static final com.google.backstory.AttackDetails.Tactic DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.AttackDetails.Tactic(); + } + + public static com.google.backstory.AttackDetails.Tactic getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Tactic parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Tactic getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TechniqueOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.AttackDetails.Technique) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Technique ID (e.g. "T1595").
+     * 
+ * + * string id = 1; + * + * @return The id. + */ + java.lang.String getId(); + + /** + * + * + *
+     * Technique ID (e.g. "T1595").
+     * 
+ * + * string id = 1; + * + * @return The bytes for id. + */ + com.google.protobuf.ByteString getIdBytes(); + + /** + * + * + *
+     * Technique Name (e.g. "Active Scanning").
+     * 
+ * + * string name = 2; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+     * Technique Name (e.g. "Active Scanning").
+     * 
+ * + * string name = 2; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+     * Subtechnique ID (e.g. "T1595.001").
+     * 
+ * + * string subtechnique_id = 3; + * + * @return The subtechniqueId. + */ + java.lang.String getSubtechniqueId(); + + /** + * + * + *
+     * Subtechnique ID (e.g. "T1595.001").
+     * 
+ * + * string subtechnique_id = 3; + * + * @return The bytes for subtechniqueId. + */ + com.google.protobuf.ByteString getSubtechniqueIdBytes(); + + /** + * + * + *
+     * Subtechnique Name (e.g. "Scanning IP Blocks").
+     * 
+ * + * string subtechnique_name = 4; + * + * @return The subtechniqueName. + */ + java.lang.String getSubtechniqueName(); + + /** + * + * + *
+     * Subtechnique Name (e.g. "Scanning IP Blocks").
+     * 
+ * + * string subtechnique_name = 4; + * + * @return The bytes for subtechniqueName. + */ + com.google.protobuf.ByteString getSubtechniqueNameBytes(); + } + + /** + * + * + *
+   * Technique information related to an attack or threat.
+   * 
+ * + * Protobuf type {@code google.backstory.AttackDetails.Technique} + */ + public static final class Technique extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.AttackDetails.Technique) + TechniqueOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Technique"); + } + + // Use Technique.newBuilder() to construct. + private Technique(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Technique() { + id_ = ""; + name_ = ""; + subtechniqueId_ = ""; + subtechniqueName_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Technique_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Technique_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AttackDetails.Technique.class, + com.google.backstory.AttackDetails.Technique.Builder.class); + } + + public static final int ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object id_ = ""; + + /** + * + * + *
+     * Technique ID (e.g. "T1595").
+     * 
+ * + * string id = 1; + * + * @return The id. + */ + @java.lang.Override + public java.lang.String getId() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } + } + + /** + * + * + *
+     * Technique ID (e.g. "T1595").
+     * 
+ * + * string id = 1; + * + * @return The bytes for id. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+     * Technique Name (e.g. "Active Scanning").
+     * 
+ * + * string name = 2; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+     * Technique Name (e.g. "Active Scanning").
+     * 
+ * + * string name = 2; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUBTECHNIQUE_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object subtechniqueId_ = ""; + + /** + * + * + *
+     * Subtechnique ID (e.g. "T1595.001").
+     * 
+ * + * string subtechnique_id = 3; + * + * @return The subtechniqueId. + */ + @java.lang.Override + public java.lang.String getSubtechniqueId() { + java.lang.Object ref = subtechniqueId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subtechniqueId_ = s; + return s; + } + } + + /** + * + * + *
+     * Subtechnique ID (e.g. "T1595.001").
+     * 
+ * + * string subtechnique_id = 3; + * + * @return The bytes for subtechniqueId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSubtechniqueIdBytes() { + java.lang.Object ref = subtechniqueId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subtechniqueId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUBTECHNIQUE_NAME_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object subtechniqueName_ = ""; + + /** + * + * + *
+     * Subtechnique Name (e.g. "Scanning IP Blocks").
+     * 
+ * + * string subtechnique_name = 4; + * + * @return The subtechniqueName. + */ + @java.lang.Override + public java.lang.String getSubtechniqueName() { + java.lang.Object ref = subtechniqueName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subtechniqueName_ = s; + return s; + } + } + + /** + * + * + *
+     * Subtechnique Name (e.g. "Scanning IP Blocks").
+     * 
+ * + * string subtechnique_name = 4; + * + * @return The bytes for subtechniqueName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSubtechniqueNameBytes() { + java.lang.Object ref = subtechniqueName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subtechniqueName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(subtechniqueId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, subtechniqueId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(subtechniqueName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, subtechniqueName_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(subtechniqueId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, subtechniqueId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(subtechniqueName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, subtechniqueName_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.AttackDetails.Technique)) { + return super.equals(obj); + } + com.google.backstory.AttackDetails.Technique other = + (com.google.backstory.AttackDetails.Technique) obj; + + if (!getId().equals(other.getId())) return false; + if (!getName().equals(other.getName())) return false; + if (!getSubtechniqueId().equals(other.getSubtechniqueId())) return false; + if (!getSubtechniqueName().equals(other.getSubtechniqueName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ID_FIELD_NUMBER; + hash = (53 * hash) + getId().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + SUBTECHNIQUE_ID_FIELD_NUMBER; + hash = (53 * hash) + getSubtechniqueId().hashCode(); + hash = (37 * hash) + SUBTECHNIQUE_NAME_FIELD_NUMBER; + hash = (53 * hash) + getSubtechniqueName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.AttackDetails.Technique parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Technique parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails.Technique parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails.Technique parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.AttackDetails.Technique prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * Technique information related to an attack or threat.
+     * 
+ * + * Protobuf type {@code google.backstory.AttackDetails.Technique} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.AttackDetails.Technique) + com.google.backstory.AttackDetails.TechniqueOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Technique_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Technique_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AttackDetails.Technique.class, + com.google.backstory.AttackDetails.Technique.Builder.class); + } + + // Construct using com.google.backstory.AttackDetails.Technique.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + id_ = ""; + name_ = ""; + subtechniqueId_ = ""; + subtechniqueName_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_Technique_descriptor; + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Technique getDefaultInstanceForType() { + return com.google.backstory.AttackDetails.Technique.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Technique build() { + com.google.backstory.AttackDetails.Technique result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Technique buildPartial() { + com.google.backstory.AttackDetails.Technique result = + new com.google.backstory.AttackDetails.Technique(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.AttackDetails.Technique result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.id_ = id_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.subtechniqueId_ = subtechniqueId_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.subtechniqueName_ = subtechniqueName_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.AttackDetails.Technique) { + return mergeFrom((com.google.backstory.AttackDetails.Technique) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.AttackDetails.Technique other) { + if (other == com.google.backstory.AttackDetails.Technique.getDefaultInstance()) return this; + if (!other.getId().isEmpty()) { + id_ = other.id_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getSubtechniqueId().isEmpty()) { + subtechniqueId_ = other.subtechniqueId_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getSubtechniqueName().isEmpty()) { + subtechniqueName_ = other.subtechniqueName_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + subtechniqueId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + subtechniqueName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object id_ = ""; + + /** + * + * + *
+       * Technique ID (e.g. "T1595").
+       * 
+ * + * string id = 1; + * + * @return The id. + */ + public java.lang.String getId() { + java.lang.Object ref = id_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Technique ID (e.g. "T1595").
+       * 
+ * + * string id = 1; + * + * @return The bytes for id. + */ + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Technique ID (e.g. "T1595").
+       * 
+ * + * string id = 1; + * + * @param value The id to set. + * @return This builder for chaining. + */ + public Builder setId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + id_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * Technique ID (e.g. "T1595").
+       * 
+ * + * string id = 1; + * + * @return This builder for chaining. + */ + public Builder clearId() { + id_ = getDefaultInstance().getId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+       * Technique ID (e.g. "T1595").
+       * 
+ * + * string id = 1; + * + * @param value The bytes for id to set. + * @return This builder for chaining. + */ + public Builder setIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + id_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object name_ = ""; + + /** + * + * + *
+       * Technique Name (e.g. "Active Scanning").
+       * 
+ * + * string name = 2; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Technique Name (e.g. "Active Scanning").
+       * 
+ * + * string name = 2; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Technique Name (e.g. "Active Scanning").
+       * 
+ * + * string name = 2; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Technique Name (e.g. "Active Scanning").
+       * 
+ * + * string name = 2; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+       * Technique Name (e.g. "Active Scanning").
+       * 
+ * + * string name = 2; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object subtechniqueId_ = ""; + + /** + * + * + *
+       * Subtechnique ID (e.g. "T1595.001").
+       * 
+ * + * string subtechnique_id = 3; + * + * @return The subtechniqueId. + */ + public java.lang.String getSubtechniqueId() { + java.lang.Object ref = subtechniqueId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subtechniqueId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Subtechnique ID (e.g. "T1595.001").
+       * 
+ * + * string subtechnique_id = 3; + * + * @return The bytes for subtechniqueId. + */ + public com.google.protobuf.ByteString getSubtechniqueIdBytes() { + java.lang.Object ref = subtechniqueId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subtechniqueId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Subtechnique ID (e.g. "T1595.001").
+       * 
+ * + * string subtechnique_id = 3; + * + * @param value The subtechniqueId to set. + * @return This builder for chaining. + */ + public Builder setSubtechniqueId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + subtechniqueId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * Subtechnique ID (e.g. "T1595.001").
+       * 
+ * + * string subtechnique_id = 3; + * + * @return This builder for chaining. + */ + public Builder clearSubtechniqueId() { + subtechniqueId_ = getDefaultInstance().getSubtechniqueId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+       * Subtechnique ID (e.g. "T1595.001").
+       * 
+ * + * string subtechnique_id = 3; + * + * @param value The bytes for subtechniqueId to set. + * @return This builder for chaining. + */ + public Builder setSubtechniqueIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + subtechniqueId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object subtechniqueName_ = ""; + + /** + * + * + *
+       * Subtechnique Name (e.g. "Scanning IP Blocks").
+       * 
+ * + * string subtechnique_name = 4; + * + * @return The subtechniqueName. + */ + public java.lang.String getSubtechniqueName() { + java.lang.Object ref = subtechniqueName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subtechniqueName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Subtechnique Name (e.g. "Scanning IP Blocks").
+       * 
+ * + * string subtechnique_name = 4; + * + * @return The bytes for subtechniqueName. + */ + public com.google.protobuf.ByteString getSubtechniqueNameBytes() { + java.lang.Object ref = subtechniqueName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subtechniqueName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Subtechnique Name (e.g. "Scanning IP Blocks").
+       * 
+ * + * string subtechnique_name = 4; + * + * @param value The subtechniqueName to set. + * @return This builder for chaining. + */ + public Builder setSubtechniqueName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + subtechniqueName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Subtechnique Name (e.g. "Scanning IP Blocks").
+       * 
+ * + * string subtechnique_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearSubtechniqueName() { + subtechniqueName_ = getDefaultInstance().getSubtechniqueName(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+       * Subtechnique Name (e.g. "Scanning IP Blocks").
+       * 
+ * + * string subtechnique_name = 4; + * + * @param value The bytes for subtechniqueName to set. + * @return This builder for chaining. + */ + public Builder setSubtechniqueNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + subtechniqueName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.AttackDetails.Technique) + } + + // @@protoc_insertion_point(class_scope:google.backstory.AttackDetails.Technique) + private static final com.google.backstory.AttackDetails.Technique DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.AttackDetails.Technique(); + } + + public static com.google.backstory.AttackDetails.Technique getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Technique parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.AttackDetails.Technique getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int VERSION_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object version_ = ""; + + /** + * + * + *
+   * ATT&CK version (e.g. 12.1).
+   * 
+ * + * string version = 1; + * + * @return The version. + */ + @java.lang.Override + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } + } + + /** + * + * + *
+   * ATT&CK version (e.g. 12.1).
+   * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TACTICS_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private java.util.List tactics_; + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + @java.lang.Override + public java.util.List getTacticsList() { + return tactics_; + } + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + @java.lang.Override + public java.util.List + getTacticsOrBuilderList() { + return tactics_; + } + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + @java.lang.Override + public int getTacticsCount() { + return tactics_.size(); + } + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + @java.lang.Override + public com.google.backstory.AttackDetails.Tactic getTactics(int index) { + return tactics_.get(index); + } + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + @java.lang.Override + public com.google.backstory.AttackDetails.TacticOrBuilder getTacticsOrBuilder(int index) { + return tactics_.get(index); + } + + public static final int TECHNIQUES_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private java.util.List techniques_; + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + @java.lang.Override + public java.util.List getTechniquesList() { + return techniques_; + } + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + @java.lang.Override + public java.util.List + getTechniquesOrBuilderList() { + return techniques_; + } + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + @java.lang.Override + public int getTechniquesCount() { + return techniques_.size(); + } + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + @java.lang.Override + public com.google.backstory.AttackDetails.Technique getTechniques(int index) { + return techniques_.get(index); + } + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + @java.lang.Override + public com.google.backstory.AttackDetails.TechniqueOrBuilder getTechniquesOrBuilder(int index) { + return techniques_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, version_); + } + for (int i = 0; i < tactics_.size(); i++) { + output.writeMessage(2, tactics_.get(i)); + } + for (int i = 0; i < techniques_.size(); i++) { + output.writeMessage(3, techniques_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, version_); + } + for (int i = 0; i < tactics_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, tactics_.get(i)); + } + for (int i = 0; i < techniques_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, techniques_.get(i)); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.AttackDetails)) { + return super.equals(obj); + } + com.google.backstory.AttackDetails other = (com.google.backstory.AttackDetails) obj; + + if (!getVersion().equals(other.getVersion())) return false; + if (!getTacticsList().equals(other.getTacticsList())) return false; + if (!getTechniquesList().equals(other.getTechniquesList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + if (getTacticsCount() > 0) { + hash = (37 * hash) + TACTICS_FIELD_NUMBER; + hash = (53 * hash) + getTacticsList().hashCode(); + } + if (getTechniquesCount() > 0) { + hash = (37 * hash) + TECHNIQUES_FIELD_NUMBER; + hash = (53 * hash) + getTechniquesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.AttackDetails parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.AttackDetails parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.AttackDetails parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AttackDetails parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.AttackDetails parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.AttackDetails parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.AttackDetails prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * MITRE ATT&CK details.
+   * 
+ * + * Protobuf type {@code google.backstory.AttackDetails} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.AttackDetails) + com.google.backstory.AttackDetailsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_AttackDetails_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_AttackDetails_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.AttackDetails.class, + com.google.backstory.AttackDetails.Builder.class); + } + + // Construct using com.google.backstory.AttackDetails.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + version_ = ""; + if (tacticsBuilder_ == null) { + tactics_ = java.util.Collections.emptyList(); + } else { + tactics_ = null; + tacticsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + if (techniquesBuilder_ == null) { + techniques_ = java.util.Collections.emptyList(); + } else { + techniques_ = null; + techniquesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000004); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_AttackDetails_descriptor; + } + + @java.lang.Override + public com.google.backstory.AttackDetails getDefaultInstanceForType() { + return com.google.backstory.AttackDetails.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.AttackDetails build() { + com.google.backstory.AttackDetails result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.AttackDetails buildPartial() { + com.google.backstory.AttackDetails result = new com.google.backstory.AttackDetails(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.AttackDetails result) { + if (tacticsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + tactics_ = java.util.Collections.unmodifiableList(tactics_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.tactics_ = tactics_; + } else { + result.tactics_ = tacticsBuilder_.build(); + } + if (techniquesBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0)) { + techniques_ = java.util.Collections.unmodifiableList(techniques_); + bitField0_ = (bitField0_ & ~0x00000004); + } + result.techniques_ = techniques_; + } else { + result.techniques_ = techniquesBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.AttackDetails result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.version_ = version_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.AttackDetails) { + return mergeFrom((com.google.backstory.AttackDetails) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.AttackDetails other) { + if (other == com.google.backstory.AttackDetails.getDefaultInstance()) return this; + if (!other.getVersion().isEmpty()) { + version_ = other.version_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (tacticsBuilder_ == null) { + if (!other.tactics_.isEmpty()) { + if (tactics_.isEmpty()) { + tactics_ = other.tactics_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureTacticsIsMutable(); + tactics_.addAll(other.tactics_); + } + onChanged(); + } + } else { + if (!other.tactics_.isEmpty()) { + if (tacticsBuilder_.isEmpty()) { + tacticsBuilder_.dispose(); + tacticsBuilder_ = null; + tactics_ = other.tactics_; + bitField0_ = (bitField0_ & ~0x00000002); + tacticsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetTacticsFieldBuilder() + : null; + } else { + tacticsBuilder_.addAllMessages(other.tactics_); + } + } + } + if (techniquesBuilder_ == null) { + if (!other.techniques_.isEmpty()) { + if (techniques_.isEmpty()) { + techniques_ = other.techniques_; + bitField0_ = (bitField0_ & ~0x00000004); + } else { + ensureTechniquesIsMutable(); + techniques_.addAll(other.techniques_); + } + onChanged(); + } + } else { + if (!other.techniques_.isEmpty()) { + if (techniquesBuilder_.isEmpty()) { + techniquesBuilder_.dispose(); + techniquesBuilder_ = null; + techniques_ = other.techniques_; + bitField0_ = (bitField0_ & ~0x00000004); + techniquesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetTechniquesFieldBuilder() + : null; + } else { + techniquesBuilder_.addAllMessages(other.techniques_); + } + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + version_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + com.google.backstory.AttackDetails.Tactic m = + input.readMessage( + com.google.backstory.AttackDetails.Tactic.parser(), extensionRegistry); + if (tacticsBuilder_ == null) { + ensureTacticsIsMutable(); + tactics_.add(m); + } else { + tacticsBuilder_.addMessage(m); + } + break; + } // case 18 + case 26: + { + com.google.backstory.AttackDetails.Technique m = + input.readMessage( + com.google.backstory.AttackDetails.Technique.parser(), extensionRegistry); + if (techniquesBuilder_ == null) { + ensureTechniquesIsMutable(); + techniques_.add(m); + } else { + techniquesBuilder_.addMessage(m); + } + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object version_ = ""; + + /** + * + * + *
+     * ATT&CK version (e.g. 12.1).
+     * 
+ * + * string version = 1; + * + * @return The version. + */ + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * ATT&CK version (e.g. 12.1).
+     * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * ATT&CK version (e.g. 12.1).
+     * 
+ * + * string version = 1; + * + * @param value The version to set. + * @return This builder for chaining. + */ + public Builder setVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + version_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * ATT&CK version (e.g. 12.1).
+     * 
+ * + * string version = 1; + * + * @return This builder for chaining. + */ + public Builder clearVersion() { + version_ = getDefaultInstance().getVersion(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * ATT&CK version (e.g. 12.1).
+     * 
+ * + * string version = 1; + * + * @param value The bytes for version to set. + * @return This builder for chaining. + */ + public Builder setVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + version_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.util.List tactics_ = + java.util.Collections.emptyList(); + + private void ensureTacticsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + tactics_ = new java.util.ArrayList(tactics_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.AttackDetails.Tactic, + com.google.backstory.AttackDetails.Tactic.Builder, + com.google.backstory.AttackDetails.TacticOrBuilder> + tacticsBuilder_; + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public java.util.List getTacticsList() { + if (tacticsBuilder_ == null) { + return java.util.Collections.unmodifiableList(tactics_); + } else { + return tacticsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public int getTacticsCount() { + if (tacticsBuilder_ == null) { + return tactics_.size(); + } else { + return tacticsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public com.google.backstory.AttackDetails.Tactic getTactics(int index) { + if (tacticsBuilder_ == null) { + return tactics_.get(index); + } else { + return tacticsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder setTactics(int index, com.google.backstory.AttackDetails.Tactic value) { + if (tacticsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTacticsIsMutable(); + tactics_.set(index, value); + onChanged(); + } else { + tacticsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder setTactics( + int index, com.google.backstory.AttackDetails.Tactic.Builder builderForValue) { + if (tacticsBuilder_ == null) { + ensureTacticsIsMutable(); + tactics_.set(index, builderForValue.build()); + onChanged(); + } else { + tacticsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder addTactics(com.google.backstory.AttackDetails.Tactic value) { + if (tacticsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTacticsIsMutable(); + tactics_.add(value); + onChanged(); + } else { + tacticsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder addTactics(int index, com.google.backstory.AttackDetails.Tactic value) { + if (tacticsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTacticsIsMutable(); + tactics_.add(index, value); + onChanged(); + } else { + tacticsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder addTactics(com.google.backstory.AttackDetails.Tactic.Builder builderForValue) { + if (tacticsBuilder_ == null) { + ensureTacticsIsMutable(); + tactics_.add(builderForValue.build()); + onChanged(); + } else { + tacticsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder addTactics( + int index, com.google.backstory.AttackDetails.Tactic.Builder builderForValue) { + if (tacticsBuilder_ == null) { + ensureTacticsIsMutable(); + tactics_.add(index, builderForValue.build()); + onChanged(); + } else { + tacticsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder addAllTactics( + java.lang.Iterable values) { + if (tacticsBuilder_ == null) { + ensureTacticsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tactics_); + onChanged(); + } else { + tacticsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder clearTactics() { + if (tacticsBuilder_ == null) { + tactics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + tacticsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public Builder removeTactics(int index) { + if (tacticsBuilder_ == null) { + ensureTacticsIsMutable(); + tactics_.remove(index); + onChanged(); + } else { + tacticsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public com.google.backstory.AttackDetails.Tactic.Builder getTacticsBuilder(int index) { + return internalGetTacticsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public com.google.backstory.AttackDetails.TacticOrBuilder getTacticsOrBuilder(int index) { + if (tacticsBuilder_ == null) { + return tactics_.get(index); + } else { + return tacticsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public java.util.List + getTacticsOrBuilderList() { + if (tacticsBuilder_ != null) { + return tacticsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(tactics_); + } + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public com.google.backstory.AttackDetails.Tactic.Builder addTacticsBuilder() { + return internalGetTacticsFieldBuilder() + .addBuilder(com.google.backstory.AttackDetails.Tactic.getDefaultInstance()); + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public com.google.backstory.AttackDetails.Tactic.Builder addTacticsBuilder(int index) { + return internalGetTacticsFieldBuilder() + .addBuilder(index, com.google.backstory.AttackDetails.Tactic.getDefaultInstance()); + } + + /** + * + * + *
+     * Tactics employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + public java.util.List + getTacticsBuilderList() { + return internalGetTacticsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.AttackDetails.Tactic, + com.google.backstory.AttackDetails.Tactic.Builder, + com.google.backstory.AttackDetails.TacticOrBuilder> + internalGetTacticsFieldBuilder() { + if (tacticsBuilder_ == null) { + tacticsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.AttackDetails.Tactic, + com.google.backstory.AttackDetails.Tactic.Builder, + com.google.backstory.AttackDetails.TacticOrBuilder>( + tactics_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + tactics_ = null; + } + return tacticsBuilder_; + } + + private java.util.List techniques_ = + java.util.Collections.emptyList(); + + private void ensureTechniquesIsMutable() { + if (!((bitField0_ & 0x00000004) != 0)) { + techniques_ = + new java.util.ArrayList(techniques_); + bitField0_ |= 0x00000004; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.AttackDetails.Technique, + com.google.backstory.AttackDetails.Technique.Builder, + com.google.backstory.AttackDetails.TechniqueOrBuilder> + techniquesBuilder_; + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public java.util.List getTechniquesList() { + if (techniquesBuilder_ == null) { + return java.util.Collections.unmodifiableList(techniques_); + } else { + return techniquesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public int getTechniquesCount() { + if (techniquesBuilder_ == null) { + return techniques_.size(); + } else { + return techniquesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public com.google.backstory.AttackDetails.Technique getTechniques(int index) { + if (techniquesBuilder_ == null) { + return techniques_.get(index); + } else { + return techniquesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder setTechniques(int index, com.google.backstory.AttackDetails.Technique value) { + if (techniquesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTechniquesIsMutable(); + techniques_.set(index, value); + onChanged(); + } else { + techniquesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder setTechniques( + int index, com.google.backstory.AttackDetails.Technique.Builder builderForValue) { + if (techniquesBuilder_ == null) { + ensureTechniquesIsMutable(); + techniques_.set(index, builderForValue.build()); + onChanged(); + } else { + techniquesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder addTechniques(com.google.backstory.AttackDetails.Technique value) { + if (techniquesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTechniquesIsMutable(); + techniques_.add(value); + onChanged(); + } else { + techniquesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder addTechniques(int index, com.google.backstory.AttackDetails.Technique value) { + if (techniquesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTechniquesIsMutable(); + techniques_.add(index, value); + onChanged(); + } else { + techniquesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder addTechniques( + com.google.backstory.AttackDetails.Technique.Builder builderForValue) { + if (techniquesBuilder_ == null) { + ensureTechniquesIsMutable(); + techniques_.add(builderForValue.build()); + onChanged(); + } else { + techniquesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder addTechniques( + int index, com.google.backstory.AttackDetails.Technique.Builder builderForValue) { + if (techniquesBuilder_ == null) { + ensureTechniquesIsMutable(); + techniques_.add(index, builderForValue.build()); + onChanged(); + } else { + techniquesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder addAllTechniques( + java.lang.Iterable values) { + if (techniquesBuilder_ == null) { + ensureTechniquesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, techniques_); + onChanged(); + } else { + techniquesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder clearTechniques() { + if (techniquesBuilder_ == null) { + techniques_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + } else { + techniquesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public Builder removeTechniques(int index) { + if (techniquesBuilder_ == null) { + ensureTechniquesIsMutable(); + techniques_.remove(index); + onChanged(); + } else { + techniquesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public com.google.backstory.AttackDetails.Technique.Builder getTechniquesBuilder(int index) { + return internalGetTechniquesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public com.google.backstory.AttackDetails.TechniqueOrBuilder getTechniquesOrBuilder(int index) { + if (techniquesBuilder_ == null) { + return techniques_.get(index); + } else { + return techniquesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public java.util.List + getTechniquesOrBuilderList() { + if (techniquesBuilder_ != null) { + return techniquesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(techniques_); + } + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public com.google.backstory.AttackDetails.Technique.Builder addTechniquesBuilder() { + return internalGetTechniquesFieldBuilder() + .addBuilder(com.google.backstory.AttackDetails.Technique.getDefaultInstance()); + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public com.google.backstory.AttackDetails.Technique.Builder addTechniquesBuilder(int index) { + return internalGetTechniquesFieldBuilder() + .addBuilder(index, com.google.backstory.AttackDetails.Technique.getDefaultInstance()); + } + + /** + * + * + *
+     * Techniques employed.
+     * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + public java.util.List + getTechniquesBuilderList() { + return internalGetTechniquesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.AttackDetails.Technique, + com.google.backstory.AttackDetails.Technique.Builder, + com.google.backstory.AttackDetails.TechniqueOrBuilder> + internalGetTechniquesFieldBuilder() { + if (techniquesBuilder_ == null) { + techniquesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.AttackDetails.Technique, + com.google.backstory.AttackDetails.Technique.Builder, + com.google.backstory.AttackDetails.TechniqueOrBuilder>( + techniques_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); + techniques_ = null; + } + return techniquesBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.AttackDetails) + } + + // @@protoc_insertion_point(class_scope:google.backstory.AttackDetails) + private static final com.google.backstory.AttackDetails DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.AttackDetails(); + } + + public static com.google.backstory.AttackDetails getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AttackDetails parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.AttackDetails getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java new file mode 100644 index 000000000000..df9f7a5f0a0a --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java @@ -0,0 +1,151 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AttackDetailsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.AttackDetails) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * ATT&CK version (e.g. 12.1).
+   * 
+ * + * string version = 1; + * + * @return The version. + */ + java.lang.String getVersion(); + + /** + * + * + *
+   * ATT&CK version (e.g. 12.1).
+   * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + com.google.protobuf.ByteString getVersionBytes(); + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + java.util.List getTacticsList(); + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + com.google.backstory.AttackDetails.Tactic getTactics(int index); + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + int getTacticsCount(); + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + java.util.List + getTacticsOrBuilderList(); + + /** + * + * + *
+   * Tactics employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Tactic tactics = 2; + */ + com.google.backstory.AttackDetails.TacticOrBuilder getTacticsOrBuilder(int index); + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + java.util.List getTechniquesList(); + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + com.google.backstory.AttackDetails.Technique getTechniques(int index); + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + int getTechniquesCount(); + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + java.util.List + getTechniquesOrBuilderList(); + + /** + * + * + *
+   * Techniques employed.
+   * 
+ * + * repeated .google.backstory.AttackDetails.Technique techniques = 3; + */ + com.google.backstory.AttackDetails.TechniqueOrBuilder getTechniquesOrBuilder(int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Attribute.java b/java-backstory/src/main/java/com/google/backstory/Attribute.java new file mode 100644 index 000000000000..7478bd836d8b --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Attribute.java @@ -0,0 +1,2856 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Attribute is a container for generic entity attributes including common
+ * attributes across core entities (such as, user or asset). For example, Cloud
+ * is a generic entity attribute since it can apply to an asset (for example, a
+ * VM) or a user (for example, an identity service account).
+ * 
+ * + * Protobuf type {@code google.backstory.Attribute} + */ +@com.google.protobuf.Generated +public final class Attribute extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Attribute) + AttributeOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Attribute"); + } + + // Use Attribute.newBuilder() to construct. + private Attribute(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Attribute() { + labels_ = java.util.Collections.emptyList(); + permissions_ = java.util.Collections.emptyList(); + roles_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Attribute_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Attribute_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Attribute.class, com.google.backstory.Attribute.Builder.class); + } + + private int bitField0_; + public static final int CLOUD_FIELD_NUMBER = 1; + private com.google.backstory.Cloud cloud_; + + /** + * + * + *
+   * Cloud metadata attributes such as project ID, account ID, or organizational
+   * hierarchy.
+   * 
+ * + * .google.backstory.Cloud cloud = 1; + * + * @return Whether the cloud field is set. + */ + @java.lang.Override + public boolean hasCloud() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Cloud metadata attributes such as project ID, account ID, or organizational
+   * hierarchy.
+   * 
+ * + * .google.backstory.Cloud cloud = 1; + * + * @return The cloud. + */ + @java.lang.Override + public com.google.backstory.Cloud getCloud() { + return cloud_ == null ? com.google.backstory.Cloud.getDefaultInstance() : cloud_; + } + + /** + * + * + *
+   * Cloud metadata attributes such as project ID, account ID, or organizational
+   * hierarchy.
+   * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + @java.lang.Override + public com.google.backstory.CloudOrBuilder getCloudOrBuilder() { + return cloud_ == null ? com.google.backstory.Cloud.getDefaultInstance() : cloud_; + } + + public static final int LABELS_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private java.util.List labels_; + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + @java.lang.Override + public java.util.List getLabelsList() { + return labels_; + } + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + @java.lang.Override + public java.util.List getLabelsOrBuilderList() { + return labels_; + } + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + @java.lang.Override + public int getLabelsCount() { + return labels_.size(); + } + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + @java.lang.Override + public com.google.backstory.Label getLabels(int index) { + return labels_.get(index); + } + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + @java.lang.Override + public com.google.backstory.LabelOrBuilder getLabelsOrBuilder(int index) { + return labels_.get(index); + } + + public static final int PERMISSIONS_FIELD_NUMBER = 705; + + @SuppressWarnings("serial") + private java.util.List permissions_; + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + @java.lang.Override + public java.util.List getPermissionsList() { + return permissions_; + } + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + @java.lang.Override + public java.util.List + getPermissionsOrBuilderList() { + return permissions_; + } + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + @java.lang.Override + public int getPermissionsCount() { + return permissions_.size(); + } + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + @java.lang.Override + public com.google.backstory.Permission getPermissions(int index) { + return permissions_.get(index); + } + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + @java.lang.Override + public com.google.backstory.PermissionOrBuilder getPermissionsOrBuilder(int index) { + return permissions_.get(index); + } + + public static final int ROLES_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private java.util.List roles_; + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + @java.lang.Override + public java.util.List getRolesList() { + return roles_; + } + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + @java.lang.Override + public java.util.List getRolesOrBuilderList() { + return roles_; + } + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + @java.lang.Override + public int getRolesCount() { + return roles_.size(); + } + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + @java.lang.Override + public com.google.backstory.Role getRoles(int index) { + return roles_.get(index); + } + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + @java.lang.Override + public com.google.backstory.RoleOrBuilder getRolesOrBuilder(int index) { + return roles_.get(index); + } + + public static final int CREATION_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp creationTime_; + + /** + * + * + *
+   * Time the resource or entity was created or provisioned.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + * + * @return Whether the creationTime field is set. + */ + @java.lang.Override + public boolean hasCreationTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Time the resource or entity was created or provisioned.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + * + * @return The creationTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreationTime() { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } + + /** + * + * + *
+   * Time the resource or entity was created or provisioned.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreationTimeOrBuilder() { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } + + public static final int LAST_UPDATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp lastUpdateTime_; + + /** + * + * + *
+   * Time the resource or entity was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + * + * @return Whether the lastUpdateTime field is set. + */ + @java.lang.Override + public boolean hasLastUpdateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Time the resource or entity was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + * + * @return The lastUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastUpdateTime() { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + + /** + * + * + *
+   * Time the resource or entity was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getCloud()); + } + for (int i = 0; i < labels_.size(); i++) { + output.writeMessage(2, labels_.get(i)); + } + for (int i = 0; i < roles_.size(); i++) { + output.writeMessage(3, roles_.get(i)); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getCreationTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(5, getLastUpdateTime()); + } + for (int i = 0; i < permissions_.size(); i++) { + output.writeMessage(705, permissions_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCloud()); + } + for (int i = 0; i < labels_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, labels_.get(i)); + } + for (int i = 0; i < roles_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, roles_.get(i)); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getCreationTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getLastUpdateTime()); + } + for (int i = 0; i < permissions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(705, permissions_.get(i)); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Attribute)) { + return super.equals(obj); + } + com.google.backstory.Attribute other = (com.google.backstory.Attribute) obj; + + if (hasCloud() != other.hasCloud()) return false; + if (hasCloud()) { + if (!getCloud().equals(other.getCloud())) return false; + } + if (!getLabelsList().equals(other.getLabelsList())) return false; + if (!getPermissionsList().equals(other.getPermissionsList())) return false; + if (!getRolesList().equals(other.getRolesList())) return false; + if (hasCreationTime() != other.hasCreationTime()) return false; + if (hasCreationTime()) { + if (!getCreationTime().equals(other.getCreationTime())) return false; + } + if (hasLastUpdateTime() != other.hasLastUpdateTime()) return false; + if (hasLastUpdateTime()) { + if (!getLastUpdateTime().equals(other.getLastUpdateTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasCloud()) { + hash = (37 * hash) + CLOUD_FIELD_NUMBER; + hash = (53 * hash) + getCloud().hashCode(); + } + if (getLabelsCount() > 0) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + getLabelsList().hashCode(); + } + if (getPermissionsCount() > 0) { + hash = (37 * hash) + PERMISSIONS_FIELD_NUMBER; + hash = (53 * hash) + getPermissionsList().hashCode(); + } + if (getRolesCount() > 0) { + hash = (37 * hash) + ROLES_FIELD_NUMBER; + hash = (53 * hash) + getRolesList().hashCode(); + } + if (hasCreationTime()) { + hash = (37 * hash) + CREATION_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreationTime().hashCode(); + } + if (hasLastUpdateTime()) { + hash = (37 * hash) + LAST_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastUpdateTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Attribute parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Attribute parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Attribute parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Attribute parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Attribute parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Attribute parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Attribute parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Attribute parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Attribute parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Attribute parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Attribute parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Attribute parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Attribute prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Attribute is a container for generic entity attributes including common
+   * attributes across core entities (such as, user or asset). For example, Cloud
+   * is a generic entity attribute since it can apply to an asset (for example, a
+   * VM) or a user (for example, an identity service account).
+   * 
+ * + * Protobuf type {@code google.backstory.Attribute} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Attribute) + com.google.backstory.AttributeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Attribute_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Attribute_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Attribute.class, com.google.backstory.Attribute.Builder.class); + } + + // Construct using com.google.backstory.Attribute.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCloudFieldBuilder(); + internalGetLabelsFieldBuilder(); + internalGetPermissionsFieldBuilder(); + internalGetRolesFieldBuilder(); + internalGetCreationTimeFieldBuilder(); + internalGetLastUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + cloud_ = null; + if (cloudBuilder_ != null) { + cloudBuilder_.dispose(); + cloudBuilder_ = null; + } + if (labelsBuilder_ == null) { + labels_ = java.util.Collections.emptyList(); + } else { + labels_ = null; + labelsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + if (permissionsBuilder_ == null) { + permissions_ = java.util.Collections.emptyList(); + } else { + permissions_ = null; + permissionsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000004); + if (rolesBuilder_ == null) { + roles_ = java.util.Collections.emptyList(); + } else { + roles_ = null; + rolesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000008); + creationTime_ = null; + if (creationTimeBuilder_ != null) { + creationTimeBuilder_.dispose(); + creationTimeBuilder_ = null; + } + lastUpdateTime_ = null; + if (lastUpdateTimeBuilder_ != null) { + lastUpdateTimeBuilder_.dispose(); + lastUpdateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Attribute_descriptor; + } + + @java.lang.Override + public com.google.backstory.Attribute getDefaultInstanceForType() { + return com.google.backstory.Attribute.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Attribute build() { + com.google.backstory.Attribute result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Attribute buildPartial() { + com.google.backstory.Attribute result = new com.google.backstory.Attribute(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.Attribute result) { + if (labelsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + labels_ = java.util.Collections.unmodifiableList(labels_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.labels_ = labels_; + } else { + result.labels_ = labelsBuilder_.build(); + } + if (permissionsBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0)) { + permissions_ = java.util.Collections.unmodifiableList(permissions_); + bitField0_ = (bitField0_ & ~0x00000004); + } + result.permissions_ = permissions_; + } else { + result.permissions_ = permissionsBuilder_.build(); + } + if (rolesBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0)) { + roles_ = java.util.Collections.unmodifiableList(roles_); + bitField0_ = (bitField0_ & ~0x00000008); + } + result.roles_ = roles_; + } else { + result.roles_ = rolesBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.Attribute result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.cloud_ = cloudBuilder_ == null ? cloud_ : cloudBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.creationTime_ = + creationTimeBuilder_ == null ? creationTime_ : creationTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.lastUpdateTime_ = + lastUpdateTimeBuilder_ == null ? lastUpdateTime_ : lastUpdateTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Attribute) { + return mergeFrom((com.google.backstory.Attribute) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Attribute other) { + if (other == com.google.backstory.Attribute.getDefaultInstance()) return this; + if (other.hasCloud()) { + mergeCloud(other.getCloud()); + } + if (labelsBuilder_ == null) { + if (!other.labels_.isEmpty()) { + if (labels_.isEmpty()) { + labels_ = other.labels_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureLabelsIsMutable(); + labels_.addAll(other.labels_); + } + onChanged(); + } + } else { + if (!other.labels_.isEmpty()) { + if (labelsBuilder_.isEmpty()) { + labelsBuilder_.dispose(); + labelsBuilder_ = null; + labels_ = other.labels_; + bitField0_ = (bitField0_ & ~0x00000002); + labelsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetLabelsFieldBuilder() + : null; + } else { + labelsBuilder_.addAllMessages(other.labels_); + } + } + } + if (permissionsBuilder_ == null) { + if (!other.permissions_.isEmpty()) { + if (permissions_.isEmpty()) { + permissions_ = other.permissions_; + bitField0_ = (bitField0_ & ~0x00000004); + } else { + ensurePermissionsIsMutable(); + permissions_.addAll(other.permissions_); + } + onChanged(); + } + } else { + if (!other.permissions_.isEmpty()) { + if (permissionsBuilder_.isEmpty()) { + permissionsBuilder_.dispose(); + permissionsBuilder_ = null; + permissions_ = other.permissions_; + bitField0_ = (bitField0_ & ~0x00000004); + permissionsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetPermissionsFieldBuilder() + : null; + } else { + permissionsBuilder_.addAllMessages(other.permissions_); + } + } + } + if (rolesBuilder_ == null) { + if (!other.roles_.isEmpty()) { + if (roles_.isEmpty()) { + roles_ = other.roles_; + bitField0_ = (bitField0_ & ~0x00000008); + } else { + ensureRolesIsMutable(); + roles_.addAll(other.roles_); + } + onChanged(); + } + } else { + if (!other.roles_.isEmpty()) { + if (rolesBuilder_.isEmpty()) { + rolesBuilder_.dispose(); + rolesBuilder_ = null; + roles_ = other.roles_; + bitField0_ = (bitField0_ & ~0x00000008); + rolesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetRolesFieldBuilder() + : null; + } else { + rolesBuilder_.addAllMessages(other.roles_); + } + } + } + if (other.hasCreationTime()) { + mergeCreationTime(other.getCreationTime()); + } + if (other.hasLastUpdateTime()) { + mergeLastUpdateTime(other.getLastUpdateTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(internalGetCloudFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + com.google.backstory.Label m = + input.readMessage(com.google.backstory.Label.parser(), extensionRegistry); + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.add(m); + } else { + labelsBuilder_.addMessage(m); + } + break; + } // case 18 + case 26: + { + com.google.backstory.Role m = + input.readMessage(com.google.backstory.Role.parser(), extensionRegistry); + if (rolesBuilder_ == null) { + ensureRolesIsMutable(); + roles_.add(m); + } else { + rolesBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetCreationTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetLastUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 42 + case 5642: + { + com.google.backstory.Permission m = + input.readMessage(com.google.backstory.Permission.parser(), extensionRegistry); + if (permissionsBuilder_ == null) { + ensurePermissionsIsMutable(); + permissions_.add(m); + } else { + permissionsBuilder_.addMessage(m); + } + break; + } // case 5642 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.backstory.Cloud cloud_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Cloud, + com.google.backstory.Cloud.Builder, + com.google.backstory.CloudOrBuilder> + cloudBuilder_; + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + * + * @return Whether the cloud field is set. + */ + public boolean hasCloud() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + * + * @return The cloud. + */ + public com.google.backstory.Cloud getCloud() { + if (cloudBuilder_ == null) { + return cloud_ == null ? com.google.backstory.Cloud.getDefaultInstance() : cloud_; + } else { + return cloudBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + public Builder setCloud(com.google.backstory.Cloud value) { + if (cloudBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + cloud_ = value; + } else { + cloudBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + public Builder setCloud(com.google.backstory.Cloud.Builder builderForValue) { + if (cloudBuilder_ == null) { + cloud_ = builderForValue.build(); + } else { + cloudBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + public Builder mergeCloud(com.google.backstory.Cloud value) { + if (cloudBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && cloud_ != null + && cloud_ != com.google.backstory.Cloud.getDefaultInstance()) { + getCloudBuilder().mergeFrom(value); + } else { + cloud_ = value; + } + } else { + cloudBuilder_.mergeFrom(value); + } + if (cloud_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + public Builder clearCloud() { + bitField0_ = (bitField0_ & ~0x00000001); + cloud_ = null; + if (cloudBuilder_ != null) { + cloudBuilder_.dispose(); + cloudBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + public com.google.backstory.Cloud.Builder getCloudBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetCloudFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + public com.google.backstory.CloudOrBuilder getCloudOrBuilder() { + if (cloudBuilder_ != null) { + return cloudBuilder_.getMessageOrBuilder(); + } else { + return cloud_ == null ? com.google.backstory.Cloud.getDefaultInstance() : cloud_; + } + } + + /** + * + * + *
+     * Cloud metadata attributes such as project ID, account ID, or organizational
+     * hierarchy.
+     * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Cloud, + com.google.backstory.Cloud.Builder, + com.google.backstory.CloudOrBuilder> + internalGetCloudFieldBuilder() { + if (cloudBuilder_ == null) { + cloudBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Cloud, + com.google.backstory.Cloud.Builder, + com.google.backstory.CloudOrBuilder>(getCloud(), getParentForChildren(), isClean()); + cloud_ = null; + } + return cloudBuilder_; + } + + private java.util.List labels_ = java.util.Collections.emptyList(); + + private void ensureLabelsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + labels_ = new java.util.ArrayList(labels_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Label, + com.google.backstory.Label.Builder, + com.google.backstory.LabelOrBuilder> + labelsBuilder_; + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public java.util.List getLabelsList() { + if (labelsBuilder_ == null) { + return java.util.Collections.unmodifiableList(labels_); + } else { + return labelsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public int getLabelsCount() { + if (labelsBuilder_ == null) { + return labels_.size(); + } else { + return labelsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public com.google.backstory.Label getLabels(int index) { + if (labelsBuilder_ == null) { + return labels_.get(index); + } else { + return labelsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder setLabels(int index, com.google.backstory.Label value) { + if (labelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureLabelsIsMutable(); + labels_.set(index, value); + onChanged(); + } else { + labelsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder setLabels(int index, com.google.backstory.Label.Builder builderForValue) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.set(index, builderForValue.build()); + onChanged(); + } else { + labelsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder addLabels(com.google.backstory.Label value) { + if (labelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureLabelsIsMutable(); + labels_.add(value); + onChanged(); + } else { + labelsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder addLabels(int index, com.google.backstory.Label value) { + if (labelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureLabelsIsMutable(); + labels_.add(index, value); + onChanged(); + } else { + labelsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder addLabels(com.google.backstory.Label.Builder builderForValue) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.add(builderForValue.build()); + onChanged(); + } else { + labelsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder addLabels(int index, com.google.backstory.Label.Builder builderForValue) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.add(index, builderForValue.build()); + onChanged(); + } else { + labelsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder addAllLabels(java.lang.Iterable values) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, labels_); + onChanged(); + } else { + labelsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder clearLabels() { + if (labelsBuilder_ == null) { + labels_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + labelsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public Builder removeLabels(int index) { + if (labelsBuilder_ == null) { + ensureLabelsIsMutable(); + labels_.remove(index); + onChanged(); + } else { + labelsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public com.google.backstory.Label.Builder getLabelsBuilder(int index) { + return internalGetLabelsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public com.google.backstory.LabelOrBuilder getLabelsOrBuilder(int index) { + if (labelsBuilder_ == null) { + return labels_.get(index); + } else { + return labelsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public java.util.List getLabelsOrBuilderList() { + if (labelsBuilder_ != null) { + return labelsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(labels_); + } + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public com.google.backstory.Label.Builder addLabelsBuilder() { + return internalGetLabelsFieldBuilder() + .addBuilder(com.google.backstory.Label.getDefaultInstance()); + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public com.google.backstory.Label.Builder addLabelsBuilder(int index) { + return internalGetLabelsFieldBuilder() + .addBuilder(index, com.google.backstory.Label.getDefaultInstance()); + } + + /** + * + * + *
+     * Set of labels for the entity. Should only be used for product labels (for
+     * example, Google Cloud resource labels or Azure AD sensitivity labels.
+     * Should not be used for arbitrary key-value mappings.
+     * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + public java.util.List getLabelsBuilderList() { + return internalGetLabelsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Label, + com.google.backstory.Label.Builder, + com.google.backstory.LabelOrBuilder> + internalGetLabelsFieldBuilder() { + if (labelsBuilder_ == null) { + labelsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Label, + com.google.backstory.Label.Builder, + com.google.backstory.LabelOrBuilder>( + labels_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + labels_ = null; + } + return labelsBuilder_; + } + + private java.util.List permissions_ = + java.util.Collections.emptyList(); + + private void ensurePermissionsIsMutable() { + if (!((bitField0_ & 0x00000004) != 0)) { + permissions_ = new java.util.ArrayList(permissions_); + bitField0_ |= 0x00000004; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Permission, + com.google.backstory.Permission.Builder, + com.google.backstory.PermissionOrBuilder> + permissionsBuilder_; + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public java.util.List getPermissionsList() { + if (permissionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(permissions_); + } else { + return permissionsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public int getPermissionsCount() { + if (permissionsBuilder_ == null) { + return permissions_.size(); + } else { + return permissionsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public com.google.backstory.Permission getPermissions(int index) { + if (permissionsBuilder_ == null) { + return permissions_.get(index); + } else { + return permissionsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder setPermissions(int index, com.google.backstory.Permission value) { + if (permissionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); + permissions_.set(index, value); + onChanged(); + } else { + permissionsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder setPermissions( + int index, com.google.backstory.Permission.Builder builderForValue) { + if (permissionsBuilder_ == null) { + ensurePermissionsIsMutable(); + permissions_.set(index, builderForValue.build()); + onChanged(); + } else { + permissionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder addPermissions(com.google.backstory.Permission value) { + if (permissionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); + permissions_.add(value); + onChanged(); + } else { + permissionsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder addPermissions(int index, com.google.backstory.Permission value) { + if (permissionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); + permissions_.add(index, value); + onChanged(); + } else { + permissionsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder addPermissions(com.google.backstory.Permission.Builder builderForValue) { + if (permissionsBuilder_ == null) { + ensurePermissionsIsMutable(); + permissions_.add(builderForValue.build()); + onChanged(); + } else { + permissionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder addPermissions( + int index, com.google.backstory.Permission.Builder builderForValue) { + if (permissionsBuilder_ == null) { + ensurePermissionsIsMutable(); + permissions_.add(index, builderForValue.build()); + onChanged(); + } else { + permissionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder addAllPermissions( + java.lang.Iterable values) { + if (permissionsBuilder_ == null) { + ensurePermissionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, permissions_); + onChanged(); + } else { + permissionsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder clearPermissions() { + if (permissionsBuilder_ == null) { + permissions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + } else { + permissionsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public Builder removePermissions(int index) { + if (permissionsBuilder_ == null) { + ensurePermissionsIsMutable(); + permissions_.remove(index); + onChanged(); + } else { + permissionsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public com.google.backstory.Permission.Builder getPermissionsBuilder(int index) { + return internalGetPermissionsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public com.google.backstory.PermissionOrBuilder getPermissionsOrBuilder(int index) { + if (permissionsBuilder_ == null) { + return permissions_.get(index); + } else { + return permissionsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public java.util.List + getPermissionsOrBuilderList() { + if (permissionsBuilder_ != null) { + return permissionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(permissions_); + } + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public com.google.backstory.Permission.Builder addPermissionsBuilder() { + return internalGetPermissionsFieldBuilder() + .addBuilder(com.google.backstory.Permission.getDefaultInstance()); + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public com.google.backstory.Permission.Builder addPermissionsBuilder(int index) { + return internalGetPermissionsFieldBuilder() + .addBuilder(index, com.google.backstory.Permission.getDefaultInstance()); + } + + /** + * + * + *
+     * System permissions for IAM entity
+     * (human principal, service account, group).
+     * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + public java.util.List getPermissionsBuilderList() { + return internalGetPermissionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Permission, + com.google.backstory.Permission.Builder, + com.google.backstory.PermissionOrBuilder> + internalGetPermissionsFieldBuilder() { + if (permissionsBuilder_ == null) { + permissionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Permission, + com.google.backstory.Permission.Builder, + com.google.backstory.PermissionOrBuilder>( + permissions_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); + permissions_ = null; + } + return permissionsBuilder_; + } + + private java.util.List roles_ = java.util.Collections.emptyList(); + + private void ensureRolesIsMutable() { + if (!((bitField0_ & 0x00000008) != 0)) { + roles_ = new java.util.ArrayList(roles_); + bitField0_ |= 0x00000008; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Role, + com.google.backstory.Role.Builder, + com.google.backstory.RoleOrBuilder> + rolesBuilder_; + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public java.util.List getRolesList() { + if (rolesBuilder_ == null) { + return java.util.Collections.unmodifiableList(roles_); + } else { + return rolesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public int getRolesCount() { + if (rolesBuilder_ == null) { + return roles_.size(); + } else { + return rolesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public com.google.backstory.Role getRoles(int index) { + if (rolesBuilder_ == null) { + return roles_.get(index); + } else { + return rolesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder setRoles(int index, com.google.backstory.Role value) { + if (rolesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRolesIsMutable(); + roles_.set(index, value); + onChanged(); + } else { + rolesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder setRoles(int index, com.google.backstory.Role.Builder builderForValue) { + if (rolesBuilder_ == null) { + ensureRolesIsMutable(); + roles_.set(index, builderForValue.build()); + onChanged(); + } else { + rolesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder addRoles(com.google.backstory.Role value) { + if (rolesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRolesIsMutable(); + roles_.add(value); + onChanged(); + } else { + rolesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder addRoles(int index, com.google.backstory.Role value) { + if (rolesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRolesIsMutable(); + roles_.add(index, value); + onChanged(); + } else { + rolesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder addRoles(com.google.backstory.Role.Builder builderForValue) { + if (rolesBuilder_ == null) { + ensureRolesIsMutable(); + roles_.add(builderForValue.build()); + onChanged(); + } else { + rolesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder addRoles(int index, com.google.backstory.Role.Builder builderForValue) { + if (rolesBuilder_ == null) { + ensureRolesIsMutable(); + roles_.add(index, builderForValue.build()); + onChanged(); + } else { + rolesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder addAllRoles(java.lang.Iterable values) { + if (rolesBuilder_ == null) { + ensureRolesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, roles_); + onChanged(); + } else { + rolesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder clearRoles() { + if (rolesBuilder_ == null) { + roles_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + } else { + rolesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public Builder removeRoles(int index) { + if (rolesBuilder_ == null) { + ensureRolesIsMutable(); + roles_.remove(index); + onChanged(); + } else { + rolesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public com.google.backstory.Role.Builder getRolesBuilder(int index) { + return internalGetRolesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public com.google.backstory.RoleOrBuilder getRolesOrBuilder(int index) { + if (rolesBuilder_ == null) { + return roles_.get(index); + } else { + return rolesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public java.util.List getRolesOrBuilderList() { + if (rolesBuilder_ != null) { + return rolesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(roles_); + } + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public com.google.backstory.Role.Builder addRolesBuilder() { + return internalGetRolesFieldBuilder() + .addBuilder(com.google.backstory.Role.getDefaultInstance()); + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public com.google.backstory.Role.Builder addRolesBuilder(int index) { + return internalGetRolesFieldBuilder() + .addBuilder(index, com.google.backstory.Role.getDefaultInstance()); + } + + /** + * + * + *
+     * System IAM roles to be assumed by resources to use the role's permissions
+     * for access control.
+     * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + public java.util.List getRolesBuilderList() { + return internalGetRolesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Role, + com.google.backstory.Role.Builder, + com.google.backstory.RoleOrBuilder> + internalGetRolesFieldBuilder() { + if (rolesBuilder_ == null) { + rolesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Role, + com.google.backstory.Role.Builder, + com.google.backstory.RoleOrBuilder>( + roles_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); + roles_ = null; + } + return rolesBuilder_; + } + + private com.google.protobuf.Timestamp creationTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + creationTimeBuilder_; + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + * + * @return Whether the creationTime field is set. + */ + public boolean hasCreationTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + * + * @return The creationTime. + */ + public com.google.protobuf.Timestamp getCreationTime() { + if (creationTimeBuilder_ == null) { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } else { + return creationTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + public Builder setCreationTime(com.google.protobuf.Timestamp value) { + if (creationTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + creationTime_ = value; + } else { + creationTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + public Builder setCreationTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (creationTimeBuilder_ == null) { + creationTime_ = builderForValue.build(); + } else { + creationTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + public Builder mergeCreationTime(com.google.protobuf.Timestamp value) { + if (creationTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && creationTime_ != null + && creationTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreationTimeBuilder().mergeFrom(value); + } else { + creationTime_ = value; + } + } else { + creationTimeBuilder_.mergeFrom(value); + } + if (creationTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + public Builder clearCreationTime() { + bitField0_ = (bitField0_ & ~0x00000010); + creationTime_ = null; + if (creationTimeBuilder_ != null) { + creationTimeBuilder_.dispose(); + creationTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + public com.google.protobuf.Timestamp.Builder getCreationTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetCreationTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + public com.google.protobuf.TimestampOrBuilder getCreationTimeOrBuilder() { + if (creationTimeBuilder_ != null) { + return creationTimeBuilder_.getMessageOrBuilder(); + } else { + return creationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : creationTime_; + } + } + + /** + * + * + *
+     * Time the resource or entity was created or provisioned.
+     * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreationTimeFieldBuilder() { + if (creationTimeBuilder_ == null) { + creationTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreationTime(), getParentForChildren(), isClean()); + creationTime_ = null; + } + return creationTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastUpdateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastUpdateTimeBuilder_; + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + * + * @return Whether the lastUpdateTime field is set. + */ + public boolean hasLastUpdateTime() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + * + * @return The lastUpdateTime. + */ + public com.google.protobuf.Timestamp getLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } else { + return lastUpdateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastUpdateTime_ = value; + } else { + lastUpdateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = builderForValue.build(); + } else { + lastUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + public Builder mergeLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && lastUpdateTime_ != null + && lastUpdateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastUpdateTimeBuilder().mergeFrom(value); + } else { + lastUpdateTime_ = value; + } + } else { + lastUpdateTimeBuilder_.mergeFrom(value); + } + if (lastUpdateTime_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + public Builder clearLastUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000020); + lastUpdateTime_ = null; + if (lastUpdateTimeBuilder_ != null) { + lastUpdateTimeBuilder_.dispose(); + lastUpdateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getLastUpdateTimeBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetLastUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + if (lastUpdateTimeBuilder_ != null) { + return lastUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + } + + /** + * + * + *
+     * Time the resource or entity was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastUpdateTimeFieldBuilder() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastUpdateTime(), getParentForChildren(), isClean()); + lastUpdateTime_ = null; + } + return lastUpdateTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Attribute) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Attribute) + private static final com.google.backstory.Attribute DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Attribute(); + } + + public static com.google.backstory.Attribute getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Attribute parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Attribute getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java new file mode 100644 index 000000000000..fe55d02f8189 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java @@ -0,0 +1,312 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AttributeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Attribute) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Cloud metadata attributes such as project ID, account ID, or organizational
+   * hierarchy.
+   * 
+ * + * .google.backstory.Cloud cloud = 1; + * + * @return Whether the cloud field is set. + */ + boolean hasCloud(); + + /** + * + * + *
+   * Cloud metadata attributes such as project ID, account ID, or organizational
+   * hierarchy.
+   * 
+ * + * .google.backstory.Cloud cloud = 1; + * + * @return The cloud. + */ + com.google.backstory.Cloud getCloud(); + + /** + * + * + *
+   * Cloud metadata attributes such as project ID, account ID, or organizational
+   * hierarchy.
+   * 
+ * + * .google.backstory.Cloud cloud = 1; + */ + com.google.backstory.CloudOrBuilder getCloudOrBuilder(); + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + java.util.List getLabelsList(); + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + com.google.backstory.Label getLabels(int index); + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + int getLabelsCount(); + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + java.util.List getLabelsOrBuilderList(); + + /** + * + * + *
+   * Set of labels for the entity. Should only be used for product labels (for
+   * example, Google Cloud resource labels or Azure AD sensitivity labels.
+   * Should not be used for arbitrary key-value mappings.
+   * 
+ * + * repeated .google.backstory.Label labels = 2; + */ + com.google.backstory.LabelOrBuilder getLabelsOrBuilder(int index); + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + java.util.List getPermissionsList(); + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + com.google.backstory.Permission getPermissions(int index); + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + int getPermissionsCount(); + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + java.util.List getPermissionsOrBuilderList(); + + /** + * + * + *
+   * System permissions for IAM entity
+   * (human principal, service account, group).
+   * 
+ * + * repeated .google.backstory.Permission permissions = 705; + */ + com.google.backstory.PermissionOrBuilder getPermissionsOrBuilder(int index); + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + java.util.List getRolesList(); + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + com.google.backstory.Role getRoles(int index); + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + int getRolesCount(); + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + java.util.List getRolesOrBuilderList(); + + /** + * + * + *
+   * System IAM roles to be assumed by resources to use the role's permissions
+   * for access control.
+   * 
+ * + * repeated .google.backstory.Role roles = 3; + */ + com.google.backstory.RoleOrBuilder getRolesOrBuilder(int index); + + /** + * + * + *
+   * Time the resource or entity was created or provisioned.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + * + * @return Whether the creationTime field is set. + */ + boolean hasCreationTime(); + + /** + * + * + *
+   * Time the resource or entity was created or provisioned.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + * + * @return The creationTime. + */ + com.google.protobuf.Timestamp getCreationTime(); + + /** + * + * + *
+   * Time the resource or entity was created or provisioned.
+   * 
+ * + * .google.protobuf.Timestamp creation_time = 4; + */ + com.google.protobuf.TimestampOrBuilder getCreationTimeOrBuilder(); + + /** + * + * + *
+   * Time the resource or entity was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + * + * @return Whether the lastUpdateTime field is set. + */ + boolean hasLastUpdateTime(); + + /** + * + * + *
+   * Time the resource or entity was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + * + * @return The lastUpdateTime. + */ + com.google.protobuf.Timestamp getLastUpdateTime(); + + /** + * + * + *
+   * Time the resource or entity was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Authentication.java b/java-backstory/src/main/java/com/google/backstory/Authentication.java new file mode 100644 index 000000000000..9b3118dd3a8e --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Authentication.java @@ -0,0 +1,2523 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * The Authentication extension captures details specific to authentication
+ * events.
+ * General guidelines for authentication events:
+ * * Details about the source of the authentication event (for example, client
+ * IP or hostname), should be captured in principal. The principal may be
+ * empty if we have no details about the source of the login.
+ * * Details about the target of the authentication event (for example, details
+ * about the machine that is being logged into or logged out of) should be
+ * captured in target.
+ * * Some authentication events may involve a third-party. For example, a user
+ * logs into
+ * a cloud service (for example, Chronicle) via their company's SSO (the
+ * event is logged by their SSO solution). In this case, the principal
+ * captures information about the user's device, the target captures details
+ * about the cloud service they logged into, and the intermediary captures
+ * details about the SSO solution.
+ * 
+ * + * Protobuf type {@code google.backstory.Authentication} + */ +@com.google.protobuf.Generated +public final class Authentication extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Authentication) + AuthenticationOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Authentication"); + } + + // Use Authentication.newBuilder() to construct. + private Authentication(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Authentication() { + type_ = 0; + mechanism_ = emptyIntList(); + authDetails_ = ""; + outcome_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Authentication_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Authentication_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Authentication.class, + com.google.backstory.Authentication.Builder.class); + } + + /** + * + * + *
+   * Type of system the authentication event is associated with.
+   * 
+ * + * Protobuf enum {@code google.backstory.Authentication.AuthType} + */ + public enum AuthType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default type.
+     * 
+ * + * AUTHTYPE_UNSPECIFIED = 0; + */ + AUTHTYPE_UNSPECIFIED(0), + /** + * + * + *
+     * A machine authentication.
+     * 
+ * + * MACHINE = 1; + */ + MACHINE(1), + /** + * + * + *
+     * An SSO authentication.
+     * 
+ * + * SSO = 2; + */ + SSO(2), + /** + * + * + *
+     * A VPN authentication.
+     * 
+ * + * VPN = 3; + */ + VPN(3), + /** + * + * + *
+     * A Physical authentication (e.g. "Badge reader").
+     * 
+ * + * PHYSICAL = 4; + */ + PHYSICAL(4), + /** + * + * + *
+     * A TACACS family protocol for networked systems authentication
+     * (e.g. TACACS, TACACS+).
+     * 
+ * + * TACACS = 5; + */ + TACACS(5), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AuthType"); + } + + /** + * + * + *
+     * The default type.
+     * 
+ * + * AUTHTYPE_UNSPECIFIED = 0; + */ + public static final int AUTHTYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * A machine authentication.
+     * 
+ * + * MACHINE = 1; + */ + public static final int MACHINE_VALUE = 1; + + /** + * + * + *
+     * An SSO authentication.
+     * 
+ * + * SSO = 2; + */ + public static final int SSO_VALUE = 2; + + /** + * + * + *
+     * A VPN authentication.
+     * 
+ * + * VPN = 3; + */ + public static final int VPN_VALUE = 3; + + /** + * + * + *
+     * A Physical authentication (e.g. "Badge reader").
+     * 
+ * + * PHYSICAL = 4; + */ + public static final int PHYSICAL_VALUE = 4; + + /** + * + * + *
+     * A TACACS family protocol for networked systems authentication
+     * (e.g. TACACS, TACACS+).
+     * 
+ * + * TACACS = 5; + */ + public static final int TACACS_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AuthType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AuthType forNumber(int value) { + switch (value) { + case 0: + return AUTHTYPE_UNSPECIFIED; + case 1: + return MACHINE; + case 2: + return SSO; + case 3: + return VPN; + case 4: + return PHYSICAL; + case 5: + return TACACS; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AuthType findValueByNumber(int number) { + return AuthType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Authentication.getDescriptor().getEnumTypes().get(0); + } + + private static final AuthType[] VALUES = values(); + + public static AuthType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AuthType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Authentication.AuthType) + } + + /** + * + * + *
+   * Mechanism(s) used to authenticate.
+   * 
+ * + * Protobuf enum {@code google.backstory.Authentication.Mechanism} + */ + public enum Mechanism implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default mechanism.
+     * 
+ * + * MECHANISM_UNSPECIFIED = 0; + */ + MECHANISM_UNSPECIFIED(0), + /** + * + * + *
+     * Username + password authentication.
+     * 
+ * + * USERNAME_PASSWORD = 1; + */ + USERNAME_PASSWORD(1), + /** + * + * + *
+     * OTP authentication.
+     * 
+ * + * OTP = 2; + */ + OTP(2), + /** + * + * + *
+     * Hardware key authentication.
+     * 
+ * + * HARDWARE_KEY = 3; + */ + HARDWARE_KEY(3), + /** + * + * + *
+     * Local authentication.
+     * 
+ * + * LOCAL = 4; + */ + LOCAL(4), + /** + * + * + *
+     * Remote authentication.
+     * 
+ * + * REMOTE = 5; + */ + REMOTE(5), + /** + * + * + *
+     * RDP, Terminal Services, or VNC.
+     * 
+ * + * REMOTE_INTERACTIVE = 6; + */ + REMOTE_INTERACTIVE(6), + /** + * + * + *
+     * Some other mechanism that is not defined here.
+     * 
+ * + * MECHANISM_OTHER = 7; + */ + MECHANISM_OTHER(7), + /** + * + * + *
+     * Badge reader authentication
+     * 
+ * + * BADGE_READER = 8; + */ + BADGE_READER(8), + /** + * + * + *
+     * Network authentication.
+     * 
+ * + * NETWORK = 9; + */ + NETWORK(9), + /** + * + * + *
+     * Batch authentication.
+     * 
+ * + * BATCH = 10; + */ + BATCH(10), + /** + * + * + *
+     * Service authentication
+     * 
+ * + * SERVICE = 11; + */ + SERVICE(11), + /** + * + * + *
+     * Direct human-interactive unlock authentication.
+     * 
+ * + * UNLOCK = 12; + */ + UNLOCK(12), + /** + * + * + *
+     * Network clear text authentication.
+     * 
+ * + * NETWORK_CLEAR_TEXT = 13; + */ + NETWORK_CLEAR_TEXT(13), + /** + * + * + *
+     * Authentication with new credentials.
+     * 
+ * + * NEW_CREDENTIALS = 14; + */ + NEW_CREDENTIALS(14), + /** + * + * + *
+     * Interactive authentication.
+     * 
+ * + * INTERACTIVE = 15; + */ + INTERACTIVE(15), + /** + * + * + *
+     * Interactive authentication using cached credentials.
+     * 
+ * + * CACHED_INTERACTIVE = 16; + */ + CACHED_INTERACTIVE(16), + /** + * + * + *
+     * Cached Remote Interactive authentication using cached credentials.
+     * 
+ * + * CACHED_REMOTE_INTERACTIVE = 17; + */ + CACHED_REMOTE_INTERACTIVE(17), + /** + * + * + *
+     * Cached Remote Interactive authentication using cached credentials.
+     * 
+ * + * CACHED_UNLOCK = 18; + */ + CACHED_UNLOCK(18), + /** + * + * + *
+     * Biometric device such as a fingerprint reader.
+     * 
+ * + * BIOMETRIC = 19; + */ + BIOMETRIC(19), + /** + * + * + *
+     * Wearable such as an Apple Watch.
+     * 
+ * + * WEARABLE = 20; + */ + WEARABLE(20), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Mechanism"); + } + + /** + * + * + *
+     * The default mechanism.
+     * 
+ * + * MECHANISM_UNSPECIFIED = 0; + */ + public static final int MECHANISM_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Username + password authentication.
+     * 
+ * + * USERNAME_PASSWORD = 1; + */ + public static final int USERNAME_PASSWORD_VALUE = 1; + + /** + * + * + *
+     * OTP authentication.
+     * 
+ * + * OTP = 2; + */ + public static final int OTP_VALUE = 2; + + /** + * + * + *
+     * Hardware key authentication.
+     * 
+ * + * HARDWARE_KEY = 3; + */ + public static final int HARDWARE_KEY_VALUE = 3; + + /** + * + * + *
+     * Local authentication.
+     * 
+ * + * LOCAL = 4; + */ + public static final int LOCAL_VALUE = 4; + + /** + * + * + *
+     * Remote authentication.
+     * 
+ * + * REMOTE = 5; + */ + public static final int REMOTE_VALUE = 5; + + /** + * + * + *
+     * RDP, Terminal Services, or VNC.
+     * 
+ * + * REMOTE_INTERACTIVE = 6; + */ + public static final int REMOTE_INTERACTIVE_VALUE = 6; + + /** + * + * + *
+     * Some other mechanism that is not defined here.
+     * 
+ * + * MECHANISM_OTHER = 7; + */ + public static final int MECHANISM_OTHER_VALUE = 7; + + /** + * + * + *
+     * Badge reader authentication
+     * 
+ * + * BADGE_READER = 8; + */ + public static final int BADGE_READER_VALUE = 8; + + /** + * + * + *
+     * Network authentication.
+     * 
+ * + * NETWORK = 9; + */ + public static final int NETWORK_VALUE = 9; + + /** + * + * + *
+     * Batch authentication.
+     * 
+ * + * BATCH = 10; + */ + public static final int BATCH_VALUE = 10; + + /** + * + * + *
+     * Service authentication
+     * 
+ * + * SERVICE = 11; + */ + public static final int SERVICE_VALUE = 11; + + /** + * + * + *
+     * Direct human-interactive unlock authentication.
+     * 
+ * + * UNLOCK = 12; + */ + public static final int UNLOCK_VALUE = 12; + + /** + * + * + *
+     * Network clear text authentication.
+     * 
+ * + * NETWORK_CLEAR_TEXT = 13; + */ + public static final int NETWORK_CLEAR_TEXT_VALUE = 13; + + /** + * + * + *
+     * Authentication with new credentials.
+     * 
+ * + * NEW_CREDENTIALS = 14; + */ + public static final int NEW_CREDENTIALS_VALUE = 14; + + /** + * + * + *
+     * Interactive authentication.
+     * 
+ * + * INTERACTIVE = 15; + */ + public static final int INTERACTIVE_VALUE = 15; + + /** + * + * + *
+     * Interactive authentication using cached credentials.
+     * 
+ * + * CACHED_INTERACTIVE = 16; + */ + public static final int CACHED_INTERACTIVE_VALUE = 16; + + /** + * + * + *
+     * Cached Remote Interactive authentication using cached credentials.
+     * 
+ * + * CACHED_REMOTE_INTERACTIVE = 17; + */ + public static final int CACHED_REMOTE_INTERACTIVE_VALUE = 17; + + /** + * + * + *
+     * Cached Remote Interactive authentication using cached credentials.
+     * 
+ * + * CACHED_UNLOCK = 18; + */ + public static final int CACHED_UNLOCK_VALUE = 18; + + /** + * + * + *
+     * Biometric device such as a fingerprint reader.
+     * 
+ * + * BIOMETRIC = 19; + */ + public static final int BIOMETRIC_VALUE = 19; + + /** + * + * + *
+     * Wearable such as an Apple Watch.
+     * 
+ * + * WEARABLE = 20; + */ + public static final int WEARABLE_VALUE = 20; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Mechanism valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Mechanism forNumber(int value) { + switch (value) { + case 0: + return MECHANISM_UNSPECIFIED; + case 1: + return USERNAME_PASSWORD; + case 2: + return OTP; + case 3: + return HARDWARE_KEY; + case 4: + return LOCAL; + case 5: + return REMOTE; + case 6: + return REMOTE_INTERACTIVE; + case 7: + return MECHANISM_OTHER; + case 8: + return BADGE_READER; + case 9: + return NETWORK; + case 10: + return BATCH; + case 11: + return SERVICE; + case 12: + return UNLOCK; + case 13: + return NETWORK_CLEAR_TEXT; + case 14: + return NEW_CREDENTIALS; + case 15: + return INTERACTIVE; + case 16: + return CACHED_INTERACTIVE; + case 17: + return CACHED_REMOTE_INTERACTIVE; + case 18: + return CACHED_UNLOCK; + case 19: + return BIOMETRIC; + case 20: + return WEARABLE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Mechanism findValueByNumber(int number) { + return Mechanism.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Authentication.getDescriptor().getEnumTypes().get(1); + } + + private static final Mechanism[] VALUES = values(); + + public static Mechanism valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Mechanism(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Authentication.Mechanism) + } + + /** + * + * + *
+   * Authentication status, can be used to describe the status of authentication
+   * for a user or particular credential.
+   * 
+ * + * Protobuf enum {@code google.backstory.Authentication.AuthenticationStatus} + */ + public enum AuthenticationStatus implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default authentication status.
+     * 
+ * + * UNKNOWN_AUTHENTICATION_STATUS = 0; + */ + UNKNOWN_AUTHENTICATION_STATUS(0), + /** + * + * + *
+     * The authentication method is in active state.
+     * 
+ * + * ACTIVE = 1; + */ + ACTIVE(1), + /** + * + * + *
+     * The authentication method is in suspended/disabled state.
+     * 
+ * + * SUSPENDED = 2; + */ + SUSPENDED(2), + /** + * + * + *
+     * The authentication method has no active credentials.
+     * 
+ * + * NO_ACTIVE_CREDENTIALS = 3; + */ + NO_ACTIVE_CREDENTIALS(3), + /** + * + * + *
+     * The authentication method has been deleted.
+     * 
+ * + * DELETED = 4; + */ + DELETED(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "AuthenticationStatus"); + } + + /** + * + * + *
+     * The default authentication status.
+     * 
+ * + * UNKNOWN_AUTHENTICATION_STATUS = 0; + */ + public static final int UNKNOWN_AUTHENTICATION_STATUS_VALUE = 0; + + /** + * + * + *
+     * The authentication method is in active state.
+     * 
+ * + * ACTIVE = 1; + */ + public static final int ACTIVE_VALUE = 1; + + /** + * + * + *
+     * The authentication method is in suspended/disabled state.
+     * 
+ * + * SUSPENDED = 2; + */ + public static final int SUSPENDED_VALUE = 2; + + /** + * + * + *
+     * The authentication method has no active credentials.
+     * 
+ * + * NO_ACTIVE_CREDENTIALS = 3; + */ + public static final int NO_ACTIVE_CREDENTIALS_VALUE = 3; + + /** + * + * + *
+     * The authentication method has been deleted.
+     * 
+ * + * DELETED = 4; + */ + public static final int DELETED_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AuthenticationStatus valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AuthenticationStatus forNumber(int value) { + switch (value) { + case 0: + return UNKNOWN_AUTHENTICATION_STATUS; + case 1: + return ACTIVE; + case 2: + return SUSPENDED; + case 3: + return NO_ACTIVE_CREDENTIALS; + case 4: + return DELETED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AuthenticationStatus findValueByNumber(int number) { + return AuthenticationStatus.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Authentication.getDescriptor().getEnumTypes().get(2); + } + + private static final AuthenticationStatus[] VALUES = values(); + + public static AuthenticationStatus valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AuthenticationStatus(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Authentication.AuthenticationStatus) + } + + /** + * + * + *
+   * The outcome of the authentication event.
+   * 
+ * + * Protobuf enum {@code google.backstory.Authentication.Outcome} + */ + public enum Outcome implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default outcome.
+     * 
+ * + * OUTCOME_UNSPECIFIED = 0; + */ + OUTCOME_UNSPECIFIED(0), + /** + * + * + *
+     * The authentication was successful.
+     * 
+ * + * SUCCESS = 1; + */ + SUCCESS(1), + /** + * + * + *
+     * The authentication failed.
+     * 
+ * + * FAILURE = 2; + */ + FAILURE(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Outcome"); + } + + /** + * + * + *
+     * The default outcome.
+     * 
+ * + * OUTCOME_UNSPECIFIED = 0; + */ + public static final int OUTCOME_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The authentication was successful.
+     * 
+ * + * SUCCESS = 1; + */ + public static final int SUCCESS_VALUE = 1; + + /** + * + * + *
+     * The authentication failed.
+     * 
+ * + * FAILURE = 2; + */ + public static final int FAILURE_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Outcome valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Outcome forNumber(int value) { + switch (value) { + case 0: + return OUTCOME_UNSPECIFIED; + case 1: + return SUCCESS; + case 2: + return FAILURE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Outcome findValueByNumber(int number) { + return Outcome.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Authentication.getDescriptor().getEnumTypes().get(3); + } + + private static final Outcome[] VALUES = values(); + + public static Outcome valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Outcome(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Authentication.Outcome) + } + + public static final int TYPE_FIELD_NUMBER = 1; + private int type_ = 0; + + /** + * + * + *
+   * The type of authentication.
+   * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+   * The type of authentication.
+   * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.backstory.Authentication.AuthType getType() { + com.google.backstory.Authentication.AuthType result = + com.google.backstory.Authentication.AuthType.forNumber(type_); + return result == null ? com.google.backstory.Authentication.AuthType.UNRECOGNIZED : result; + } + + public static final int MECHANISM_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.IntList mechanism_ = emptyIntList(); + + private static final com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.backstory.Authentication.Mechanism> + mechanism_converter_ = + new com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.backstory.Authentication.Mechanism>() { + public com.google.backstory.Authentication.Mechanism convert(int from) { + com.google.backstory.Authentication.Mechanism result = + com.google.backstory.Authentication.Mechanism.forNumber(from); + return result == null + ? com.google.backstory.Authentication.Mechanism.UNRECOGNIZED + : result; + } + }; + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return A list containing the mechanism. + */ + @java.lang.Override + public java.util.List getMechanismList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.backstory.Authentication.Mechanism>(mechanism_, mechanism_converter_); + } + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return The count of mechanism. + */ + @java.lang.Override + public int getMechanismCount() { + return mechanism_.size(); + } + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index of the element to return. + * @return The mechanism at the given index. + */ + @java.lang.Override + public com.google.backstory.Authentication.Mechanism getMechanism(int index) { + return mechanism_converter_.convert(mechanism_.getInt(index)); + } + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return A list containing the enum numeric values on the wire for mechanism. + */ + @java.lang.Override + public java.util.List getMechanismValueList() { + return mechanism_; + } + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of mechanism at the given index. + */ + @java.lang.Override + public int getMechanismValue(int index) { + return mechanism_.getInt(index); + } + + private int mechanismMemoizedSerializedSize; + + public static final int AUTH_DETAILS_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object authDetails_ = ""; + + /** + * + * + *
+   * The vendor defined details of the authentication.
+   * 
+ * + * string auth_details = 3; + * + * @return The authDetails. + */ + @java.lang.Override + public java.lang.String getAuthDetails() { + java.lang.Object ref = authDetails_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + authDetails_ = s; + return s; + } + } + + /** + * + * + *
+   * The vendor defined details of the authentication.
+   * 
+ * + * string auth_details = 3; + * + * @return The bytes for authDetails. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAuthDetailsBytes() { + java.lang.Object ref = authDetails_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + authDetails_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int OUTCOME_FIELD_NUMBER = 4; + private int outcome_ = 0; + + /** + * + * + *
+   * The outcome of the authentication event.
+   * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return The enum numeric value on the wire for outcome. + */ + @java.lang.Override + public int getOutcomeValue() { + return outcome_; + } + + /** + * + * + *
+   * The outcome of the authentication event.
+   * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return The outcome. + */ + @java.lang.Override + public com.google.backstory.Authentication.Outcome getOutcome() { + com.google.backstory.Authentication.Outcome result = + com.google.backstory.Authentication.Outcome.forNumber(outcome_); + return result == null ? com.google.backstory.Authentication.Outcome.UNRECOGNIZED : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getSerializedSize(); + if (type_ != com.google.backstory.Authentication.AuthType.AUTHTYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(1, type_); + } + if (getMechanismList().size() > 0) { + output.writeUInt32NoTag(18); + output.writeUInt32NoTag(mechanismMemoizedSerializedSize); + } + for (int i = 0; i < mechanism_.size(); i++) { + output.writeEnumNoTag(mechanism_.getInt(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(authDetails_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, authDetails_); + } + if (outcome_ != com.google.backstory.Authentication.Outcome.OUTCOME_UNSPECIFIED.getNumber()) { + output.writeEnum(4, outcome_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (type_ != com.google.backstory.Authentication.AuthType.AUTHTYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); + } + { + int dataSize = 0; + for (int i = 0; i < mechanism_.size(); i++) { + dataSize += + com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag(mechanism_.getInt(i)); + } + size += dataSize; + if (!getMechanismList().isEmpty()) { + size += 1; + size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); + } + mechanismMemoizedSerializedSize = dataSize; + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(authDetails_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, authDetails_); + } + if (outcome_ != com.google.backstory.Authentication.Outcome.OUTCOME_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, outcome_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Authentication)) { + return super.equals(obj); + } + com.google.backstory.Authentication other = (com.google.backstory.Authentication) obj; + + if (type_ != other.type_) return false; + if (!mechanism_.equals(other.mechanism_)) return false; + if (!getAuthDetails().equals(other.getAuthDetails())) return false; + if (outcome_ != other.outcome_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + if (getMechanismCount() > 0) { + hash = (37 * hash) + MECHANISM_FIELD_NUMBER; + hash = (53 * hash) + mechanism_.hashCode(); + } + hash = (37 * hash) + AUTH_DETAILS_FIELD_NUMBER; + hash = (53 * hash) + getAuthDetails().hashCode(); + hash = (37 * hash) + OUTCOME_FIELD_NUMBER; + hash = (53 * hash) + outcome_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Authentication parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Authentication parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Authentication parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Authentication parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Authentication parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Authentication parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Authentication parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Authentication parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Authentication parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Authentication parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Authentication parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Authentication parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Authentication prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * The Authentication extension captures details specific to authentication
+   * events.
+   * General guidelines for authentication events:
+   * * Details about the source of the authentication event (for example, client
+   * IP or hostname), should be captured in principal. The principal may be
+   * empty if we have no details about the source of the login.
+   * * Details about the target of the authentication event (for example, details
+   * about the machine that is being logged into or logged out of) should be
+   * captured in target.
+   * * Some authentication events may involve a third-party. For example, a user
+   * logs into
+   * a cloud service (for example, Chronicle) via their company's SSO (the
+   * event is logged by their SSO solution). In this case, the principal
+   * captures information about the user's device, the target captures details
+   * about the cloud service they logged into, and the intermediary captures
+   * details about the SSO solution.
+   * 
+ * + * Protobuf type {@code google.backstory.Authentication} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Authentication) + com.google.backstory.AuthenticationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Authentication_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Authentication_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Authentication.class, + com.google.backstory.Authentication.Builder.class); + } + + // Construct using com.google.backstory.Authentication.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + type_ = 0; + mechanism_ = emptyIntList(); + authDetails_ = ""; + outcome_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Authentication_descriptor; + } + + @java.lang.Override + public com.google.backstory.Authentication getDefaultInstanceForType() { + return com.google.backstory.Authentication.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Authentication build() { + com.google.backstory.Authentication result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Authentication buildPartial() { + com.google.backstory.Authentication result = new com.google.backstory.Authentication(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.Authentication result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.type_ = type_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + mechanism_.makeImmutable(); + result.mechanism_ = mechanism_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.authDetails_ = authDetails_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.outcome_ = outcome_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Authentication) { + return mergeFrom((com.google.backstory.Authentication) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Authentication other) { + if (other == com.google.backstory.Authentication.getDefaultInstance()) return this; + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + if (!other.mechanism_.isEmpty()) { + if (mechanism_.isEmpty()) { + mechanism_ = other.mechanism_; + mechanism_.makeImmutable(); + bitField0_ |= 0x00000002; + } else { + ensureMechanismIsMutable(); + mechanism_.addAll(other.mechanism_); + } + onChanged(); + } + if (!other.getAuthDetails().isEmpty()) { + authDetails_ = other.authDetails_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.outcome_ != 0) { + setOutcomeValue(other.getOutcomeValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + type_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 16: + { + int tmpRaw = input.readEnum(); + ensureMechanismIsMutable(); + mechanism_.addInt(tmpRaw); + break; + } // case 16 + case 18: + { + int length = input.readRawVarint32(); + int limit = input.pushLimit(length); + ensureMechanismIsMutable(); + while (input.getBytesUntilLimit() > 0) { + mechanism_.addInt(input.readEnum()); + } + input.popLimit(limit); + break; + } // case 18 + case 26: + { + authDetails_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + outcome_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int type_ = 0; + + /** + * + * + *
+     * The type of authentication.
+     * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+     * The type of authentication.
+     * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @param value The enum numeric value on the wire for type to set. + * @return This builder for chaining. + */ + public Builder setTypeValue(int value) { + type_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of authentication.
+     * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.backstory.Authentication.AuthType getType() { + com.google.backstory.Authentication.AuthType result = + com.google.backstory.Authentication.AuthType.forNumber(type_); + return result == null ? com.google.backstory.Authentication.AuthType.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The type of authentication.
+     * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.backstory.Authentication.AuthType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + type_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The type of authentication.
+     * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return This builder for chaining. + */ + public Builder clearType() { + bitField0_ = (bitField0_ & ~0x00000001); + type_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Internal.IntList mechanism_ = emptyIntList(); + + private void ensureMechanismIsMutable() { + if (!mechanism_.isModifiable()) { + mechanism_ = makeMutableCopy(mechanism_); + } + bitField0_ |= 0x00000002; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return A list containing the mechanism. + */ + public java.util.List getMechanismList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.backstory.Authentication.Mechanism>(mechanism_, mechanism_converter_); + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return The count of mechanism. + */ + public int getMechanismCount() { + return mechanism_.size(); + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index of the element to return. + * @return The mechanism at the given index. + */ + public com.google.backstory.Authentication.Mechanism getMechanism(int index) { + return mechanism_converter_.convert(mechanism_.getInt(index)); + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index to set the value at. + * @param value The mechanism to set. + * @return This builder for chaining. + */ + public Builder setMechanism(int index, com.google.backstory.Authentication.Mechanism value) { + if (value == null) { + throw new NullPointerException(); + } + ensureMechanismIsMutable(); + mechanism_.setInt(index, value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param value The mechanism to add. + * @return This builder for chaining. + */ + public Builder addMechanism(com.google.backstory.Authentication.Mechanism value) { + if (value == null) { + throw new NullPointerException(); + } + ensureMechanismIsMutable(); + mechanism_.addInt(value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param values The mechanism to add. + * @return This builder for chaining. + */ + public Builder addAllMechanism( + java.lang.Iterable values) { + ensureMechanismIsMutable(); + for (com.google.backstory.Authentication.Mechanism value : values) { + mechanism_.addInt(value.getNumber()); + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return This builder for chaining. + */ + public Builder clearMechanism() { + mechanism_ = emptyIntList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return A list containing the enum numeric values on the wire for mechanism. + */ + public java.util.List getMechanismValueList() { + mechanism_.makeImmutable(); + return mechanism_; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of mechanism at the given index. + */ + public int getMechanismValue(int index) { + return mechanism_.getInt(index); + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index to set the value at. + * @param value The enum numeric value on the wire for mechanism to set. + * @return This builder for chaining. + */ + public Builder setMechanismValue(int index, int value) { + ensureMechanismIsMutable(); + mechanism_.setInt(index, value); + onChanged(); + return this; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param value The enum numeric value on the wire for mechanism to add. + * @return This builder for chaining. + */ + public Builder addMechanismValue(int value) { + ensureMechanismIsMutable(); + mechanism_.addInt(value); + onChanged(); + return this; + } + + /** + * + * + *
+     * The authentication mechanism.
+     * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param values The enum numeric values on the wire for mechanism to add. + * @return This builder for chaining. + */ + public Builder addAllMechanismValue(java.lang.Iterable values) { + ensureMechanismIsMutable(); + for (int value : values) { + mechanism_.addInt(value); + } + onChanged(); + return this; + } + + private java.lang.Object authDetails_ = ""; + + /** + * + * + *
+     * The vendor defined details of the authentication.
+     * 
+ * + * string auth_details = 3; + * + * @return The authDetails. + */ + public java.lang.String getAuthDetails() { + java.lang.Object ref = authDetails_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + authDetails_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The vendor defined details of the authentication.
+     * 
+ * + * string auth_details = 3; + * + * @return The bytes for authDetails. + */ + public com.google.protobuf.ByteString getAuthDetailsBytes() { + java.lang.Object ref = authDetails_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + authDetails_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The vendor defined details of the authentication.
+     * 
+ * + * string auth_details = 3; + * + * @param value The authDetails to set. + * @return This builder for chaining. + */ + public Builder setAuthDetails(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + authDetails_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The vendor defined details of the authentication.
+     * 
+ * + * string auth_details = 3; + * + * @return This builder for chaining. + */ + public Builder clearAuthDetails() { + authDetails_ = getDefaultInstance().getAuthDetails(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * The vendor defined details of the authentication.
+     * 
+ * + * string auth_details = 3; + * + * @param value The bytes for authDetails to set. + * @return This builder for chaining. + */ + public Builder setAuthDetailsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + authDetails_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int outcome_ = 0; + + /** + * + * + *
+     * The outcome of the authentication event.
+     * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return The enum numeric value on the wire for outcome. + */ + @java.lang.Override + public int getOutcomeValue() { + return outcome_; + } + + /** + * + * + *
+     * The outcome of the authentication event.
+     * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @param value The enum numeric value on the wire for outcome to set. + * @return This builder for chaining. + */ + public Builder setOutcomeValue(int value) { + outcome_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * The outcome of the authentication event.
+     * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return The outcome. + */ + @java.lang.Override + public com.google.backstory.Authentication.Outcome getOutcome() { + com.google.backstory.Authentication.Outcome result = + com.google.backstory.Authentication.Outcome.forNumber(outcome_); + return result == null ? com.google.backstory.Authentication.Outcome.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The outcome of the authentication event.
+     * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @param value The outcome to set. + * @return This builder for chaining. + */ + public Builder setOutcome(com.google.backstory.Authentication.Outcome value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + outcome_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The outcome of the authentication event.
+     * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return This builder for chaining. + */ + public Builder clearOutcome() { + bitField0_ = (bitField0_ & ~0x00000008); + outcome_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Authentication) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Authentication) + private static final com.google.backstory.Authentication DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Authentication(); + } + + public static com.google.backstory.Authentication getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Authentication parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Authentication getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java new file mode 100644 index 000000000000..320be61e911a --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java @@ -0,0 +1,158 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface AuthenticationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Authentication) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The type of authentication.
+   * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + + /** + * + * + *
+   * The type of authentication.
+   * 
+ * + * .google.backstory.Authentication.AuthType type = 1; + * + * @return The type. + */ + com.google.backstory.Authentication.AuthType getType(); + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return A list containing the mechanism. + */ + java.util.List getMechanismList(); + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return The count of mechanism. + */ + int getMechanismCount(); + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index of the element to return. + * @return The mechanism at the given index. + */ + com.google.backstory.Authentication.Mechanism getMechanism(int index); + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @return A list containing the enum numeric values on the wire for mechanism. + */ + java.util.List getMechanismValueList(); + + /** + * + * + *
+   * The authentication mechanism.
+   * 
+ * + * repeated .google.backstory.Authentication.Mechanism mechanism = 2; + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of mechanism at the given index. + */ + int getMechanismValue(int index); + + /** + * + * + *
+   * The vendor defined details of the authentication.
+   * 
+ * + * string auth_details = 3; + * + * @return The authDetails. + */ + java.lang.String getAuthDetails(); + + /** + * + * + *
+   * The vendor defined details of the authentication.
+   * 
+ * + * string auth_details = 3; + * + * @return The bytes for authDetails. + */ + com.google.protobuf.ByteString getAuthDetailsBytes(); + + /** + * + * + *
+   * The outcome of the authentication event.
+   * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return The enum numeric value on the wire for outcome. + */ + int getOutcomeValue(); + + /** + * + * + *
+   * The outcome of the authentication event.
+   * 
+ * + * .google.backstory.Authentication.Outcome outcome = 4; + * + * @return The outcome. + */ + com.google.backstory.Authentication.Outcome getOutcome(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/BoolSequence.java b/java-backstory/src/main/java/com/google/backstory/BoolSequence.java new file mode 100644 index 000000000000..f95d309d5b30 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/BoolSequence.java @@ -0,0 +1,641 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * BoolSequence represents a sequence of bools.
+ * 
+ * + * Protobuf type {@code google.backstory.BoolSequence} + */ +@com.google.protobuf.Generated +public final class BoolSequence extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.BoolSequence) + BoolSequenceOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "BoolSequence"); + } + + // Use BoolSequence.newBuilder() to construct. + private BoolSequence(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private BoolSequence() { + boolVals_ = emptyBooleanList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_BoolSequence_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_BoolSequence_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.BoolSequence.class, + com.google.backstory.BoolSequence.Builder.class); + } + + public static final int BOOL_VALS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.BooleanList boolVals_ = emptyBooleanList(); + + /** + * + * + *
+   * bool sequence.
+   * 
+ * + * repeated bool bool_vals = 1; + * + * @return A list containing the boolVals. + */ + @java.lang.Override + public java.util.List getBoolValsList() { + return boolVals_; + } + + /** + * + * + *
+   * bool sequence.
+   * 
+ * + * repeated bool bool_vals = 1; + * + * @return The count of boolVals. + */ + public int getBoolValsCount() { + return boolVals_.size(); + } + + /** + * + * + *
+   * bool sequence.
+   * 
+ * + * repeated bool bool_vals = 1; + * + * @param index The index of the element to return. + * @return The boolVals at the given index. + */ + public boolean getBoolVals(int index) { + return boolVals_.getBoolean(index); + } + + private int boolValsMemoizedSerializedSize = -1; + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getSerializedSize(); + if (getBoolValsList().size() > 0) { + output.writeUInt32NoTag(10); + output.writeUInt32NoTag(boolValsMemoizedSerializedSize); + } + for (int i = 0; i < boolVals_.size(); i++) { + output.writeBoolNoTag(boolVals_.getBoolean(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + dataSize = 1 * getBoolValsList().size(); + size += dataSize; + if (!getBoolValsList().isEmpty()) { + size += 1; + size += com.google.protobuf.CodedOutputStream.computeInt32SizeNoTag(dataSize); + } + boolValsMemoizedSerializedSize = dataSize; + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.BoolSequence)) { + return super.equals(obj); + } + com.google.backstory.BoolSequence other = (com.google.backstory.BoolSequence) obj; + + if (!getBoolValsList().equals(other.getBoolValsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getBoolValsCount() > 0) { + hash = (37 * hash) + BOOL_VALS_FIELD_NUMBER; + hash = (53 * hash) + getBoolValsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.BoolSequence parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.BoolSequence parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.BoolSequence parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.BoolSequence parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.BoolSequence parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.BoolSequence parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.BoolSequence parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.BoolSequence parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.BoolSequence parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.BoolSequence parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.BoolSequence parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.BoolSequence parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.BoolSequence prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * BoolSequence represents a sequence of bools.
+   * 
+ * + * Protobuf type {@code google.backstory.BoolSequence} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.BoolSequence) + com.google.backstory.BoolSequenceOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_BoolSequence_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_BoolSequence_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.BoolSequence.class, + com.google.backstory.BoolSequence.Builder.class); + } + + // Construct using com.google.backstory.BoolSequence.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + boolVals_ = emptyBooleanList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_BoolSequence_descriptor; + } + + @java.lang.Override + public com.google.backstory.BoolSequence getDefaultInstanceForType() { + return com.google.backstory.BoolSequence.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.BoolSequence build() { + com.google.backstory.BoolSequence result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.BoolSequence buildPartial() { + com.google.backstory.BoolSequence result = new com.google.backstory.BoolSequence(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.BoolSequence result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + boolVals_.makeImmutable(); + result.boolVals_ = boolVals_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.BoolSequence) { + return mergeFrom((com.google.backstory.BoolSequence) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.BoolSequence other) { + if (other == com.google.backstory.BoolSequence.getDefaultInstance()) return this; + if (!other.boolVals_.isEmpty()) { + if (boolVals_.isEmpty()) { + boolVals_ = other.boolVals_; + boolVals_.makeImmutable(); + bitField0_ |= 0x00000001; + } else { + ensureBoolValsIsMutable(); + boolVals_.addAll(other.boolVals_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + boolean v = input.readBool(); + ensureBoolValsIsMutable(); + boolVals_.addBoolean(v); + break; + } // case 8 + case 10: + { + int length = input.readRawVarint32(); + int limit = input.pushLimit(length); + int alloc = length > 4096 ? 4096 : length; + ensureBoolValsIsMutable(alloc / 1); + while (input.getBytesUntilLimit() > 0) { + boolVals_.addBoolean(input.readBool()); + } + input.popLimit(limit); + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.Internal.BooleanList boolVals_ = emptyBooleanList(); + + private void ensureBoolValsIsMutable() { + if (!boolVals_.isModifiable()) { + boolVals_ = makeMutableCopy(boolVals_); + } + bitField0_ |= 0x00000001; + } + + private void ensureBoolValsIsMutable(int capacity) { + if (!boolVals_.isModifiable()) { + boolVals_ = makeMutableCopy(boolVals_, capacity); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @return A list containing the boolVals. + */ + public java.util.List getBoolValsList() { + boolVals_.makeImmutable(); + return boolVals_; + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @return The count of boolVals. + */ + public int getBoolValsCount() { + return boolVals_.size(); + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @param index The index of the element to return. + * @return The boolVals at the given index. + */ + public boolean getBoolVals(int index) { + return boolVals_.getBoolean(index); + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @param index The index to set the value at. + * @param value The boolVals to set. + * @return This builder for chaining. + */ + public Builder setBoolVals(int index, boolean value) { + + ensureBoolValsIsMutable(); + boolVals_.setBoolean(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @param value The boolVals to add. + * @return This builder for chaining. + */ + public Builder addBoolVals(boolean value) { + + ensureBoolValsIsMutable(); + boolVals_.addBoolean(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @param values The boolVals to add. + * @return This builder for chaining. + */ + public Builder addAllBoolVals(java.lang.Iterable values) { + ensureBoolValsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, boolVals_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * bool sequence.
+     * 
+ * + * repeated bool bool_vals = 1; + * + * @return This builder for chaining. + */ + public Builder clearBoolVals() { + boolVals_ = emptyBooleanList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.BoolSequence) + } + + // @@protoc_insertion_point(class_scope:google.backstory.BoolSequence) + private static final com.google.backstory.BoolSequence DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.BoolSequence(); + } + + public static com.google.backstory.BoolSequence getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BoolSequence parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.BoolSequence getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java new file mode 100644 index 000000000000..1257b3758518 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java @@ -0,0 +1,53 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface BoolSequenceOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.BoolSequence) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * bool sequence.
+   * 
+ * + * repeated bool bool_vals = 1; + * + * @return A list containing the boolVals. + */ + java.util.List getBoolValsList(); + + /** + * + * + *
+   * bool sequence.
+   * 
+ * + * repeated bool bool_vals = 1; + * + * @return The count of boolVals. + */ + int getBoolValsCount(); + + /** + * + * + *
+   * bool sequence.
+   * 
+ * + * repeated bool bool_vals = 1; + * + * @param index The index of the element to return. + * @return The boolVals at the given index. + */ + boolean getBoolVals(int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Browser.java b/java-backstory/src/main/java/com/google/backstory/Browser.java new file mode 100644 index 000000000000..cd40942bcdb0 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Browser.java @@ -0,0 +1,6970 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Information about an entry in the web browser's local history database.
+ * 
+ * + * Protobuf type {@code google.backstory.Browser} + */ +@com.google.protobuf.Generated +public final class Browser extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Browser) + BrowserOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Browser"); + } + + // Use Browser.newBuilder() to construct. + private Browser(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Browser() { + browserType_ = 0; + browserVersion_ = ""; + profile_ = ""; + visitType_ = 0; + requestOriginUri_ = ""; + visitCountCriteria_ = ""; + indexedContent_ = ""; + cookies_ = java.util.Collections.emptyList(); + visitSource_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Browser.class, com.google.backstory.Browser.Builder.class); + } + + /** + * + * + *
+   * The name of the browser.
+   * 
+ * + * Protobuf enum {@code google.backstory.Browser.BrowserType} + */ + public enum BrowserType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value.
+     * 
+ * + * BROWSER_TYPE_UNSPECIFIED = 0; + */ + BROWSER_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * Chrome.
+     * 
+ * + * CHROME = 1; + */ + CHROME(1), + /** + * + * + *
+     * Firefox.
+     * 
+ * + * FIREFOX = 2; + */ + FIREFOX(2), + /** + * + * + *
+     * Safari.
+     * 
+ * + * SAFARI = 3; + */ + SAFARI(3), + /** + * + * + *
+     * Internet Explorer.
+     * 
+ * + * INTERNET_EXPLORER = 4; + */ + INTERNET_EXPLORER(4), + /** + * + * + *
+     * Edge.
+     * 
+ * + * EDGE = 5; + */ + EDGE(5), + /** + * + * + *
+     * Opera.
+     * 
+ * + * OPERA = 6; + */ + OPERA(6), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "BrowserType"); + } + + /** + * + * + *
+     * Default value.
+     * 
+ * + * BROWSER_TYPE_UNSPECIFIED = 0; + */ + public static final int BROWSER_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Chrome.
+     * 
+ * + * CHROME = 1; + */ + public static final int CHROME_VALUE = 1; + + /** + * + * + *
+     * Firefox.
+     * 
+ * + * FIREFOX = 2; + */ + public static final int FIREFOX_VALUE = 2; + + /** + * + * + *
+     * Safari.
+     * 
+ * + * SAFARI = 3; + */ + public static final int SAFARI_VALUE = 3; + + /** + * + * + *
+     * Internet Explorer.
+     * 
+ * + * INTERNET_EXPLORER = 4; + */ + public static final int INTERNET_EXPLORER_VALUE = 4; + + /** + * + * + *
+     * Edge.
+     * 
+ * + * EDGE = 5; + */ + public static final int EDGE_VALUE = 5; + + /** + * + * + *
+     * Opera.
+     * 
+ * + * OPERA = 6; + */ + public static final int OPERA_VALUE = 6; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static BrowserType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static BrowserType forNumber(int value) { + switch (value) { + case 0: + return BROWSER_TYPE_UNSPECIFIED; + case 1: + return CHROME; + case 2: + return FIREFOX; + case 3: + return SAFARI; + case 4: + return INTERNET_EXPLORER; + case 5: + return EDGE; + case 6: + return OPERA; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public BrowserType findValueByNumber(int number) { + return BrowserType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Browser.getDescriptor().getEnumTypes().get(0); + } + + private static final BrowserType[] VALUES = values(); + + public static BrowserType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private BrowserType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Browser.BrowserType) + } + + /** + * + * + *
+   * The type of visit to a URL.
+   * 
+ * + * Protobuf enum {@code google.backstory.Browser.UrlVisitType} + */ + public enum UrlVisitType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value.
+     * 
+ * + * URL_VISIT_TYPE_UNSPECIFIED = 0; + */ + URL_VISIT_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * The user clicked a link.
+     * 
+ * + * LINK = 1; + */ + LINK(1), + /** + * + * + *
+     * The user typed a URL.
+     * 
+ * + * TYPED = 2; + */ + TYPED(2), + /** + * + * + *
+     * The user bookmarked the URL.
+     * 
+ * + * AUTO_BOOKMARK = 3; + */ + AUTO_BOOKMARK(3), + /** + * + * + *
+     * Loaded in a nested subframe by the parent frame.
+     * 
+ * + * AUTO_SUBFRAME = 4; + */ + AUTO_SUBFRAME(4), + /** + * + * + *
+     * Loaded in a nested subframe by the user.
+     * 
+ * + * MANUAL_SUBFRAME = 5; + */ + MANUAL_SUBFRAME(5), + /** + * + * + *
+     * The user clicked on auto generated link in browser address bar.
+     * 
+ * + * GENERATED = 6; + */ + GENERATED(6), + /** + * + * + *
+     * The page was loaded through command line or is the starting page.
+     * 
+ * + * AUTO_TOPLEVEL = 7; + */ + AUTO_TOPLEVEL(7), + /** + * + * + *
+     * The user submitted a form.
+     * 
+ * + * FORM_SUBMIT = 8; + */ + FORM_SUBMIT(8), + /** + * + * + *
+     * The user reloaded the page.
+     * 
+ * + * RELOAD = 9; + */ + RELOAD(9), + /** + * + * + *
+     * The Url was generated by a keyword search configured by user.
+     * 
+ * + * KEYWORD = 10; + */ + KEYWORD(10), + /** + * + * + *
+     * Corresponds to a visit generated by a keyword search.
+     * 
+ * + * KEYWORD_GENERATED = 11; + */ + KEYWORD_GENERATED(11), + /** + * + * + *
+     * The user was redirected to the URL.
+     * 
+ * + * REDIRECT = 12; + */ + REDIRECT(12), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "UrlVisitType"); + } + + /** + * + * + *
+     * Default value.
+     * 
+ * + * URL_VISIT_TYPE_UNSPECIFIED = 0; + */ + public static final int URL_VISIT_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The user clicked a link.
+     * 
+ * + * LINK = 1; + */ + public static final int LINK_VALUE = 1; + + /** + * + * + *
+     * The user typed a URL.
+     * 
+ * + * TYPED = 2; + */ + public static final int TYPED_VALUE = 2; + + /** + * + * + *
+     * The user bookmarked the URL.
+     * 
+ * + * AUTO_BOOKMARK = 3; + */ + public static final int AUTO_BOOKMARK_VALUE = 3; + + /** + * + * + *
+     * Loaded in a nested subframe by the parent frame.
+     * 
+ * + * AUTO_SUBFRAME = 4; + */ + public static final int AUTO_SUBFRAME_VALUE = 4; + + /** + * + * + *
+     * Loaded in a nested subframe by the user.
+     * 
+ * + * MANUAL_SUBFRAME = 5; + */ + public static final int MANUAL_SUBFRAME_VALUE = 5; + + /** + * + * + *
+     * The user clicked on auto generated link in browser address bar.
+     * 
+ * + * GENERATED = 6; + */ + public static final int GENERATED_VALUE = 6; + + /** + * + * + *
+     * The page was loaded through command line or is the starting page.
+     * 
+ * + * AUTO_TOPLEVEL = 7; + */ + public static final int AUTO_TOPLEVEL_VALUE = 7; + + /** + * + * + *
+     * The user submitted a form.
+     * 
+ * + * FORM_SUBMIT = 8; + */ + public static final int FORM_SUBMIT_VALUE = 8; + + /** + * + * + *
+     * The user reloaded the page.
+     * 
+ * + * RELOAD = 9; + */ + public static final int RELOAD_VALUE = 9; + + /** + * + * + *
+     * The Url was generated by a keyword search configured by user.
+     * 
+ * + * KEYWORD = 10; + */ + public static final int KEYWORD_VALUE = 10; + + /** + * + * + *
+     * Corresponds to a visit generated by a keyword search.
+     * 
+ * + * KEYWORD_GENERATED = 11; + */ + public static final int KEYWORD_GENERATED_VALUE = 11; + + /** + * + * + *
+     * The user was redirected to the URL.
+     * 
+ * + * REDIRECT = 12; + */ + public static final int REDIRECT_VALUE = 12; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static UrlVisitType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static UrlVisitType forNumber(int value) { + switch (value) { + case 0: + return URL_VISIT_TYPE_UNSPECIFIED; + case 1: + return LINK; + case 2: + return TYPED; + case 3: + return AUTO_BOOKMARK; + case 4: + return AUTO_SUBFRAME; + case 5: + return MANUAL_SUBFRAME; + case 6: + return GENERATED; + case 7: + return AUTO_TOPLEVEL; + case 8: + return FORM_SUBMIT; + case 9: + return RELOAD; + case 10: + return KEYWORD; + case 11: + return KEYWORD_GENERATED; + case 12: + return REDIRECT; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public UrlVisitType findValueByNumber(int number) { + return UrlVisitType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Browser.getDescriptor().getEnumTypes().get(1); + } + + private static final UrlVisitType[] VALUES = values(); + + public static UrlVisitType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private UrlVisitType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Browser.UrlVisitType) + } + + /** + * + * + *
+   * The source of the visit.
+   * 
+ * + * Protobuf enum {@code google.backstory.Browser.VisitSource} + */ + public enum VisitSource implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value.
+     * 
+ * + * VISIT_SOURCE_UNSPECIFIED = 0; + */ + VISIT_SOURCE_UNSPECIFIED(0), + /** + * + * + *
+     * The visit was synced from another device.
+     * 
+ * + * SYNCED = 1; + */ + SYNCED(1), + /** + * + * + *
+     * The visit was from a browser.
+     * 
+ * + * BROWSER = 2; + */ + BROWSER(2), + /** + * + * + *
+     * The visit was from an extension.
+     * 
+ * + * EXTENSION = 3; + */ + EXTENSION(3), + /** + * + * + *
+     * The visit was imported from another browser application.
+     * 
+ * + * IMPORTED = 4; + */ + IMPORTED(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "VisitSource"); + } + + /** + * + * + *
+     * Default value.
+     * 
+ * + * VISIT_SOURCE_UNSPECIFIED = 0; + */ + public static final int VISIT_SOURCE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The visit was synced from another device.
+     * 
+ * + * SYNCED = 1; + */ + public static final int SYNCED_VALUE = 1; + + /** + * + * + *
+     * The visit was from a browser.
+     * 
+ * + * BROWSER = 2; + */ + public static final int BROWSER_VALUE = 2; + + /** + * + * + *
+     * The visit was from an extension.
+     * 
+ * + * EXTENSION = 3; + */ + public static final int EXTENSION_VALUE = 3; + + /** + * + * + *
+     * The visit was imported from another browser application.
+     * 
+ * + * IMPORTED = 4; + */ + public static final int IMPORTED_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static VisitSource valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static VisitSource forNumber(int value) { + switch (value) { + case 0: + return VISIT_SOURCE_UNSPECIFIED; + case 1: + return SYNCED; + case 2: + return BROWSER; + case 3: + return EXTENSION; + case 4: + return IMPORTED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public VisitSource findValueByNumber(int number) { + return VisitSource.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Browser.getDescriptor().getEnumTypes().get(2); + } + + private static final VisitSource[] VALUES = values(); + + public static VisitSource valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private VisitSource(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Browser.VisitSource) + } + + public interface CookieOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Browser.Cookie) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The unique name identifying the cookie.
+     * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+     * The unique name identifying the cookie.
+     * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+     * The data stored within the cookie.
+     * 
+ * + * string value = 2; + * + * @return The value. + */ + java.lang.String getValue(); + + /** + * + * + *
+     * The data stored within the cookie.
+     * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); + + /** + * + * + *
+     * The domain for which the cookie is valid.
+     * 
+ * + * string domain = 3; + * + * @return The domain. + */ + java.lang.String getDomain(); + + /** + * + * + *
+     * The domain for which the cookie is valid.
+     * 
+ * + * string domain = 3; + * + * @return The bytes for domain. + */ + com.google.protobuf.ByteString getDomainBytes(); + + /** + * + * + *
+     * The URL path for which the cookie is valid.
+     * 
+ * + * string path = 4; + * + * @return The path. + */ + java.lang.String getPath(); + + /** + * + * + *
+     * The URL path for which the cookie is valid.
+     * 
+ * + * string path = 4; + * + * @return The bytes for path. + */ + com.google.protobuf.ByteString getPathBytes(); + + /** + * + * + *
+     * The date and time when the cookie will expire.
+     * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + * + * @return Whether the expirationTime field is set. + */ + boolean hasExpirationTime(); + + /** + * + * + *
+     * The date and time when the cookie will expire.
+     * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + * + * @return The expirationTime. + */ + com.google.protobuf.Timestamp getExpirationTime(); + + /** + * + * + *
+     * The date and time when the cookie will expire.
+     * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder(); + + /** + * + * + *
+     * Indicates if the cookie is inaccessible via client-side scripts (e.g.,
+     * JavaScript).
+     * 
+ * + * bool http_only = 6; + * + * @return The httpOnly. + */ + boolean getHttpOnly(); + + /** + * + * + *
+     * Indicates if the cookie should only be sent over secure HTTPS
+     * connections.
+     * 
+ * + * bool secure = 7; + * + * @return The secure. + */ + boolean getSecure(); + + /** + * + * + *
+     * The maximum age of the cookie in seconds.
+     * 
+ * + * int64 max_age = 8; + * + * @return The maxAge. + */ + long getMaxAge(); + + /** + * + * + *
+     * Affects cross-site request behavior.
+     * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return The enum numeric value on the wire for sameSite. + */ + int getSameSiteValue(); + + /** + * + * + *
+     * Affects cross-site request behavior.
+     * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return The sameSite. + */ + com.google.backstory.Browser.Cookie.CookieSameSite getSameSite(); + + /** + * + * + *
+     * Indicates if the cookie is persistent.
+     * 
+ * + * bool session = 10; + * + * @return The session. + */ + boolean getSession(); + + /** + * + * + *
+     * Shows if the cookies is stored using partitioned storage.
+     * 
+ * + * bool partitioned = 11; + * + * @return The partitioned. + */ + boolean getPartitioned(); + } + + /** + * + * + *
+   * Browser cookie.
+   * 
+ * + * Protobuf type {@code google.backstory.Browser.Cookie} + */ + public static final class Cookie extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Browser.Cookie) + CookieOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Cookie"); + } + + // Use Cookie.newBuilder() to construct. + private Cookie(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Cookie() { + name_ = ""; + value_ = ""; + domain_ = ""; + path_ = ""; + sameSite_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_Cookie_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Browser_Cookie_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Browser.Cookie.class, + com.google.backstory.Browser.Cookie.Builder.class); + } + + /** + * + * + *
+     * The SameSite attribute of a cookie.
+     * 
+ * + * Protobuf enum {@code google.backstory.Browser.Cookie.CookieSameSite} + */ + public enum CookieSameSite implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Default value.
+       * 
+ * + * COOKIE_SAME_SITE_UNSPECIFIED = 0; + */ + COOKIE_SAME_SITE_UNSPECIFIED(0), + /** + * + * + *
+       * Corresponds to SameSite=Strict.
+       * 
+ * + * STRICT = 1; + */ + STRICT(1), + /** + * + * + *
+       * Corresponds to SameSite=Lax.
+       * 
+ * + * LAX = 2; + */ + LAX(2), + /** + * + * + *
+       * Corresponds to SameSite=None.
+       * 
+ * + * NONE = 3; + */ + NONE(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "CookieSameSite"); + } + + /** + * + * + *
+       * Default value.
+       * 
+ * + * COOKIE_SAME_SITE_UNSPECIFIED = 0; + */ + public static final int COOKIE_SAME_SITE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+       * Corresponds to SameSite=Strict.
+       * 
+ * + * STRICT = 1; + */ + public static final int STRICT_VALUE = 1; + + /** + * + * + *
+       * Corresponds to SameSite=Lax.
+       * 
+ * + * LAX = 2; + */ + public static final int LAX_VALUE = 2; + + /** + * + * + *
+       * Corresponds to SameSite=None.
+       * 
+ * + * NONE = 3; + */ + public static final int NONE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static CookieSameSite valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static CookieSameSite forNumber(int value) { + switch (value) { + case 0: + return COOKIE_SAME_SITE_UNSPECIFIED; + case 1: + return STRICT; + case 2: + return LAX; + case 3: + return NONE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public CookieSameSite findValueByNumber(int number) { + return CookieSameSite.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Browser.Cookie.getDescriptor().getEnumTypes().get(0); + } + + private static final CookieSameSite[] VALUES = values(); + + public static CookieSameSite valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private CookieSameSite(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Browser.Cookie.CookieSameSite) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+     * The unique name identifying the cookie.
+     * 
+ * + * string name = 1; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+     * The unique name identifying the cookie.
+     * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALUE_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object value_ = ""; + + /** + * + * + *
+     * The data stored within the cookie.
+     * 
+ * + * string value = 2; + * + * @return The value. + */ + @java.lang.Override + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } + } + + /** + * + * + *
+     * The data stored within the cookie.
+     * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + @java.lang.Override + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DOMAIN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object domain_ = ""; + + /** + * + * + *
+     * The domain for which the cookie is valid.
+     * 
+ * + * string domain = 3; + * + * @return The domain. + */ + @java.lang.Override + public java.lang.String getDomain() { + java.lang.Object ref = domain_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + domain_ = s; + return s; + } + } + + /** + * + * + *
+     * The domain for which the cookie is valid.
+     * 
+ * + * string domain = 3; + * + * @return The bytes for domain. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDomainBytes() { + java.lang.Object ref = domain_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + domain_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PATH_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object path_ = ""; + + /** + * + * + *
+     * The URL path for which the cookie is valid.
+     * 
+ * + * string path = 4; + * + * @return The path. + */ + @java.lang.Override + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } + } + + /** + * + * + *
+     * The URL path for which the cookie is valid.
+     * 
+ * + * string path = 4; + * + * @return The bytes for path. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int EXPIRATION_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp expirationTime_; + + /** + * + * + *
+     * The date and time when the cookie will expire.
+     * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + * + * @return Whether the expirationTime field is set. + */ + @java.lang.Override + public boolean hasExpirationTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The date and time when the cookie will expire.
+     * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + * + * @return The expirationTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getExpirationTime() { + return expirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expirationTime_; + } + + /** + * + * + *
+     * The date and time when the cookie will expire.
+     * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder() { + return expirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expirationTime_; + } + + public static final int HTTP_ONLY_FIELD_NUMBER = 6; + private boolean httpOnly_ = false; + + /** + * + * + *
+     * Indicates if the cookie is inaccessible via client-side scripts (e.g.,
+     * JavaScript).
+     * 
+ * + * bool http_only = 6; + * + * @return The httpOnly. + */ + @java.lang.Override + public boolean getHttpOnly() { + return httpOnly_; + } + + public static final int SECURE_FIELD_NUMBER = 7; + private boolean secure_ = false; + + /** + * + * + *
+     * Indicates if the cookie should only be sent over secure HTTPS
+     * connections.
+     * 
+ * + * bool secure = 7; + * + * @return The secure. + */ + @java.lang.Override + public boolean getSecure() { + return secure_; + } + + public static final int MAX_AGE_FIELD_NUMBER = 8; + private long maxAge_ = 0L; + + /** + * + * + *
+     * The maximum age of the cookie in seconds.
+     * 
+ * + * int64 max_age = 8; + * + * @return The maxAge. + */ + @java.lang.Override + public long getMaxAge() { + return maxAge_; + } + + public static final int SAME_SITE_FIELD_NUMBER = 9; + private int sameSite_ = 0; + + /** + * + * + *
+     * Affects cross-site request behavior.
+     * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return The enum numeric value on the wire for sameSite. + */ + @java.lang.Override + public int getSameSiteValue() { + return sameSite_; + } + + /** + * + * + *
+     * Affects cross-site request behavior.
+     * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return The sameSite. + */ + @java.lang.Override + public com.google.backstory.Browser.Cookie.CookieSameSite getSameSite() { + com.google.backstory.Browser.Cookie.CookieSameSite result = + com.google.backstory.Browser.Cookie.CookieSameSite.forNumber(sameSite_); + return result == null + ? com.google.backstory.Browser.Cookie.CookieSameSite.UNRECOGNIZED + : result; + } + + public static final int SESSION_FIELD_NUMBER = 10; + private boolean session_ = false; + + /** + * + * + *
+     * Indicates if the cookie is persistent.
+     * 
+ * + * bool session = 10; + * + * @return The session. + */ + @java.lang.Override + public boolean getSession() { + return session_; + } + + public static final int PARTITIONED_FIELD_NUMBER = 11; + private boolean partitioned_ = false; + + /** + * + * + *
+     * Shows if the cookies is stored using partitioned storage.
+     * 
+ * + * bool partitioned = 11; + * + * @return The partitioned. + */ + @java.lang.Override + public boolean getPartitioned() { + return partitioned_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(value_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, value_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(domain_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, domain_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(path_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, path_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getExpirationTime()); + } + if (httpOnly_ != false) { + output.writeBool(6, httpOnly_); + } + if (secure_ != false) { + output.writeBool(7, secure_); + } + if (maxAge_ != 0L) { + output.writeInt64(8, maxAge_); + } + if (sameSite_ + != com.google.backstory.Browser.Cookie.CookieSameSite.COOKIE_SAME_SITE_UNSPECIFIED + .getNumber()) { + output.writeEnum(9, sameSite_); + } + if (session_ != false) { + output.writeBool(10, session_); + } + if (partitioned_ != false) { + output.writeBool(11, partitioned_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(value_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, value_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(domain_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, domain_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(path_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, path_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getExpirationTime()); + } + if (httpOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, httpOnly_); + } + if (secure_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(7, secure_); + } + if (maxAge_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, maxAge_); + } + if (sameSite_ + != com.google.backstory.Browser.Cookie.CookieSameSite.COOKIE_SAME_SITE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, sameSite_); + } + if (session_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(10, session_); + } + if (partitioned_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, partitioned_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Browser.Cookie)) { + return super.equals(obj); + } + com.google.backstory.Browser.Cookie other = (com.google.backstory.Browser.Cookie) obj; + + if (!getName().equals(other.getName())) return false; + if (!getValue().equals(other.getValue())) return false; + if (!getDomain().equals(other.getDomain())) return false; + if (!getPath().equals(other.getPath())) return false; + if (hasExpirationTime() != other.hasExpirationTime()) return false; + if (hasExpirationTime()) { + if (!getExpirationTime().equals(other.getExpirationTime())) return false; + } + if (getHttpOnly() != other.getHttpOnly()) return false; + if (getSecure() != other.getSecure()) return false; + if (getMaxAge() != other.getMaxAge()) return false; + if (sameSite_ != other.sameSite_) return false; + if (getSession() != other.getSession()) return false; + if (getPartitioned() != other.getPartitioned()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + hash = (37 * hash) + DOMAIN_FIELD_NUMBER; + hash = (53 * hash) + getDomain().hashCode(); + hash = (37 * hash) + PATH_FIELD_NUMBER; + hash = (53 * hash) + getPath().hashCode(); + if (hasExpirationTime()) { + hash = (37 * hash) + EXPIRATION_TIME_FIELD_NUMBER; + hash = (53 * hash) + getExpirationTime().hashCode(); + } + hash = (37 * hash) + HTTP_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getHttpOnly()); + hash = (37 * hash) + SECURE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSecure()); + hash = (37 * hash) + MAX_AGE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getMaxAge()); + hash = (37 * hash) + SAME_SITE_FIELD_NUMBER; + hash = (53 * hash) + sameSite_; + hash = (37 * hash) + SESSION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSession()); + hash = (37 * hash) + PARTITIONED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPartitioned()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Browser.Cookie parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Browser.Cookie parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Browser.Cookie parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Browser.Cookie parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Browser.Cookie parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Browser.Cookie parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Browser.Cookie parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Browser.Cookie parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Browser.Cookie parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Browser.Cookie parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Browser.Cookie parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Browser.Cookie parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Browser.Cookie prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * Browser cookie.
+     * 
+ * + * Protobuf type {@code google.backstory.Browser.Cookie} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Browser.Cookie) + com.google.backstory.Browser.CookieOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_Cookie_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Browser_Cookie_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Browser.Cookie.class, + com.google.backstory.Browser.Cookie.Builder.class); + } + + // Construct using com.google.backstory.Browser.Cookie.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetExpirationTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + value_ = ""; + domain_ = ""; + path_ = ""; + expirationTime_ = null; + if (expirationTimeBuilder_ != null) { + expirationTimeBuilder_.dispose(); + expirationTimeBuilder_ = null; + } + httpOnly_ = false; + secure_ = false; + maxAge_ = 0L; + sameSite_ = 0; + session_ = false; + partitioned_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_Cookie_descriptor; + } + + @java.lang.Override + public com.google.backstory.Browser.Cookie getDefaultInstanceForType() { + return com.google.backstory.Browser.Cookie.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Browser.Cookie build() { + com.google.backstory.Browser.Cookie result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Browser.Cookie buildPartial() { + com.google.backstory.Browser.Cookie result = new com.google.backstory.Browser.Cookie(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.Browser.Cookie result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.value_ = value_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.domain_ = domain_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.path_ = path_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.expirationTime_ = + expirationTimeBuilder_ == null ? expirationTime_ : expirationTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.httpOnly_ = httpOnly_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.secure_ = secure_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.maxAge_ = maxAge_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.sameSite_ = sameSite_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.session_ = session_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.partitioned_ = partitioned_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Browser.Cookie) { + return mergeFrom((com.google.backstory.Browser.Cookie) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Browser.Cookie other) { + if (other == com.google.backstory.Browser.Cookie.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getValue().isEmpty()) { + value_ = other.value_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDomain().isEmpty()) { + domain_ = other.domain_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getPath().isEmpty()) { + path_ = other.path_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.hasExpirationTime()) { + mergeExpirationTime(other.getExpirationTime()); + } + if (other.getHttpOnly() != false) { + setHttpOnly(other.getHttpOnly()); + } + if (other.getSecure() != false) { + setSecure(other.getSecure()); + } + if (other.getMaxAge() != 0L) { + setMaxAge(other.getMaxAge()); + } + if (other.sameSite_ != 0) { + setSameSiteValue(other.getSameSiteValue()); + } + if (other.getSession() != false) { + setSession(other.getSession()); + } + if (other.getPartitioned() != false) { + setPartitioned(other.getPartitioned()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + value_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + domain_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + path_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetExpirationTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 48: + { + httpOnly_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 56: + { + secure_ = input.readBool(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 64: + { + maxAge_ = input.readInt64(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 72: + { + sameSite_ = input.readEnum(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 80: + { + session_ = input.readBool(); + bitField0_ |= 0x00000200; + break; + } // case 80 + case 88: + { + partitioned_ = input.readBool(); + bitField0_ |= 0x00000400; + break; + } // case 88 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+       * The unique name identifying the cookie.
+       * 
+ * + * string name = 1; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The unique name identifying the cookie.
+       * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The unique name identifying the cookie.
+       * 
+ * + * string name = 1; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * The unique name identifying the cookie.
+       * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+       * The unique name identifying the cookie.
+       * 
+ * + * string name = 1; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object value_ = ""; + + /** + * + * + *
+       * The data stored within the cookie.
+       * 
+ * + * string value = 2; + * + * @return The value. + */ + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The data stored within the cookie.
+       * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The data stored within the cookie.
+       * 
+ * + * string value = 2; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * The data stored within the cookie.
+       * 
+ * + * string value = 2; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + value_ = getDefaultInstance().getValue(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+       * The data stored within the cookie.
+       * 
+ * + * string value = 2; + * + * @param value The bytes for value to set. + * @return This builder for chaining. + */ + public Builder setValueBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object domain_ = ""; + + /** + * + * + *
+       * The domain for which the cookie is valid.
+       * 
+ * + * string domain = 3; + * + * @return The domain. + */ + public java.lang.String getDomain() { + java.lang.Object ref = domain_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + domain_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The domain for which the cookie is valid.
+       * 
+ * + * string domain = 3; + * + * @return The bytes for domain. + */ + public com.google.protobuf.ByteString getDomainBytes() { + java.lang.Object ref = domain_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + domain_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The domain for which the cookie is valid.
+       * 
+ * + * string domain = 3; + * + * @param value The domain to set. + * @return This builder for chaining. + */ + public Builder setDomain(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + domain_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * The domain for which the cookie is valid.
+       * 
+ * + * string domain = 3; + * + * @return This builder for chaining. + */ + public Builder clearDomain() { + domain_ = getDefaultInstance().getDomain(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+       * The domain for which the cookie is valid.
+       * 
+ * + * string domain = 3; + * + * @param value The bytes for domain to set. + * @return This builder for chaining. + */ + public Builder setDomainBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + domain_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object path_ = ""; + + /** + * + * + *
+       * The URL path for which the cookie is valid.
+       * 
+ * + * string path = 4; + * + * @return The path. + */ + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The URL path for which the cookie is valid.
+       * 
+ * + * string path = 4; + * + * @return The bytes for path. + */ + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The URL path for which the cookie is valid.
+       * 
+ * + * string path = 4; + * + * @param value The path to set. + * @return This builder for chaining. + */ + public Builder setPath(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + path_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * The URL path for which the cookie is valid.
+       * 
+ * + * string path = 4; + * + * @return This builder for chaining. + */ + public Builder clearPath() { + path_ = getDefaultInstance().getPath(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+       * The URL path for which the cookie is valid.
+       * 
+ * + * string path = 4; + * + * @param value The bytes for path to set. + * @return This builder for chaining. + */ + public Builder setPathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + path_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp expirationTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + expirationTimeBuilder_; + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + * + * @return Whether the expirationTime field is set. + */ + public boolean hasExpirationTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + * + * @return The expirationTime. + */ + public com.google.protobuf.Timestamp getExpirationTime() { + if (expirationTimeBuilder_ == null) { + return expirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expirationTime_; + } else { + return expirationTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + public Builder setExpirationTime(com.google.protobuf.Timestamp value) { + if (expirationTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expirationTime_ = value; + } else { + expirationTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + public Builder setExpirationTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (expirationTimeBuilder_ == null) { + expirationTime_ = builderForValue.build(); + } else { + expirationTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + public Builder mergeExpirationTime(com.google.protobuf.Timestamp value) { + if (expirationTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && expirationTime_ != null + && expirationTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getExpirationTimeBuilder().mergeFrom(value); + } else { + expirationTime_ = value; + } + } else { + expirationTimeBuilder_.mergeFrom(value); + } + if (expirationTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + public Builder clearExpirationTime() { + bitField0_ = (bitField0_ & ~0x00000010); + expirationTime_ = null; + if (expirationTimeBuilder_ != null) { + expirationTimeBuilder_.dispose(); + expirationTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getExpirationTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetExpirationTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder() { + if (expirationTimeBuilder_ != null) { + return expirationTimeBuilder_.getMessageOrBuilder(); + } else { + return expirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expirationTime_; + } + } + + /** + * + * + *
+       * The date and time when the cookie will expire.
+       * 
+ * + * .google.protobuf.Timestamp expiration_time = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetExpirationTimeFieldBuilder() { + if (expirationTimeBuilder_ == null) { + expirationTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getExpirationTime(), getParentForChildren(), isClean()); + expirationTime_ = null; + } + return expirationTimeBuilder_; + } + + private boolean httpOnly_; + + /** + * + * + *
+       * Indicates if the cookie is inaccessible via client-side scripts (e.g.,
+       * JavaScript).
+       * 
+ * + * bool http_only = 6; + * + * @return The httpOnly. + */ + @java.lang.Override + public boolean getHttpOnly() { + return httpOnly_; + } + + /** + * + * + *
+       * Indicates if the cookie is inaccessible via client-side scripts (e.g.,
+       * JavaScript).
+       * 
+ * + * bool http_only = 6; + * + * @param value The httpOnly to set. + * @return This builder for chaining. + */ + public Builder setHttpOnly(boolean value) { + + httpOnly_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+       * Indicates if the cookie is inaccessible via client-side scripts (e.g.,
+       * JavaScript).
+       * 
+ * + * bool http_only = 6; + * + * @return This builder for chaining. + */ + public Builder clearHttpOnly() { + bitField0_ = (bitField0_ & ~0x00000020); + httpOnly_ = false; + onChanged(); + return this; + } + + private boolean secure_; + + /** + * + * + *
+       * Indicates if the cookie should only be sent over secure HTTPS
+       * connections.
+       * 
+ * + * bool secure = 7; + * + * @return The secure. + */ + @java.lang.Override + public boolean getSecure() { + return secure_; + } + + /** + * + * + *
+       * Indicates if the cookie should only be sent over secure HTTPS
+       * connections.
+       * 
+ * + * bool secure = 7; + * + * @param value The secure to set. + * @return This builder for chaining. + */ + public Builder setSecure(boolean value) { + + secure_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+       * Indicates if the cookie should only be sent over secure HTTPS
+       * connections.
+       * 
+ * + * bool secure = 7; + * + * @return This builder for chaining. + */ + public Builder clearSecure() { + bitField0_ = (bitField0_ & ~0x00000040); + secure_ = false; + onChanged(); + return this; + } + + private long maxAge_; + + /** + * + * + *
+       * The maximum age of the cookie in seconds.
+       * 
+ * + * int64 max_age = 8; + * + * @return The maxAge. + */ + @java.lang.Override + public long getMaxAge() { + return maxAge_; + } + + /** + * + * + *
+       * The maximum age of the cookie in seconds.
+       * 
+ * + * int64 max_age = 8; + * + * @param value The maxAge to set. + * @return This builder for chaining. + */ + public Builder setMaxAge(long value) { + + maxAge_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+       * The maximum age of the cookie in seconds.
+       * 
+ * + * int64 max_age = 8; + * + * @return This builder for chaining. + */ + public Builder clearMaxAge() { + bitField0_ = (bitField0_ & ~0x00000080); + maxAge_ = 0L; + onChanged(); + return this; + } + + private int sameSite_ = 0; + + /** + * + * + *
+       * Affects cross-site request behavior.
+       * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return The enum numeric value on the wire for sameSite. + */ + @java.lang.Override + public int getSameSiteValue() { + return sameSite_; + } + + /** + * + * + *
+       * Affects cross-site request behavior.
+       * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @param value The enum numeric value on the wire for sameSite to set. + * @return This builder for chaining. + */ + public Builder setSameSiteValue(int value) { + sameSite_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+       * Affects cross-site request behavior.
+       * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return The sameSite. + */ + @java.lang.Override + public com.google.backstory.Browser.Cookie.CookieSameSite getSameSite() { + com.google.backstory.Browser.Cookie.CookieSameSite result = + com.google.backstory.Browser.Cookie.CookieSameSite.forNumber(sameSite_); + return result == null + ? com.google.backstory.Browser.Cookie.CookieSameSite.UNRECOGNIZED + : result; + } + + /** + * + * + *
+       * Affects cross-site request behavior.
+       * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @param value The sameSite to set. + * @return This builder for chaining. + */ + public Builder setSameSite(com.google.backstory.Browser.Cookie.CookieSameSite value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000100; + sameSite_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+       * Affects cross-site request behavior.
+       * 
+ * + * .google.backstory.Browser.Cookie.CookieSameSite same_site = 9; + * + * @return This builder for chaining. + */ + public Builder clearSameSite() { + bitField0_ = (bitField0_ & ~0x00000100); + sameSite_ = 0; + onChanged(); + return this; + } + + private boolean session_; + + /** + * + * + *
+       * Indicates if the cookie is persistent.
+       * 
+ * + * bool session = 10; + * + * @return The session. + */ + @java.lang.Override + public boolean getSession() { + return session_; + } + + /** + * + * + *
+       * Indicates if the cookie is persistent.
+       * 
+ * + * bool session = 10; + * + * @param value The session to set. + * @return This builder for chaining. + */ + public Builder setSession(boolean value) { + + session_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+       * Indicates if the cookie is persistent.
+       * 
+ * + * bool session = 10; + * + * @return This builder for chaining. + */ + public Builder clearSession() { + bitField0_ = (bitField0_ & ~0x00000200); + session_ = false; + onChanged(); + return this; + } + + private boolean partitioned_; + + /** + * + * + *
+       * Shows if the cookies is stored using partitioned storage.
+       * 
+ * + * bool partitioned = 11; + * + * @return The partitioned. + */ + @java.lang.Override + public boolean getPartitioned() { + return partitioned_; + } + + /** + * + * + *
+       * Shows if the cookies is stored using partitioned storage.
+       * 
+ * + * bool partitioned = 11; + * + * @param value The partitioned to set. + * @return This builder for chaining. + */ + public Builder setPartitioned(boolean value) { + + partitioned_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+       * Shows if the cookies is stored using partitioned storage.
+       * 
+ * + * bool partitioned = 11; + * + * @return This builder for chaining. + */ + public Builder clearPartitioned() { + bitField0_ = (bitField0_ & ~0x00000400); + partitioned_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Browser.Cookie) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Browser.Cookie) + private static final com.google.backstory.Browser.Cookie DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Browser.Cookie(); + } + + public static com.google.backstory.Browser.Cookie getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Cookie parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Browser.Cookie getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int BROWSER_TYPE_FIELD_NUMBER = 1; + private int browserType_ = 0; + + /** + * + * + *
+   * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+   * "Safari", etc.).
+   * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return The enum numeric value on the wire for browserType. + */ + @java.lang.Override + public int getBrowserTypeValue() { + return browserType_; + } + + /** + * + * + *
+   * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+   * "Safari", etc.).
+   * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return The browserType. + */ + @java.lang.Override + public com.google.backstory.Browser.BrowserType getBrowserType() { + com.google.backstory.Browser.BrowserType result = + com.google.backstory.Browser.BrowserType.forNumber(browserType_); + return result == null ? com.google.backstory.Browser.BrowserType.UNRECOGNIZED : result; + } + + public static final int BROWSER_VERSION_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object browserVersion_ = ""; + + /** + * + * + *
+   * The browser version.
+   * 
+ * + * string browser_version = 2; + * + * @return The browserVersion. + */ + @java.lang.Override + public java.lang.String getBrowserVersion() { + java.lang.Object ref = browserVersion_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + browserVersion_ = s; + return s; + } + } + + /** + * + * + *
+   * The browser version.
+   * 
+ * + * string browser_version = 2; + * + * @return The bytes for browserVersion. + */ + @java.lang.Override + public com.google.protobuf.ByteString getBrowserVersionBytes() { + java.lang.Object ref = browserVersion_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + browserVersion_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FIRST_VISIT_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp firstVisitTime_; + + /** + * + * + *
+   * The timestamp indicating the initial visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + * + * @return Whether the firstVisitTime field is set. + */ + @java.lang.Override + public boolean hasFirstVisitTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The timestamp indicating the initial visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + * + * @return The firstVisitTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getFirstVisitTime() { + return firstVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstVisitTime_; + } + + /** + * + * + *
+   * The timestamp indicating the initial visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getFirstVisitTimeOrBuilder() { + return firstVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstVisitTime_; + } + + public static final int LAST_VISIT_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp lastVisitTime_; + + /** + * + * + *
+   * The timestamp indicating the most recent visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + * + * @return Whether the lastVisitTime field is set. + */ + @java.lang.Override + public boolean hasLastVisitTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The timestamp indicating the most recent visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + * + * @return The lastVisitTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastVisitTime() { + return lastVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastVisitTime_; + } + + /** + * + * + *
+   * The timestamp indicating the most recent visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastVisitTimeOrBuilder() { + return lastVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastVisitTime_; + } + + public static final int PROFILE_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object profile_ = ""; + + /** + * + * + *
+   * The browser profile associated with the history entry.
+   * 
+ * + * string profile = 5; + * + * @return The profile. + */ + @java.lang.Override + public java.lang.String getProfile() { + java.lang.Object ref = profile_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + profile_ = s; + return s; + } + } + + /** + * + * + *
+   * The browser profile associated with the history entry.
+   * 
+ * + * string profile = 5; + * + * @return The bytes for profile. + */ + @java.lang.Override + public com.google.protobuf.ByteString getProfileBytes() { + java.lang.Object ref = profile_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + profile_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TYPED_FIELD_NUMBER = 6; + private boolean typed_ = false; + + /** + * + * + *
+   * A boolean value indicating if the URL was typed by the user.
+   * 
+ * + * bool typed = 6; + * + * @return The typed. + */ + @java.lang.Override + public boolean getTyped() { + return typed_; + } + + public static final int VISIT_TYPE_FIELD_NUMBER = 7; + private int visitType_ = 0; + + /** + * + * + *
+   * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+   * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return The enum numeric value on the wire for visitType. + */ + @java.lang.Override + public int getVisitTypeValue() { + return visitType_; + } + + /** + * + * + *
+   * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+   * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return The visitType. + */ + @java.lang.Override + public com.google.backstory.Browser.UrlVisitType getVisitType() { + com.google.backstory.Browser.UrlVisitType result = + com.google.backstory.Browser.UrlVisitType.forNumber(visitType_); + return result == null ? com.google.backstory.Browser.UrlVisitType.UNRECOGNIZED : result; + } + + public static final int HIDDEN_FIELD_NUMBER = 8; + private boolean hidden_ = false; + + /** + * + * + *
+   * A boolean value indicating if the history entry is hidden.
+   * 
+ * + * bool hidden = 8; + * + * @return The hidden. + */ + @java.lang.Override + public boolean getHidden() { + return hidden_; + } + + public static final int REQUEST_ORIGIN_URI_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestOriginUri_ = ""; + + /** + * + * + *
+   * Indicates the URI from which the current visit originated.
+   * 
+ * + * string request_origin_uri = 9; + * + * @return The requestOriginUri. + */ + @java.lang.Override + public java.lang.String getRequestOriginUri() { + java.lang.Object ref = requestOriginUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestOriginUri_ = s; + return s; + } + } + + /** + * + * + *
+   * Indicates the URI from which the current visit originated.
+   * 
+ * + * string request_origin_uri = 9; + * + * @return The bytes for requestOriginUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestOriginUriBytes() { + java.lang.Object ref = requestOriginUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestOriginUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VISIT_COUNT_FIELD_NUMBER = 10; + private long visitCount_ = 0L; + + /** + * + * + *
+   * The total number of times the Url has been visited.
+   * 
+ * + * int64 visit_count = 10; + * + * @return The visitCount. + */ + @java.lang.Override + public long getVisitCount() { + return visitCount_; + } + + public static final int VISIT_COUNT_CRITERIA_FIELD_NUMBER = 11; + + @SuppressWarnings("serial") + private volatile java.lang.Object visitCountCriteria_ = ""; + + /** + * + * + *
+   * Describes the criteria used to calculate the visit_count.
+   * 
+ * + * string visit_count_criteria = 11; + * + * @return The visitCountCriteria. + */ + @java.lang.Override + public java.lang.String getVisitCountCriteria() { + java.lang.Object ref = visitCountCriteria_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + visitCountCriteria_ = s; + return s; + } + } + + /** + * + * + *
+   * Describes the criteria used to calculate the visit_count.
+   * 
+ * + * string visit_count_criteria = 11; + * + * @return The bytes for visitCountCriteria. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVisitCountCriteriaBytes() { + java.lang.Object ref = visitCountCriteria_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + visitCountCriteria_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int INDEXED_CONTENT_FIELD_NUMBER = 12; + + @SuppressWarnings("serial") + private volatile java.lang.Object indexedContent_ = ""; + + /** + * + * + *
+   * Represents the textual content of a web page. This field should be kept
+   * short. Large strings may affect latency and payload sizes.
+   * 
+ * + * string indexed_content = 12; + * + * @return The indexedContent. + */ + @java.lang.Override + public java.lang.String getIndexedContent() { + java.lang.Object ref = indexedContent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + indexedContent_ = s; + return s; + } + } + + /** + * + * + *
+   * Represents the textual content of a web page. This field should be kept
+   * short. Large strings may affect latency and payload sizes.
+   * 
+ * + * string indexed_content = 12; + * + * @return The bytes for indexedContent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIndexedContentBytes() { + java.lang.Object ref = indexedContent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + indexedContent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FIRST_BOOKMARKED_TIME_FIELD_NUMBER = 13; + private com.google.protobuf.Timestamp firstBookmarkedTime_; + + /** + * + * + *
+   * The timestamp indicating the first time the URL was bookmarked.
+   * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + * + * @return Whether the firstBookmarkedTime field is set. + */ + @java.lang.Override + public boolean hasFirstBookmarkedTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * The timestamp indicating the first time the URL was bookmarked.
+   * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + * + * @return The firstBookmarkedTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getFirstBookmarkedTime() { + return firstBookmarkedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstBookmarkedTime_; + } + + /** + * + * + *
+   * The timestamp indicating the first time the URL was bookmarked.
+   * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getFirstBookmarkedTimeOrBuilder() { + return firstBookmarkedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstBookmarkedTime_; + } + + public static final int COOKIES_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private java.util.List cookies_; + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + @java.lang.Override + public java.util.List getCookiesList() { + return cookies_; + } + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + @java.lang.Override + public java.util.List + getCookiesOrBuilderList() { + return cookies_; + } + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + @java.lang.Override + public int getCookiesCount() { + return cookies_.size(); + } + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + @java.lang.Override + public com.google.backstory.Browser.Cookie getCookies(int index) { + return cookies_.get(index); + } + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + @java.lang.Override + public com.google.backstory.Browser.CookieOrBuilder getCookiesOrBuilder(int index) { + return cookies_.get(index); + } + + public static final int TYPED_COUNT_FIELD_NUMBER = 15; + private long typedCount_ = 0L; + + /** + * + * + *
+   * The number of times the URL was visited with this specific visit type and
+   * visit source.
+   * 
+ * + * int64 typed_count = 15; + * + * @return The typedCount. + */ + @java.lang.Override + public long getTypedCount() { + return typedCount_; + } + + public static final int VISIT_SOURCE_FIELD_NUMBER = 16; + private int visitSource_ = 0; + + /** + * + * + *
+   * The source of the visit.
+   * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return The enum numeric value on the wire for visitSource. + */ + @java.lang.Override + public int getVisitSourceValue() { + return visitSource_; + } + + /** + * + * + *
+   * The source of the visit.
+   * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return The visitSource. + */ + @java.lang.Override + public com.google.backstory.Browser.VisitSource getVisitSource() { + com.google.backstory.Browser.VisitSource result = + com.google.backstory.Browser.VisitSource.forNumber(visitSource_); + return result == null ? com.google.backstory.Browser.VisitSource.UNRECOGNIZED : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (browserType_ + != com.google.backstory.Browser.BrowserType.BROWSER_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(1, browserType_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(browserVersion_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, browserVersion_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getFirstVisitTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getLastVisitTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(profile_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, profile_); + } + if (typed_ != false) { + output.writeBool(6, typed_); + } + if (visitType_ + != com.google.backstory.Browser.UrlVisitType.URL_VISIT_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(7, visitType_); + } + if (hidden_ != false) { + output.writeBool(8, hidden_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestOriginUri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 9, requestOriginUri_); + } + if (visitCount_ != 0L) { + output.writeInt64(10, visitCount_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(visitCountCriteria_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 11, visitCountCriteria_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(indexedContent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 12, indexedContent_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(13, getFirstBookmarkedTime()); + } + for (int i = 0; i < cookies_.size(); i++) { + output.writeMessage(14, cookies_.get(i)); + } + if (typedCount_ != 0L) { + output.writeInt64(15, typedCount_); + } + if (visitSource_ + != com.google.backstory.Browser.VisitSource.VISIT_SOURCE_UNSPECIFIED.getNumber()) { + output.writeEnum(16, visitSource_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (browserType_ + != com.google.backstory.Browser.BrowserType.BROWSER_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, browserType_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(browserVersion_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, browserVersion_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFirstVisitTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getLastVisitTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(profile_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, profile_); + } + if (typed_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, typed_); + } + if (visitType_ + != com.google.backstory.Browser.UrlVisitType.URL_VISIT_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, visitType_); + } + if (hidden_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, hidden_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestOriginUri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(9, requestOriginUri_); + } + if (visitCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(10, visitCount_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(visitCountCriteria_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(11, visitCountCriteria_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(indexedContent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(12, indexedContent_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(13, getFirstBookmarkedTime()); + } + for (int i = 0; i < cookies_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(14, cookies_.get(i)); + } + if (typedCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(15, typedCount_); + } + if (visitSource_ + != com.google.backstory.Browser.VisitSource.VISIT_SOURCE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(16, visitSource_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Browser)) { + return super.equals(obj); + } + com.google.backstory.Browser other = (com.google.backstory.Browser) obj; + + if (browserType_ != other.browserType_) return false; + if (!getBrowserVersion().equals(other.getBrowserVersion())) return false; + if (hasFirstVisitTime() != other.hasFirstVisitTime()) return false; + if (hasFirstVisitTime()) { + if (!getFirstVisitTime().equals(other.getFirstVisitTime())) return false; + } + if (hasLastVisitTime() != other.hasLastVisitTime()) return false; + if (hasLastVisitTime()) { + if (!getLastVisitTime().equals(other.getLastVisitTime())) return false; + } + if (!getProfile().equals(other.getProfile())) return false; + if (getTyped() != other.getTyped()) return false; + if (visitType_ != other.visitType_) return false; + if (getHidden() != other.getHidden()) return false; + if (!getRequestOriginUri().equals(other.getRequestOriginUri())) return false; + if (getVisitCount() != other.getVisitCount()) return false; + if (!getVisitCountCriteria().equals(other.getVisitCountCriteria())) return false; + if (!getIndexedContent().equals(other.getIndexedContent())) return false; + if (hasFirstBookmarkedTime() != other.hasFirstBookmarkedTime()) return false; + if (hasFirstBookmarkedTime()) { + if (!getFirstBookmarkedTime().equals(other.getFirstBookmarkedTime())) return false; + } + if (!getCookiesList().equals(other.getCookiesList())) return false; + if (getTypedCount() != other.getTypedCount()) return false; + if (visitSource_ != other.visitSource_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + BROWSER_TYPE_FIELD_NUMBER; + hash = (53 * hash) + browserType_; + hash = (37 * hash) + BROWSER_VERSION_FIELD_NUMBER; + hash = (53 * hash) + getBrowserVersion().hashCode(); + if (hasFirstVisitTime()) { + hash = (37 * hash) + FIRST_VISIT_TIME_FIELD_NUMBER; + hash = (53 * hash) + getFirstVisitTime().hashCode(); + } + if (hasLastVisitTime()) { + hash = (37 * hash) + LAST_VISIT_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastVisitTime().hashCode(); + } + hash = (37 * hash) + PROFILE_FIELD_NUMBER; + hash = (53 * hash) + getProfile().hashCode(); + hash = (37 * hash) + TYPED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getTyped()); + hash = (37 * hash) + VISIT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + visitType_; + hash = (37 * hash) + HIDDEN_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getHidden()); + hash = (37 * hash) + REQUEST_ORIGIN_URI_FIELD_NUMBER; + hash = (53 * hash) + getRequestOriginUri().hashCode(); + hash = (37 * hash) + VISIT_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getVisitCount()); + hash = (37 * hash) + VISIT_COUNT_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getVisitCountCriteria().hashCode(); + hash = (37 * hash) + INDEXED_CONTENT_FIELD_NUMBER; + hash = (53 * hash) + getIndexedContent().hashCode(); + if (hasFirstBookmarkedTime()) { + hash = (37 * hash) + FIRST_BOOKMARKED_TIME_FIELD_NUMBER; + hash = (53 * hash) + getFirstBookmarkedTime().hashCode(); + } + if (getCookiesCount() > 0) { + hash = (37 * hash) + COOKIES_FIELD_NUMBER; + hash = (53 * hash) + getCookiesList().hashCode(); + } + hash = (37 * hash) + TYPED_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTypedCount()); + hash = (37 * hash) + VISIT_SOURCE_FIELD_NUMBER; + hash = (53 * hash) + visitSource_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Browser parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Browser parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Browser parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Browser parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Browser parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Browser parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Browser parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Browser parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Browser parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Browser parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Browser parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Browser parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Browser prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Information about an entry in the web browser's local history database.
+   * 
+ * + * Protobuf type {@code google.backstory.Browser} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Browser) + com.google.backstory.BrowserOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Browser.class, com.google.backstory.Browser.Builder.class); + } + + // Construct using com.google.backstory.Browser.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetFirstVisitTimeFieldBuilder(); + internalGetLastVisitTimeFieldBuilder(); + internalGetFirstBookmarkedTimeFieldBuilder(); + internalGetCookiesFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + browserType_ = 0; + browserVersion_ = ""; + firstVisitTime_ = null; + if (firstVisitTimeBuilder_ != null) { + firstVisitTimeBuilder_.dispose(); + firstVisitTimeBuilder_ = null; + } + lastVisitTime_ = null; + if (lastVisitTimeBuilder_ != null) { + lastVisitTimeBuilder_.dispose(); + lastVisitTimeBuilder_ = null; + } + profile_ = ""; + typed_ = false; + visitType_ = 0; + hidden_ = false; + requestOriginUri_ = ""; + visitCount_ = 0L; + visitCountCriteria_ = ""; + indexedContent_ = ""; + firstBookmarkedTime_ = null; + if (firstBookmarkedTimeBuilder_ != null) { + firstBookmarkedTimeBuilder_.dispose(); + firstBookmarkedTimeBuilder_ = null; + } + if (cookiesBuilder_ == null) { + cookies_ = java.util.Collections.emptyList(); + } else { + cookies_ = null; + cookiesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00002000); + typedCount_ = 0L; + visitSource_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Browser_descriptor; + } + + @java.lang.Override + public com.google.backstory.Browser getDefaultInstanceForType() { + return com.google.backstory.Browser.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Browser build() { + com.google.backstory.Browser result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Browser buildPartial() { + com.google.backstory.Browser result = new com.google.backstory.Browser(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.Browser result) { + if (cookiesBuilder_ == null) { + if (((bitField0_ & 0x00002000) != 0)) { + cookies_ = java.util.Collections.unmodifiableList(cookies_); + bitField0_ = (bitField0_ & ~0x00002000); + } + result.cookies_ = cookies_; + } else { + result.cookies_ = cookiesBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.Browser result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.browserType_ = browserType_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.browserVersion_ = browserVersion_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.firstVisitTime_ = + firstVisitTimeBuilder_ == null ? firstVisitTime_ : firstVisitTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.lastVisitTime_ = + lastVisitTimeBuilder_ == null ? lastVisitTime_ : lastVisitTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.profile_ = profile_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.typed_ = typed_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.visitType_ = visitType_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.hidden_ = hidden_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.requestOriginUri_ = requestOriginUri_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.visitCount_ = visitCount_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.visitCountCriteria_ = visitCountCriteria_; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.indexedContent_ = indexedContent_; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.firstBookmarkedTime_ = + firstBookmarkedTimeBuilder_ == null + ? firstBookmarkedTime_ + : firstBookmarkedTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00004000) != 0)) { + result.typedCount_ = typedCount_; + } + if (((from_bitField0_ & 0x00008000) != 0)) { + result.visitSource_ = visitSource_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Browser) { + return mergeFrom((com.google.backstory.Browser) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Browser other) { + if (other == com.google.backstory.Browser.getDefaultInstance()) return this; + if (other.browserType_ != 0) { + setBrowserTypeValue(other.getBrowserTypeValue()); + } + if (!other.getBrowserVersion().isEmpty()) { + browserVersion_ = other.browserVersion_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasFirstVisitTime()) { + mergeFirstVisitTime(other.getFirstVisitTime()); + } + if (other.hasLastVisitTime()) { + mergeLastVisitTime(other.getLastVisitTime()); + } + if (!other.getProfile().isEmpty()) { + profile_ = other.profile_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (other.getTyped() != false) { + setTyped(other.getTyped()); + } + if (other.visitType_ != 0) { + setVisitTypeValue(other.getVisitTypeValue()); + } + if (other.getHidden() != false) { + setHidden(other.getHidden()); + } + if (!other.getRequestOriginUri().isEmpty()) { + requestOriginUri_ = other.requestOriginUri_; + bitField0_ |= 0x00000100; + onChanged(); + } + if (other.getVisitCount() != 0L) { + setVisitCount(other.getVisitCount()); + } + if (!other.getVisitCountCriteria().isEmpty()) { + visitCountCriteria_ = other.visitCountCriteria_; + bitField0_ |= 0x00000400; + onChanged(); + } + if (!other.getIndexedContent().isEmpty()) { + indexedContent_ = other.indexedContent_; + bitField0_ |= 0x00000800; + onChanged(); + } + if (other.hasFirstBookmarkedTime()) { + mergeFirstBookmarkedTime(other.getFirstBookmarkedTime()); + } + if (cookiesBuilder_ == null) { + if (!other.cookies_.isEmpty()) { + if (cookies_.isEmpty()) { + cookies_ = other.cookies_; + bitField0_ = (bitField0_ & ~0x00002000); + } else { + ensureCookiesIsMutable(); + cookies_.addAll(other.cookies_); + } + onChanged(); + } + } else { + if (!other.cookies_.isEmpty()) { + if (cookiesBuilder_.isEmpty()) { + cookiesBuilder_.dispose(); + cookiesBuilder_ = null; + cookies_ = other.cookies_; + bitField0_ = (bitField0_ & ~0x00002000); + cookiesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetCookiesFieldBuilder() + : null; + } else { + cookiesBuilder_.addAllMessages(other.cookies_); + } + } + } + if (other.getTypedCount() != 0L) { + setTypedCount(other.getTypedCount()); + } + if (other.visitSource_ != 0) { + setVisitSourceValue(other.getVisitSourceValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + browserType_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + browserVersion_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetFirstVisitTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetLastVisitTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + profile_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 48: + { + typed_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 56: + { + visitType_ = input.readEnum(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 64: + { + hidden_ = input.readBool(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 74: + { + requestOriginUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000100; + break; + } // case 74 + case 80: + { + visitCount_ = input.readInt64(); + bitField0_ |= 0x00000200; + break; + } // case 80 + case 90: + { + visitCountCriteria_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000400; + break; + } // case 90 + case 98: + { + indexedContent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000800; + break; + } // case 98 + case 106: + { + input.readMessage( + internalGetFirstBookmarkedTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00001000; + break; + } // case 106 + case 114: + { + com.google.backstory.Browser.Cookie m = + input.readMessage( + com.google.backstory.Browser.Cookie.parser(), extensionRegistry); + if (cookiesBuilder_ == null) { + ensureCookiesIsMutable(); + cookies_.add(m); + } else { + cookiesBuilder_.addMessage(m); + } + break; + } // case 114 + case 120: + { + typedCount_ = input.readInt64(); + bitField0_ |= 0x00004000; + break; + } // case 120 + case 128: + { + visitSource_ = input.readEnum(); + bitField0_ |= 0x00008000; + break; + } // case 128 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int browserType_ = 0; + + /** + * + * + *
+     * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+     * "Safari", etc.).
+     * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return The enum numeric value on the wire for browserType. + */ + @java.lang.Override + public int getBrowserTypeValue() { + return browserType_; + } + + /** + * + * + *
+     * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+     * "Safari", etc.).
+     * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @param value The enum numeric value on the wire for browserType to set. + * @return This builder for chaining. + */ + public Builder setBrowserTypeValue(int value) { + browserType_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+     * "Safari", etc.).
+     * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return The browserType. + */ + @java.lang.Override + public com.google.backstory.Browser.BrowserType getBrowserType() { + com.google.backstory.Browser.BrowserType result = + com.google.backstory.Browser.BrowserType.forNumber(browserType_); + return result == null ? com.google.backstory.Browser.BrowserType.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+     * "Safari", etc.).
+     * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @param value The browserType to set. + * @return This builder for chaining. + */ + public Builder setBrowserType(com.google.backstory.Browser.BrowserType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + browserType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+     * "Safari", etc.).
+     * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return This builder for chaining. + */ + public Builder clearBrowserType() { + bitField0_ = (bitField0_ & ~0x00000001); + browserType_ = 0; + onChanged(); + return this; + } + + private java.lang.Object browserVersion_ = ""; + + /** + * + * + *
+     * The browser version.
+     * 
+ * + * string browser_version = 2; + * + * @return The browserVersion. + */ + public java.lang.String getBrowserVersion() { + java.lang.Object ref = browserVersion_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + browserVersion_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The browser version.
+     * 
+ * + * string browser_version = 2; + * + * @return The bytes for browserVersion. + */ + public com.google.protobuf.ByteString getBrowserVersionBytes() { + java.lang.Object ref = browserVersion_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + browserVersion_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The browser version.
+     * 
+ * + * string browser_version = 2; + * + * @param value The browserVersion to set. + * @return This builder for chaining. + */ + public Builder setBrowserVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + browserVersion_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The browser version.
+     * 
+ * + * string browser_version = 2; + * + * @return This builder for chaining. + */ + public Builder clearBrowserVersion() { + browserVersion_ = getDefaultInstance().getBrowserVersion(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * The browser version.
+     * 
+ * + * string browser_version = 2; + * + * @param value The bytes for browserVersion to set. + * @return This builder for chaining. + */ + public Builder setBrowserVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + browserVersion_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp firstVisitTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + firstVisitTimeBuilder_; + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + * + * @return Whether the firstVisitTime field is set. + */ + public boolean hasFirstVisitTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + * + * @return The firstVisitTime. + */ + public com.google.protobuf.Timestamp getFirstVisitTime() { + if (firstVisitTimeBuilder_ == null) { + return firstVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstVisitTime_; + } else { + return firstVisitTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + public Builder setFirstVisitTime(com.google.protobuf.Timestamp value) { + if (firstVisitTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + firstVisitTime_ = value; + } else { + firstVisitTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + public Builder setFirstVisitTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (firstVisitTimeBuilder_ == null) { + firstVisitTime_ = builderForValue.build(); + } else { + firstVisitTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + public Builder mergeFirstVisitTime(com.google.protobuf.Timestamp value) { + if (firstVisitTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && firstVisitTime_ != null + && firstVisitTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getFirstVisitTimeBuilder().mergeFrom(value); + } else { + firstVisitTime_ = value; + } + } else { + firstVisitTimeBuilder_.mergeFrom(value); + } + if (firstVisitTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + public Builder clearFirstVisitTime() { + bitField0_ = (bitField0_ & ~0x00000004); + firstVisitTime_ = null; + if (firstVisitTimeBuilder_ != null) { + firstVisitTimeBuilder_.dispose(); + firstVisitTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + public com.google.protobuf.Timestamp.Builder getFirstVisitTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetFirstVisitTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + public com.google.protobuf.TimestampOrBuilder getFirstVisitTimeOrBuilder() { + if (firstVisitTimeBuilder_ != null) { + return firstVisitTimeBuilder_.getMessageOrBuilder(); + } else { + return firstVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstVisitTime_; + } + } + + /** + * + * + *
+     * The timestamp indicating the initial visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetFirstVisitTimeFieldBuilder() { + if (firstVisitTimeBuilder_ == null) { + firstVisitTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getFirstVisitTime(), getParentForChildren(), isClean()); + firstVisitTime_ = null; + } + return firstVisitTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastVisitTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastVisitTimeBuilder_; + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + * + * @return Whether the lastVisitTime field is set. + */ + public boolean hasLastVisitTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + * + * @return The lastVisitTime. + */ + public com.google.protobuf.Timestamp getLastVisitTime() { + if (lastVisitTimeBuilder_ == null) { + return lastVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastVisitTime_; + } else { + return lastVisitTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + public Builder setLastVisitTime(com.google.protobuf.Timestamp value) { + if (lastVisitTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastVisitTime_ = value; + } else { + lastVisitTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + public Builder setLastVisitTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastVisitTimeBuilder_ == null) { + lastVisitTime_ = builderForValue.build(); + } else { + lastVisitTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + public Builder mergeLastVisitTime(com.google.protobuf.Timestamp value) { + if (lastVisitTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && lastVisitTime_ != null + && lastVisitTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastVisitTimeBuilder().mergeFrom(value); + } else { + lastVisitTime_ = value; + } + } else { + lastVisitTimeBuilder_.mergeFrom(value); + } + if (lastVisitTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + public Builder clearLastVisitTime() { + bitField0_ = (bitField0_ & ~0x00000008); + lastVisitTime_ = null; + if (lastVisitTimeBuilder_ != null) { + lastVisitTimeBuilder_.dispose(); + lastVisitTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + public com.google.protobuf.Timestamp.Builder getLastVisitTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetLastVisitTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + public com.google.protobuf.TimestampOrBuilder getLastVisitTimeOrBuilder() { + if (lastVisitTimeBuilder_ != null) { + return lastVisitTimeBuilder_.getMessageOrBuilder(); + } else { + return lastVisitTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastVisitTime_; + } + } + + /** + * + * + *
+     * The timestamp indicating the most recent visit to the URL.
+     * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastVisitTimeFieldBuilder() { + if (lastVisitTimeBuilder_ == null) { + lastVisitTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastVisitTime(), getParentForChildren(), isClean()); + lastVisitTime_ = null; + } + return lastVisitTimeBuilder_; + } + + private java.lang.Object profile_ = ""; + + /** + * + * + *
+     * The browser profile associated with the history entry.
+     * 
+ * + * string profile = 5; + * + * @return The profile. + */ + public java.lang.String getProfile() { + java.lang.Object ref = profile_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + profile_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The browser profile associated with the history entry.
+     * 
+ * + * string profile = 5; + * + * @return The bytes for profile. + */ + public com.google.protobuf.ByteString getProfileBytes() { + java.lang.Object ref = profile_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + profile_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The browser profile associated with the history entry.
+     * 
+ * + * string profile = 5; + * + * @param value The profile to set. + * @return This builder for chaining. + */ + public Builder setProfile(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + profile_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * The browser profile associated with the history entry.
+     * 
+ * + * string profile = 5; + * + * @return This builder for chaining. + */ + public Builder clearProfile() { + profile_ = getDefaultInstance().getProfile(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * The browser profile associated with the history entry.
+     * 
+ * + * string profile = 5; + * + * @param value The bytes for profile to set. + * @return This builder for chaining. + */ + public Builder setProfileBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + profile_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private boolean typed_; + + /** + * + * + *
+     * A boolean value indicating if the URL was typed by the user.
+     * 
+ * + * bool typed = 6; + * + * @return The typed. + */ + @java.lang.Override + public boolean getTyped() { + return typed_; + } + + /** + * + * + *
+     * A boolean value indicating if the URL was typed by the user.
+     * 
+ * + * bool typed = 6; + * + * @param value The typed to set. + * @return This builder for chaining. + */ + public Builder setTyped(boolean value) { + + typed_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * A boolean value indicating if the URL was typed by the user.
+     * 
+ * + * bool typed = 6; + * + * @return This builder for chaining. + */ + public Builder clearTyped() { + bitField0_ = (bitField0_ & ~0x00000020); + typed_ = false; + onChanged(); + return this; + } + + private int visitType_ = 0; + + /** + * + * + *
+     * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+     * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return The enum numeric value on the wire for visitType. + */ + @java.lang.Override + public int getVisitTypeValue() { + return visitType_; + } + + /** + * + * + *
+     * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+     * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @param value The enum numeric value on the wire for visitType to set. + * @return This builder for chaining. + */ + public Builder setVisitTypeValue(int value) { + visitType_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+     * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return The visitType. + */ + @java.lang.Override + public com.google.backstory.Browser.UrlVisitType getVisitType() { + com.google.backstory.Browser.UrlVisitType result = + com.google.backstory.Browser.UrlVisitType.forNumber(visitType_); + return result == null ? com.google.backstory.Browser.UrlVisitType.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+     * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @param value The visitType to set. + * @return This builder for chaining. + */ + public Builder setVisitType(com.google.backstory.Browser.UrlVisitType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000040; + visitType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+     * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return This builder for chaining. + */ + public Builder clearVisitType() { + bitField0_ = (bitField0_ & ~0x00000040); + visitType_ = 0; + onChanged(); + return this; + } + + private boolean hidden_; + + /** + * + * + *
+     * A boolean value indicating if the history entry is hidden.
+     * 
+ * + * bool hidden = 8; + * + * @return The hidden. + */ + @java.lang.Override + public boolean getHidden() { + return hidden_; + } + + /** + * + * + *
+     * A boolean value indicating if the history entry is hidden.
+     * 
+ * + * bool hidden = 8; + * + * @param value The hidden to set. + * @return This builder for chaining. + */ + public Builder setHidden(boolean value) { + + hidden_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * A boolean value indicating if the history entry is hidden.
+     * 
+ * + * bool hidden = 8; + * + * @return This builder for chaining. + */ + public Builder clearHidden() { + bitField0_ = (bitField0_ & ~0x00000080); + hidden_ = false; + onChanged(); + return this; + } + + private java.lang.Object requestOriginUri_ = ""; + + /** + * + * + *
+     * Indicates the URI from which the current visit originated.
+     * 
+ * + * string request_origin_uri = 9; + * + * @return The requestOriginUri. + */ + public java.lang.String getRequestOriginUri() { + java.lang.Object ref = requestOriginUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestOriginUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Indicates the URI from which the current visit originated.
+     * 
+ * + * string request_origin_uri = 9; + * + * @return The bytes for requestOriginUri. + */ + public com.google.protobuf.ByteString getRequestOriginUriBytes() { + java.lang.Object ref = requestOriginUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestOriginUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Indicates the URI from which the current visit originated.
+     * 
+ * + * string request_origin_uri = 9; + * + * @param value The requestOriginUri to set. + * @return This builder for chaining. + */ + public Builder setRequestOriginUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestOriginUri_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates the URI from which the current visit originated.
+     * 
+ * + * string request_origin_uri = 9; + * + * @return This builder for chaining. + */ + public Builder clearRequestOriginUri() { + requestOriginUri_ = getDefaultInstance().getRequestOriginUri(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates the URI from which the current visit originated.
+     * 
+ * + * string request_origin_uri = 9; + * + * @param value The bytes for requestOriginUri to set. + * @return This builder for chaining. + */ + public Builder setRequestOriginUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestOriginUri_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + private long visitCount_; + + /** + * + * + *
+     * The total number of times the Url has been visited.
+     * 
+ * + * int64 visit_count = 10; + * + * @return The visitCount. + */ + @java.lang.Override + public long getVisitCount() { + return visitCount_; + } + + /** + * + * + *
+     * The total number of times the Url has been visited.
+     * 
+ * + * int64 visit_count = 10; + * + * @param value The visitCount to set. + * @return This builder for chaining. + */ + public Builder setVisitCount(long value) { + + visitCount_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * The total number of times the Url has been visited.
+     * 
+ * + * int64 visit_count = 10; + * + * @return This builder for chaining. + */ + public Builder clearVisitCount() { + bitField0_ = (bitField0_ & ~0x00000200); + visitCount_ = 0L; + onChanged(); + return this; + } + + private java.lang.Object visitCountCriteria_ = ""; + + /** + * + * + *
+     * Describes the criteria used to calculate the visit_count.
+     * 
+ * + * string visit_count_criteria = 11; + * + * @return The visitCountCriteria. + */ + public java.lang.String getVisitCountCriteria() { + java.lang.Object ref = visitCountCriteria_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + visitCountCriteria_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Describes the criteria used to calculate the visit_count.
+     * 
+ * + * string visit_count_criteria = 11; + * + * @return The bytes for visitCountCriteria. + */ + public com.google.protobuf.ByteString getVisitCountCriteriaBytes() { + java.lang.Object ref = visitCountCriteria_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + visitCountCriteria_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Describes the criteria used to calculate the visit_count.
+     * 
+ * + * string visit_count_criteria = 11; + * + * @param value The visitCountCriteria to set. + * @return This builder for chaining. + */ + public Builder setVisitCountCriteria(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + visitCountCriteria_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Describes the criteria used to calculate the visit_count.
+     * 
+ * + * string visit_count_criteria = 11; + * + * @return This builder for chaining. + */ + public Builder clearVisitCountCriteria() { + visitCountCriteria_ = getDefaultInstance().getVisitCountCriteria(); + bitField0_ = (bitField0_ & ~0x00000400); + onChanged(); + return this; + } + + /** + * + * + *
+     * Describes the criteria used to calculate the visit_count.
+     * 
+ * + * string visit_count_criteria = 11; + * + * @param value The bytes for visitCountCriteria to set. + * @return This builder for chaining. + */ + public Builder setVisitCountCriteriaBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + visitCountCriteria_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + private java.lang.Object indexedContent_ = ""; + + /** + * + * + *
+     * Represents the textual content of a web page. This field should be kept
+     * short. Large strings may affect latency and payload sizes.
+     * 
+ * + * string indexed_content = 12; + * + * @return The indexedContent. + */ + public java.lang.String getIndexedContent() { + java.lang.Object ref = indexedContent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + indexedContent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Represents the textual content of a web page. This field should be kept
+     * short. Large strings may affect latency and payload sizes.
+     * 
+ * + * string indexed_content = 12; + * + * @return The bytes for indexedContent. + */ + public com.google.protobuf.ByteString getIndexedContentBytes() { + java.lang.Object ref = indexedContent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + indexedContent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Represents the textual content of a web page. This field should be kept
+     * short. Large strings may affect latency and payload sizes.
+     * 
+ * + * string indexed_content = 12; + * + * @param value The indexedContent to set. + * @return This builder for chaining. + */ + public Builder setIndexedContent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + indexedContent_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Represents the textual content of a web page. This field should be kept
+     * short. Large strings may affect latency and payload sizes.
+     * 
+ * + * string indexed_content = 12; + * + * @return This builder for chaining. + */ + public Builder clearIndexedContent() { + indexedContent_ = getDefaultInstance().getIndexedContent(); + bitField0_ = (bitField0_ & ~0x00000800); + onChanged(); + return this; + } + + /** + * + * + *
+     * Represents the textual content of a web page. This field should be kept
+     * short. Large strings may affect latency and payload sizes.
+     * 
+ * + * string indexed_content = 12; + * + * @param value The bytes for indexedContent to set. + * @return This builder for chaining. + */ + public Builder setIndexedContentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + indexedContent_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp firstBookmarkedTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + firstBookmarkedTimeBuilder_; + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + * + * @return Whether the firstBookmarkedTime field is set. + */ + public boolean hasFirstBookmarkedTime() { + return ((bitField0_ & 0x00001000) != 0); + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + * + * @return The firstBookmarkedTime. + */ + public com.google.protobuf.Timestamp getFirstBookmarkedTime() { + if (firstBookmarkedTimeBuilder_ == null) { + return firstBookmarkedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstBookmarkedTime_; + } else { + return firstBookmarkedTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + public Builder setFirstBookmarkedTime(com.google.protobuf.Timestamp value) { + if (firstBookmarkedTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + firstBookmarkedTime_ = value; + } else { + firstBookmarkedTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + public Builder setFirstBookmarkedTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (firstBookmarkedTimeBuilder_ == null) { + firstBookmarkedTime_ = builderForValue.build(); + } else { + firstBookmarkedTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + public Builder mergeFirstBookmarkedTime(com.google.protobuf.Timestamp value) { + if (firstBookmarkedTimeBuilder_ == null) { + if (((bitField0_ & 0x00001000) != 0) + && firstBookmarkedTime_ != null + && firstBookmarkedTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getFirstBookmarkedTimeBuilder().mergeFrom(value); + } else { + firstBookmarkedTime_ = value; + } + } else { + firstBookmarkedTimeBuilder_.mergeFrom(value); + } + if (firstBookmarkedTime_ != null) { + bitField0_ |= 0x00001000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + public Builder clearFirstBookmarkedTime() { + bitField0_ = (bitField0_ & ~0x00001000); + firstBookmarkedTime_ = null; + if (firstBookmarkedTimeBuilder_ != null) { + firstBookmarkedTimeBuilder_.dispose(); + firstBookmarkedTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + public com.google.protobuf.Timestamp.Builder getFirstBookmarkedTimeBuilder() { + bitField0_ |= 0x00001000; + onChanged(); + return internalGetFirstBookmarkedTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + public com.google.protobuf.TimestampOrBuilder getFirstBookmarkedTimeOrBuilder() { + if (firstBookmarkedTimeBuilder_ != null) { + return firstBookmarkedTimeBuilder_.getMessageOrBuilder(); + } else { + return firstBookmarkedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : firstBookmarkedTime_; + } + } + + /** + * + * + *
+     * The timestamp indicating the first time the URL was bookmarked.
+     * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetFirstBookmarkedTimeFieldBuilder() { + if (firstBookmarkedTimeBuilder_ == null) { + firstBookmarkedTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getFirstBookmarkedTime(), getParentForChildren(), isClean()); + firstBookmarkedTime_ = null; + } + return firstBookmarkedTimeBuilder_; + } + + private java.util.List cookies_ = + java.util.Collections.emptyList(); + + private void ensureCookiesIsMutable() { + if (!((bitField0_ & 0x00002000) != 0)) { + cookies_ = new java.util.ArrayList(cookies_); + bitField0_ |= 0x00002000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Browser.Cookie, + com.google.backstory.Browser.Cookie.Builder, + com.google.backstory.Browser.CookieOrBuilder> + cookiesBuilder_; + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public java.util.List getCookiesList() { + if (cookiesBuilder_ == null) { + return java.util.Collections.unmodifiableList(cookies_); + } else { + return cookiesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public int getCookiesCount() { + if (cookiesBuilder_ == null) { + return cookies_.size(); + } else { + return cookiesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public com.google.backstory.Browser.Cookie getCookies(int index) { + if (cookiesBuilder_ == null) { + return cookies_.get(index); + } else { + return cookiesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder setCookies(int index, com.google.backstory.Browser.Cookie value) { + if (cookiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCookiesIsMutable(); + cookies_.set(index, value); + onChanged(); + } else { + cookiesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder setCookies( + int index, com.google.backstory.Browser.Cookie.Builder builderForValue) { + if (cookiesBuilder_ == null) { + ensureCookiesIsMutable(); + cookies_.set(index, builderForValue.build()); + onChanged(); + } else { + cookiesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder addCookies(com.google.backstory.Browser.Cookie value) { + if (cookiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCookiesIsMutable(); + cookies_.add(value); + onChanged(); + } else { + cookiesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder addCookies(int index, com.google.backstory.Browser.Cookie value) { + if (cookiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCookiesIsMutable(); + cookies_.add(index, value); + onChanged(); + } else { + cookiesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder addCookies(com.google.backstory.Browser.Cookie.Builder builderForValue) { + if (cookiesBuilder_ == null) { + ensureCookiesIsMutable(); + cookies_.add(builderForValue.build()); + onChanged(); + } else { + cookiesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder addCookies( + int index, com.google.backstory.Browser.Cookie.Builder builderForValue) { + if (cookiesBuilder_ == null) { + ensureCookiesIsMutable(); + cookies_.add(index, builderForValue.build()); + onChanged(); + } else { + cookiesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder addAllCookies( + java.lang.Iterable values) { + if (cookiesBuilder_ == null) { + ensureCookiesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, cookies_); + onChanged(); + } else { + cookiesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder clearCookies() { + if (cookiesBuilder_ == null) { + cookies_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00002000); + onChanged(); + } else { + cookiesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public Builder removeCookies(int index) { + if (cookiesBuilder_ == null) { + ensureCookiesIsMutable(); + cookies_.remove(index); + onChanged(); + } else { + cookiesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public com.google.backstory.Browser.Cookie.Builder getCookiesBuilder(int index) { + return internalGetCookiesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public com.google.backstory.Browser.CookieOrBuilder getCookiesOrBuilder(int index) { + if (cookiesBuilder_ == null) { + return cookies_.get(index); + } else { + return cookiesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public java.util.List + getCookiesOrBuilderList() { + if (cookiesBuilder_ != null) { + return cookiesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(cookies_); + } + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public com.google.backstory.Browser.Cookie.Builder addCookiesBuilder() { + return internalGetCookiesFieldBuilder() + .addBuilder(com.google.backstory.Browser.Cookie.getDefaultInstance()); + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public com.google.backstory.Browser.Cookie.Builder addCookiesBuilder(int index) { + return internalGetCookiesFieldBuilder() + .addBuilder(index, com.google.backstory.Browser.Cookie.getDefaultInstance()); + } + + /** + * + * + *
+     * Information about the cookies.
+     * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + public java.util.List getCookiesBuilderList() { + return internalGetCookiesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Browser.Cookie, + com.google.backstory.Browser.Cookie.Builder, + com.google.backstory.Browser.CookieOrBuilder> + internalGetCookiesFieldBuilder() { + if (cookiesBuilder_ == null) { + cookiesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Browser.Cookie, + com.google.backstory.Browser.Cookie.Builder, + com.google.backstory.Browser.CookieOrBuilder>( + cookies_, ((bitField0_ & 0x00002000) != 0), getParentForChildren(), isClean()); + cookies_ = null; + } + return cookiesBuilder_; + } + + private long typedCount_; + + /** + * + * + *
+     * The number of times the URL was visited with this specific visit type and
+     * visit source.
+     * 
+ * + * int64 typed_count = 15; + * + * @return The typedCount. + */ + @java.lang.Override + public long getTypedCount() { + return typedCount_; + } + + /** + * + * + *
+     * The number of times the URL was visited with this specific visit type and
+     * visit source.
+     * 
+ * + * int64 typed_count = 15; + * + * @param value The typedCount to set. + * @return This builder for chaining. + */ + public Builder setTypedCount(long value) { + + typedCount_ = value; + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The number of times the URL was visited with this specific visit type and
+     * visit source.
+     * 
+ * + * int64 typed_count = 15; + * + * @return This builder for chaining. + */ + public Builder clearTypedCount() { + bitField0_ = (bitField0_ & ~0x00004000); + typedCount_ = 0L; + onChanged(); + return this; + } + + private int visitSource_ = 0; + + /** + * + * + *
+     * The source of the visit.
+     * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return The enum numeric value on the wire for visitSource. + */ + @java.lang.Override + public int getVisitSourceValue() { + return visitSource_; + } + + /** + * + * + *
+     * The source of the visit.
+     * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @param value The enum numeric value on the wire for visitSource to set. + * @return This builder for chaining. + */ + public Builder setVisitSourceValue(int value) { + visitSource_ = value; + bitField0_ |= 0x00008000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The source of the visit.
+     * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return The visitSource. + */ + @java.lang.Override + public com.google.backstory.Browser.VisitSource getVisitSource() { + com.google.backstory.Browser.VisitSource result = + com.google.backstory.Browser.VisitSource.forNumber(visitSource_); + return result == null ? com.google.backstory.Browser.VisitSource.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The source of the visit.
+     * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @param value The visitSource to set. + * @return This builder for chaining. + */ + public Builder setVisitSource(com.google.backstory.Browser.VisitSource value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00008000; + visitSource_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The source of the visit.
+     * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return This builder for chaining. + */ + public Builder clearVisitSource() { + bitField0_ = (bitField0_ & ~0x00008000); + visitSource_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Browser) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Browser) + private static final com.google.backstory.Browser DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Browser(); + } + + public static com.google.backstory.Browser getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Browser parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Browser getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java new file mode 100644 index 000000000000..58064376bd24 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java @@ -0,0 +1,444 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface BrowserOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Browser) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+   * "Safari", etc.).
+   * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return The enum numeric value on the wire for browserType. + */ + int getBrowserTypeValue(); + + /** + * + * + *
+   * The browser that recorded the history entry (e.g. "Chrome", "Firefox",
+   * "Safari", etc.).
+   * 
+ * + * .google.backstory.Browser.BrowserType browser_type = 1; + * + * @return The browserType. + */ + com.google.backstory.Browser.BrowserType getBrowserType(); + + /** + * + * + *
+   * The browser version.
+   * 
+ * + * string browser_version = 2; + * + * @return The browserVersion. + */ + java.lang.String getBrowserVersion(); + + /** + * + * + *
+   * The browser version.
+   * 
+ * + * string browser_version = 2; + * + * @return The bytes for browserVersion. + */ + com.google.protobuf.ByteString getBrowserVersionBytes(); + + /** + * + * + *
+   * The timestamp indicating the initial visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + * + * @return Whether the firstVisitTime field is set. + */ + boolean hasFirstVisitTime(); + + /** + * + * + *
+   * The timestamp indicating the initial visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + * + * @return The firstVisitTime. + */ + com.google.protobuf.Timestamp getFirstVisitTime(); + + /** + * + * + *
+   * The timestamp indicating the initial visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp first_visit_time = 3; + */ + com.google.protobuf.TimestampOrBuilder getFirstVisitTimeOrBuilder(); + + /** + * + * + *
+   * The timestamp indicating the most recent visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + * + * @return Whether the lastVisitTime field is set. + */ + boolean hasLastVisitTime(); + + /** + * + * + *
+   * The timestamp indicating the most recent visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + * + * @return The lastVisitTime. + */ + com.google.protobuf.Timestamp getLastVisitTime(); + + /** + * + * + *
+   * The timestamp indicating the most recent visit to the URL.
+   * 
+ * + * .google.protobuf.Timestamp last_visit_time = 4; + */ + com.google.protobuf.TimestampOrBuilder getLastVisitTimeOrBuilder(); + + /** + * + * + *
+   * The browser profile associated with the history entry.
+   * 
+ * + * string profile = 5; + * + * @return The profile. + */ + java.lang.String getProfile(); + + /** + * + * + *
+   * The browser profile associated with the history entry.
+   * 
+ * + * string profile = 5; + * + * @return The bytes for profile. + */ + com.google.protobuf.ByteString getProfileBytes(); + + /** + * + * + *
+   * A boolean value indicating if the URL was typed by the user.
+   * 
+ * + * bool typed = 6; + * + * @return The typed. + */ + boolean getTyped(); + + /** + * + * + *
+   * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+   * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return The enum numeric value on the wire for visitType. + */ + int getVisitTypeValue(); + + /** + * + * + *
+   * Describes the type of navigation or visit (e.g., direct, redirect, etc.).
+   * 
+ * + * .google.backstory.Browser.UrlVisitType visit_type = 7; + * + * @return The visitType. + */ + com.google.backstory.Browser.UrlVisitType getVisitType(); + + /** + * + * + *
+   * A boolean value indicating if the history entry is hidden.
+   * 
+ * + * bool hidden = 8; + * + * @return The hidden. + */ + boolean getHidden(); + + /** + * + * + *
+   * Indicates the URI from which the current visit originated.
+   * 
+ * + * string request_origin_uri = 9; + * + * @return The requestOriginUri. + */ + java.lang.String getRequestOriginUri(); + + /** + * + * + *
+   * Indicates the URI from which the current visit originated.
+   * 
+ * + * string request_origin_uri = 9; + * + * @return The bytes for requestOriginUri. + */ + com.google.protobuf.ByteString getRequestOriginUriBytes(); + + /** + * + * + *
+   * The total number of times the Url has been visited.
+   * 
+ * + * int64 visit_count = 10; + * + * @return The visitCount. + */ + long getVisitCount(); + + /** + * + * + *
+   * Describes the criteria used to calculate the visit_count.
+   * 
+ * + * string visit_count_criteria = 11; + * + * @return The visitCountCriteria. + */ + java.lang.String getVisitCountCriteria(); + + /** + * + * + *
+   * Describes the criteria used to calculate the visit_count.
+   * 
+ * + * string visit_count_criteria = 11; + * + * @return The bytes for visitCountCriteria. + */ + com.google.protobuf.ByteString getVisitCountCriteriaBytes(); + + /** + * + * + *
+   * Represents the textual content of a web page. This field should be kept
+   * short. Large strings may affect latency and payload sizes.
+   * 
+ * + * string indexed_content = 12; + * + * @return The indexedContent. + */ + java.lang.String getIndexedContent(); + + /** + * + * + *
+   * Represents the textual content of a web page. This field should be kept
+   * short. Large strings may affect latency and payload sizes.
+   * 
+ * + * string indexed_content = 12; + * + * @return The bytes for indexedContent. + */ + com.google.protobuf.ByteString getIndexedContentBytes(); + + /** + * + * + *
+   * The timestamp indicating the first time the URL was bookmarked.
+   * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + * + * @return Whether the firstBookmarkedTime field is set. + */ + boolean hasFirstBookmarkedTime(); + + /** + * + * + *
+   * The timestamp indicating the first time the URL was bookmarked.
+   * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + * + * @return The firstBookmarkedTime. + */ + com.google.protobuf.Timestamp getFirstBookmarkedTime(); + + /** + * + * + *
+   * The timestamp indicating the first time the URL was bookmarked.
+   * 
+ * + * .google.protobuf.Timestamp first_bookmarked_time = 13; + */ + com.google.protobuf.TimestampOrBuilder getFirstBookmarkedTimeOrBuilder(); + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + java.util.List getCookiesList(); + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + com.google.backstory.Browser.Cookie getCookies(int index); + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + int getCookiesCount(); + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + java.util.List getCookiesOrBuilderList(); + + /** + * + * + *
+   * Information about the cookies.
+   * 
+ * + * repeated .google.backstory.Browser.Cookie cookies = 14; + */ + com.google.backstory.Browser.CookieOrBuilder getCookiesOrBuilder(int index); + + /** + * + * + *
+   * The number of times the URL was visited with this specific visit type and
+   * visit source.
+   * 
+ * + * int64 typed_count = 15; + * + * @return The typedCount. + */ + long getTypedCount(); + + /** + * + * + *
+   * The source of the visit.
+   * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return The enum numeric value on the wire for visitSource. + */ + int getVisitSourceValue(); + + /** + * + * + *
+   * The source of the visit.
+   * 
+ * + * .google.backstory.Browser.VisitSource visit_source = 16; + * + * @return The visitSource. + */ + com.google.backstory.Browser.VisitSource getVisitSource(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/BytesSequence.java b/java-backstory/src/main/java/com/google/backstory/BytesSequence.java new file mode 100644 index 000000000000..14a2950213bc --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/BytesSequence.java @@ -0,0 +1,621 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * BytesSequence represents a sequence of bytes.
+ * 
+ * + * Protobuf type {@code google.backstory.BytesSequence} + */ +@com.google.protobuf.Generated +public final class BytesSequence extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.BytesSequence) + BytesSequenceOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "BytesSequence"); + } + + // Use BytesSequence.newBuilder() to construct. + private BytesSequence(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private BytesSequence() { + bytesVals_ = emptyList(com.google.protobuf.ByteString.class); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_BytesSequence_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_BytesSequence_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.BytesSequence.class, + com.google.backstory.BytesSequence.Builder.class); + } + + public static final int BYTES_VALS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.ProtobufList bytesVals_ = + emptyList(com.google.protobuf.ByteString.class); + + /** + * + * + *
+   * bytes sequence.
+   * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return A list containing the bytesVals. + */ + @java.lang.Override + public java.util.List getBytesValsList() { + return bytesVals_; + } + + /** + * + * + *
+   * bytes sequence.
+   * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return The count of bytesVals. + */ + public int getBytesValsCount() { + return bytesVals_.size(); + } + + /** + * + * + *
+   * bytes sequence.
+   * 
+ * + * repeated bytes bytes_vals = 1; + * + * @param index The index of the element to return. + * @return The bytesVals at the given index. + */ + public com.google.protobuf.ByteString getBytesVals(int index) { + return bytesVals_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < bytesVals_.size(); i++) { + output.writeBytes(1, bytesVals_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < bytesVals_.size(); i++) { + dataSize += com.google.protobuf.CodedOutputStream.computeBytesSizeNoTag(bytesVals_.get(i)); + } + size += dataSize; + size += 1 * getBytesValsList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.BytesSequence)) { + return super.equals(obj); + } + com.google.backstory.BytesSequence other = (com.google.backstory.BytesSequence) obj; + + if (!getBytesValsList().equals(other.getBytesValsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getBytesValsCount() > 0) { + hash = (37 * hash) + BYTES_VALS_FIELD_NUMBER; + hash = (53 * hash) + getBytesValsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.BytesSequence parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.BytesSequence parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.BytesSequence parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.BytesSequence parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.BytesSequence parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.BytesSequence parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.BytesSequence parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.BytesSequence parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.BytesSequence parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.BytesSequence parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.BytesSequence parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.BytesSequence parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.BytesSequence prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * BytesSequence represents a sequence of bytes.
+   * 
+ * + * Protobuf type {@code google.backstory.BytesSequence} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.BytesSequence) + com.google.backstory.BytesSequenceOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_BytesSequence_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_BytesSequence_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.BytesSequence.class, + com.google.backstory.BytesSequence.Builder.class); + } + + // Construct using com.google.backstory.BytesSequence.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + bytesVals_ = emptyList(com.google.protobuf.ByteString.class); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_BytesSequence_descriptor; + } + + @java.lang.Override + public com.google.backstory.BytesSequence getDefaultInstanceForType() { + return com.google.backstory.BytesSequence.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.BytesSequence build() { + com.google.backstory.BytesSequence result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.BytesSequence buildPartial() { + com.google.backstory.BytesSequence result = new com.google.backstory.BytesSequence(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.BytesSequence result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + bytesVals_.makeImmutable(); + result.bytesVals_ = bytesVals_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.BytesSequence) { + return mergeFrom((com.google.backstory.BytesSequence) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.BytesSequence other) { + if (other == com.google.backstory.BytesSequence.getDefaultInstance()) return this; + if (!other.bytesVals_.isEmpty()) { + if (bytesVals_.isEmpty()) { + bytesVals_ = other.bytesVals_; + bytesVals_.makeImmutable(); + bitField0_ |= 0x00000001; + } else { + ensureBytesValsIsMutable(); + bytesVals_.addAll(other.bytesVals_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.protobuf.ByteString v = input.readBytes(); + ensureBytesValsIsMutable(); + bytesVals_.add(v); + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.Internal.ProtobufList bytesVals_ = + emptyList(com.google.protobuf.ByteString.class); + + private void ensureBytesValsIsMutable() { + if (!bytesVals_.isModifiable()) { + bytesVals_ = makeMutableCopy(bytesVals_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return A list containing the bytesVals. + */ + public java.util.List getBytesValsList() { + bytesVals_.makeImmutable(); + return bytesVals_; + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return The count of bytesVals. + */ + public int getBytesValsCount() { + return bytesVals_.size(); + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @param index The index of the element to return. + * @return The bytesVals at the given index. + */ + public com.google.protobuf.ByteString getBytesVals(int index) { + return bytesVals_.get(index); + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @param index The index to set the value at. + * @param value The bytesVals to set. + * @return This builder for chaining. + */ + public Builder setBytesVals(int index, com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + ensureBytesValsIsMutable(); + bytesVals_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @param value The bytesVals to add. + * @return This builder for chaining. + */ + public Builder addBytesVals(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + ensureBytesValsIsMutable(); + bytesVals_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @param values The bytesVals to add. + * @return This builder for chaining. + */ + public Builder addAllBytesVals( + java.lang.Iterable values) { + ensureBytesValsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, bytesVals_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * bytes sequence.
+     * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return This builder for chaining. + */ + public Builder clearBytesVals() { + bytesVals_ = emptyList(com.google.protobuf.ByteString.class); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.BytesSequence) + } + + // @@protoc_insertion_point(class_scope:google.backstory.BytesSequence) + private static final com.google.backstory.BytesSequence DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.BytesSequence(); + } + + public static com.google.backstory.BytesSequence getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BytesSequence parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.BytesSequence getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java new file mode 100644 index 000000000000..b79712afbe3e --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java @@ -0,0 +1,53 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface BytesSequenceOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.BytesSequence) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * bytes sequence.
+   * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return A list containing the bytesVals. + */ + java.util.List getBytesValsList(); + + /** + * + * + *
+   * bytes sequence.
+   * 
+ * + * repeated bytes bytes_vals = 1; + * + * @return The count of bytesVals. + */ + int getBytesValsCount(); + + /** + * + * + *
+   * bytes sequence.
+   * 
+ * + * repeated bytes bytes_vals = 1; + * + * @param index The index of the element to return. + * @return The bytesVals at the given index. + */ + com.google.protobuf.ByteString getBytesVals(int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Certificate.java b/java-backstory/src/main/java/com/google/backstory/Certificate.java new file mode 100644 index 000000000000..b4b79c231062 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Certificate.java @@ -0,0 +1,2263 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Certificate information
+ * 
+ * + * Protobuf type {@code google.backstory.Certificate} + */ +@com.google.protobuf.Generated +public final class Certificate extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Certificate) + CertificateOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Certificate"); + } + + // Use Certificate.newBuilder() to construct. + private Certificate(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Certificate() { + version_ = ""; + serial_ = ""; + subject_ = ""; + issuer_ = ""; + md5_ = ""; + sha1_ = ""; + sha256_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Certificate_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Certificate_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Certificate.class, com.google.backstory.Certificate.Builder.class); + } + + private int bitField0_; + public static final int VERSION_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object version_ = ""; + + /** + * + * + *
+   * Certificate version.
+   * 
+ * + * string version = 1; + * + * @return The version. + */ + @java.lang.Override + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } + } + + /** + * + * + *
+   * Certificate version.
+   * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SERIAL_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object serial_ = ""; + + /** + * + * + *
+   * Certificate serial number.
+   * 
+ * + * string serial = 2; + * + * @return The serial. + */ + @java.lang.Override + public java.lang.String getSerial() { + java.lang.Object ref = serial_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + serial_ = s; + return s; + } + } + + /** + * + * + *
+   * Certificate serial number.
+   * 
+ * + * string serial = 2; + * + * @return The bytes for serial. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSerialBytes() { + java.lang.Object ref = serial_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + serial_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUBJECT_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object subject_ = ""; + + /** + * + * + *
+   * Subject of the certificate.
+   * 
+ * + * string subject = 3; + * + * @return The subject. + */ + @java.lang.Override + public java.lang.String getSubject() { + java.lang.Object ref = subject_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subject_ = s; + return s; + } + } + + /** + * + * + *
+   * Subject of the certificate.
+   * 
+ * + * string subject = 3; + * + * @return The bytes for subject. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSubjectBytes() { + java.lang.Object ref = subject_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ISSUER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object issuer_ = ""; + + /** + * + * + *
+   * Issuer of the certificate.
+   * 
+ * + * string issuer = 4; + * + * @return The issuer. + */ + @java.lang.Override + public java.lang.String getIssuer() { + java.lang.Object ref = issuer_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + issuer_ = s; + return s; + } + } + + /** + * + * + *
+   * Issuer of the certificate.
+   * 
+ * + * string issuer = 4; + * + * @return The bytes for issuer. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIssuerBytes() { + java.lang.Object ref = issuer_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + issuer_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int MD5_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object md5_ = ""; + + /** + * + * + *
+   * The MD5 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string md5 = 5; + * + * @return The md5. + */ + @java.lang.Override + public java.lang.String getMd5() { + java.lang.Object ref = md5_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + md5_ = s; + return s; + } + } + + /** + * + * + *
+   * The MD5 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string md5 = 5; + * + * @return The bytes for md5. + */ + @java.lang.Override + public com.google.protobuf.ByteString getMd5Bytes() { + java.lang.Object ref = md5_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + md5_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SHA1_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object sha1_ = ""; + + /** + * + * + *
+   * The SHA1 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha1 = 6; + * + * @return The sha1. + */ + @java.lang.Override + public java.lang.String getSha1() { + java.lang.Object ref = sha1_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sha1_ = s; + return s; + } + } + + /** + * + * + *
+   * The SHA1 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha1 = 6; + * + * @return The bytes for sha1. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSha1Bytes() { + java.lang.Object ref = sha1_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sha1_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SHA256_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object sha256_ = ""; + + /** + * + * + *
+   * The SHA256 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha256 = 7; + * + * @return The sha256. + */ + @java.lang.Override + public java.lang.String getSha256() { + java.lang.Object ref = sha256_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sha256_ = s; + return s; + } + } + + /** + * + * + *
+   * The SHA256 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha256 = 7; + * + * @return The bytes for sha256. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSha256Bytes() { + java.lang.Object ref = sha256_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sha256_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int NOT_BEFORE_FIELD_NUMBER = 8; + private com.google.protobuf.Timestamp notBefore_; + + /** + * + * + *
+   * Indicates when the certificate is first valid.
+   * 
+ * + * .google.protobuf.Timestamp not_before = 8; + * + * @return Whether the notBefore field is set. + */ + @java.lang.Override + public boolean hasNotBefore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Indicates when the certificate is first valid.
+   * 
+ * + * .google.protobuf.Timestamp not_before = 8; + * + * @return The notBefore. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getNotBefore() { + return notBefore_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notBefore_; + } + + /** + * + * + *
+   * Indicates when the certificate is first valid.
+   * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getNotBeforeOrBuilder() { + return notBefore_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notBefore_; + } + + public static final int NOT_AFTER_FIELD_NUMBER = 9; + private com.google.protobuf.Timestamp notAfter_; + + /** + * + * + *
+   * Indicates when the certificate is no longer valid.
+   * 
+ * + * .google.protobuf.Timestamp not_after = 9; + * + * @return Whether the notAfter field is set. + */ + @java.lang.Override + public boolean hasNotAfter() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Indicates when the certificate is no longer valid.
+   * 
+ * + * .google.protobuf.Timestamp not_after = 9; + * + * @return The notAfter. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getNotAfter() { + return notAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notAfter_; + } + + /** + * + * + *
+   * Indicates when the certificate is no longer valid.
+   * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getNotAfterOrBuilder() { + return notAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notAfter_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, version_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(serial_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, serial_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(subject_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, subject_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(issuer_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, issuer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(md5_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, md5_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sha1_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, sha1_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sha256_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, sha256_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(8, getNotBefore()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(9, getNotAfter()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(version_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, version_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(serial_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, serial_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(subject_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, subject_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(issuer_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, issuer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(md5_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, md5_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sha1_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, sha1_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sha256_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(7, sha256_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getNotBefore()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getNotAfter()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Certificate)) { + return super.equals(obj); + } + com.google.backstory.Certificate other = (com.google.backstory.Certificate) obj; + + if (!getVersion().equals(other.getVersion())) return false; + if (!getSerial().equals(other.getSerial())) return false; + if (!getSubject().equals(other.getSubject())) return false; + if (!getIssuer().equals(other.getIssuer())) return false; + if (!getMd5().equals(other.getMd5())) return false; + if (!getSha1().equals(other.getSha1())) return false; + if (!getSha256().equals(other.getSha256())) return false; + if (hasNotBefore() != other.hasNotBefore()) return false; + if (hasNotBefore()) { + if (!getNotBefore().equals(other.getNotBefore())) return false; + } + if (hasNotAfter() != other.hasNotAfter()) return false; + if (hasNotAfter()) { + if (!getNotAfter().equals(other.getNotAfter())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + hash = (37 * hash) + SERIAL_FIELD_NUMBER; + hash = (53 * hash) + getSerial().hashCode(); + hash = (37 * hash) + SUBJECT_FIELD_NUMBER; + hash = (53 * hash) + getSubject().hashCode(); + hash = (37 * hash) + ISSUER_FIELD_NUMBER; + hash = (53 * hash) + getIssuer().hashCode(); + hash = (37 * hash) + MD5_FIELD_NUMBER; + hash = (53 * hash) + getMd5().hashCode(); + hash = (37 * hash) + SHA1_FIELD_NUMBER; + hash = (53 * hash) + getSha1().hashCode(); + hash = (37 * hash) + SHA256_FIELD_NUMBER; + hash = (53 * hash) + getSha256().hashCode(); + if (hasNotBefore()) { + hash = (37 * hash) + NOT_BEFORE_FIELD_NUMBER; + hash = (53 * hash) + getNotBefore().hashCode(); + } + if (hasNotAfter()) { + hash = (37 * hash) + NOT_AFTER_FIELD_NUMBER; + hash = (53 * hash) + getNotAfter().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Certificate parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Certificate parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Certificate parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Certificate parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Certificate parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Certificate parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Certificate parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Certificate parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Certificate parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Certificate parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Certificate parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Certificate parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Certificate prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Certificate information
+   * 
+ * + * Protobuf type {@code google.backstory.Certificate} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Certificate) + com.google.backstory.CertificateOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Certificate_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Certificate_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Certificate.class, + com.google.backstory.Certificate.Builder.class); + } + + // Construct using com.google.backstory.Certificate.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetNotBeforeFieldBuilder(); + internalGetNotAfterFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + version_ = ""; + serial_ = ""; + subject_ = ""; + issuer_ = ""; + md5_ = ""; + sha1_ = ""; + sha256_ = ""; + notBefore_ = null; + if (notBeforeBuilder_ != null) { + notBeforeBuilder_.dispose(); + notBeforeBuilder_ = null; + } + notAfter_ = null; + if (notAfterBuilder_ != null) { + notAfterBuilder_.dispose(); + notAfterBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Certificate_descriptor; + } + + @java.lang.Override + public com.google.backstory.Certificate getDefaultInstanceForType() { + return com.google.backstory.Certificate.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Certificate build() { + com.google.backstory.Certificate result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Certificate buildPartial() { + com.google.backstory.Certificate result = new com.google.backstory.Certificate(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.Certificate result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.version_ = version_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.serial_ = serial_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.subject_ = subject_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.issuer_ = issuer_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.md5_ = md5_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.sha1_ = sha1_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.sha256_ = sha256_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000080) != 0)) { + result.notBefore_ = notBeforeBuilder_ == null ? notBefore_ : notBeforeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.notAfter_ = notAfterBuilder_ == null ? notAfter_ : notAfterBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Certificate) { + return mergeFrom((com.google.backstory.Certificate) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Certificate other) { + if (other == com.google.backstory.Certificate.getDefaultInstance()) return this; + if (!other.getVersion().isEmpty()) { + version_ = other.version_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSerial().isEmpty()) { + serial_ = other.serial_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getSubject().isEmpty()) { + subject_ = other.subject_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getIssuer().isEmpty()) { + issuer_ = other.issuer_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getMd5().isEmpty()) { + md5_ = other.md5_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (!other.getSha1().isEmpty()) { + sha1_ = other.sha1_; + bitField0_ |= 0x00000020; + onChanged(); + } + if (!other.getSha256().isEmpty()) { + sha256_ = other.sha256_; + bitField0_ |= 0x00000040; + onChanged(); + } + if (other.hasNotBefore()) { + mergeNotBefore(other.getNotBefore()); + } + if (other.hasNotAfter()) { + mergeNotAfter(other.getNotAfter()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + version_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + serial_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + subject_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + issuer_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + md5_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + sha1_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 58: + { + sha256_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 66: + { + input.readMessage( + internalGetNotBeforeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000080; + break; + } // case 66 + case 74: + { + input.readMessage( + internalGetNotAfterFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object version_ = ""; + + /** + * + * + *
+     * Certificate version.
+     * 
+ * + * string version = 1; + * + * @return The version. + */ + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Certificate version.
+     * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Certificate version.
+     * 
+ * + * string version = 1; + * + * @param value The version to set. + * @return This builder for chaining. + */ + public Builder setVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + version_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Certificate version.
+     * 
+ * + * string version = 1; + * + * @return This builder for chaining. + */ + public Builder clearVersion() { + version_ = getDefaultInstance().getVersion(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Certificate version.
+     * 
+ * + * string version = 1; + * + * @param value The bytes for version to set. + * @return This builder for chaining. + */ + public Builder setVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + version_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object serial_ = ""; + + /** + * + * + *
+     * Certificate serial number.
+     * 
+ * + * string serial = 2; + * + * @return The serial. + */ + public java.lang.String getSerial() { + java.lang.Object ref = serial_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + serial_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Certificate serial number.
+     * 
+ * + * string serial = 2; + * + * @return The bytes for serial. + */ + public com.google.protobuf.ByteString getSerialBytes() { + java.lang.Object ref = serial_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + serial_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Certificate serial number.
+     * 
+ * + * string serial = 2; + * + * @param value The serial to set. + * @return This builder for chaining. + */ + public Builder setSerial(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + serial_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Certificate serial number.
+     * 
+ * + * string serial = 2; + * + * @return This builder for chaining. + */ + public Builder clearSerial() { + serial_ = getDefaultInstance().getSerial(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Certificate serial number.
+     * 
+ * + * string serial = 2; + * + * @param value The bytes for serial to set. + * @return This builder for chaining. + */ + public Builder setSerialBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + serial_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object subject_ = ""; + + /** + * + * + *
+     * Subject of the certificate.
+     * 
+ * + * string subject = 3; + * + * @return The subject. + */ + public java.lang.String getSubject() { + java.lang.Object ref = subject_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subject_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Subject of the certificate.
+     * 
+ * + * string subject = 3; + * + * @return The bytes for subject. + */ + public com.google.protobuf.ByteString getSubjectBytes() { + java.lang.Object ref = subject_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Subject of the certificate.
+     * 
+ * + * string subject = 3; + * + * @param value The subject to set. + * @return This builder for chaining. + */ + public Builder setSubject(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + subject_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Subject of the certificate.
+     * 
+ * + * string subject = 3; + * + * @return This builder for chaining. + */ + public Builder clearSubject() { + subject_ = getDefaultInstance().getSubject(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Subject of the certificate.
+     * 
+ * + * string subject = 3; + * + * @param value The bytes for subject to set. + * @return This builder for chaining. + */ + public Builder setSubjectBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + subject_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object issuer_ = ""; + + /** + * + * + *
+     * Issuer of the certificate.
+     * 
+ * + * string issuer = 4; + * + * @return The issuer. + */ + public java.lang.String getIssuer() { + java.lang.Object ref = issuer_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + issuer_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Issuer of the certificate.
+     * 
+ * + * string issuer = 4; + * + * @return The bytes for issuer. + */ + public com.google.protobuf.ByteString getIssuerBytes() { + java.lang.Object ref = issuer_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + issuer_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Issuer of the certificate.
+     * 
+ * + * string issuer = 4; + * + * @param value The issuer to set. + * @return This builder for chaining. + */ + public Builder setIssuer(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + issuer_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Issuer of the certificate.
+     * 
+ * + * string issuer = 4; + * + * @return This builder for chaining. + */ + public Builder clearIssuer() { + issuer_ = getDefaultInstance().getIssuer(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Issuer of the certificate.
+     * 
+ * + * string issuer = 4; + * + * @param value The bytes for issuer to set. + * @return This builder for chaining. + */ + public Builder setIssuerBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + issuer_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object md5_ = ""; + + /** + * + * + *
+     * The MD5 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string md5 = 5; + * + * @return The md5. + */ + public java.lang.String getMd5() { + java.lang.Object ref = md5_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + md5_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The MD5 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string md5 = 5; + * + * @return The bytes for md5. + */ + public com.google.protobuf.ByteString getMd5Bytes() { + java.lang.Object ref = md5_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + md5_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The MD5 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string md5 = 5; + * + * @param value The md5 to set. + * @return This builder for chaining. + */ + public Builder setMd5(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + md5_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * The MD5 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string md5 = 5; + * + * @return This builder for chaining. + */ + public Builder clearMd5() { + md5_ = getDefaultInstance().getMd5(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * The MD5 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string md5 = 5; + * + * @param value The bytes for md5 to set. + * @return This builder for chaining. + */ + public Builder setMd5Bytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + md5_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private java.lang.Object sha1_ = ""; + + /** + * + * + *
+     * The SHA1 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha1 = 6; + * + * @return The sha1. + */ + public java.lang.String getSha1() { + java.lang.Object ref = sha1_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sha1_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The SHA1 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha1 = 6; + * + * @return The bytes for sha1. + */ + public com.google.protobuf.ByteString getSha1Bytes() { + java.lang.Object ref = sha1_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sha1_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The SHA1 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha1 = 6; + * + * @param value The sha1 to set. + * @return This builder for chaining. + */ + public Builder setSha1(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sha1_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * The SHA1 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha1 = 6; + * + * @return This builder for chaining. + */ + public Builder clearSha1() { + sha1_ = getDefaultInstance().getSha1(); + bitField0_ = (bitField0_ & ~0x00000020); + onChanged(); + return this; + } + + /** + * + * + *
+     * The SHA1 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha1 = 6; + * + * @param value The bytes for sha1 to set. + * @return This builder for chaining. + */ + public Builder setSha1Bytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sha1_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + private java.lang.Object sha256_ = ""; + + /** + * + * + *
+     * The SHA256 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha256 = 7; + * + * @return The sha256. + */ + public java.lang.String getSha256() { + java.lang.Object ref = sha256_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sha256_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The SHA256 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha256 = 7; + * + * @return The bytes for sha256. + */ + public com.google.protobuf.ByteString getSha256Bytes() { + java.lang.Object ref = sha256_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sha256_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The SHA256 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha256 = 7; + * + * @param value The sha256 to set. + * @return This builder for chaining. + */ + public Builder setSha256(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sha256_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * The SHA256 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha256 = 7; + * + * @return This builder for chaining. + */ + public Builder clearSha256() { + sha256_ = getDefaultInstance().getSha256(); + bitField0_ = (bitField0_ & ~0x00000040); + onChanged(); + return this; + } + + /** + * + * + *
+     * The SHA256 hash of the certificate, as a hex-encoded string.
+     * 
+ * + * string sha256 = 7; + * + * @param value The bytes for sha256 to set. + * @return This builder for chaining. + */ + public Builder setSha256Bytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sha256_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp notBefore_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + notBeforeBuilder_; + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + * + * @return Whether the notBefore field is set. + */ + public boolean hasNotBefore() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + * + * @return The notBefore. + */ + public com.google.protobuf.Timestamp getNotBefore() { + if (notBeforeBuilder_ == null) { + return notBefore_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notBefore_; + } else { + return notBeforeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + public Builder setNotBefore(com.google.protobuf.Timestamp value) { + if (notBeforeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + notBefore_ = value; + } else { + notBeforeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + public Builder setNotBefore(com.google.protobuf.Timestamp.Builder builderForValue) { + if (notBeforeBuilder_ == null) { + notBefore_ = builderForValue.build(); + } else { + notBeforeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + public Builder mergeNotBefore(com.google.protobuf.Timestamp value) { + if (notBeforeBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0) + && notBefore_ != null + && notBefore_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getNotBeforeBuilder().mergeFrom(value); + } else { + notBefore_ = value; + } + } else { + notBeforeBuilder_.mergeFrom(value); + } + if (notBefore_ != null) { + bitField0_ |= 0x00000080; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + public Builder clearNotBefore() { + bitField0_ = (bitField0_ & ~0x00000080); + notBefore_ = null; + if (notBeforeBuilder_ != null) { + notBeforeBuilder_.dispose(); + notBeforeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + public com.google.protobuf.Timestamp.Builder getNotBeforeBuilder() { + bitField0_ |= 0x00000080; + onChanged(); + return internalGetNotBeforeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + public com.google.protobuf.TimestampOrBuilder getNotBeforeOrBuilder() { + if (notBeforeBuilder_ != null) { + return notBeforeBuilder_.getMessageOrBuilder(); + } else { + return notBefore_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notBefore_; + } + } + + /** + * + * + *
+     * Indicates when the certificate is first valid.
+     * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetNotBeforeFieldBuilder() { + if (notBeforeBuilder_ == null) { + notBeforeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getNotBefore(), getParentForChildren(), isClean()); + notBefore_ = null; + } + return notBeforeBuilder_; + } + + private com.google.protobuf.Timestamp notAfter_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + notAfterBuilder_; + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + * + * @return Whether the notAfter field is set. + */ + public boolean hasNotAfter() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + * + * @return The notAfter. + */ + public com.google.protobuf.Timestamp getNotAfter() { + if (notAfterBuilder_ == null) { + return notAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notAfter_; + } else { + return notAfterBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + public Builder setNotAfter(com.google.protobuf.Timestamp value) { + if (notAfterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + notAfter_ = value; + } else { + notAfterBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + public Builder setNotAfter(com.google.protobuf.Timestamp.Builder builderForValue) { + if (notAfterBuilder_ == null) { + notAfter_ = builderForValue.build(); + } else { + notAfterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + public Builder mergeNotAfter(com.google.protobuf.Timestamp value) { + if (notAfterBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && notAfter_ != null + && notAfter_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getNotAfterBuilder().mergeFrom(value); + } else { + notAfter_ = value; + } + } else { + notAfterBuilder_.mergeFrom(value); + } + if (notAfter_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + public Builder clearNotAfter() { + bitField0_ = (bitField0_ & ~0x00000100); + notAfter_ = null; + if (notAfterBuilder_ != null) { + notAfterBuilder_.dispose(); + notAfterBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + public com.google.protobuf.Timestamp.Builder getNotAfterBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return internalGetNotAfterFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + public com.google.protobuf.TimestampOrBuilder getNotAfterOrBuilder() { + if (notAfterBuilder_ != null) { + return notAfterBuilder_.getMessageOrBuilder(); + } else { + return notAfter_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : notAfter_; + } + } + + /** + * + * + *
+     * Indicates when the certificate is no longer valid.
+     * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetNotAfterFieldBuilder() { + if (notAfterBuilder_ == null) { + notAfterBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getNotAfter(), getParentForChildren(), isClean()); + notAfter_ = null; + } + return notAfterBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Certificate) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Certificate) + private static final com.google.backstory.Certificate DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Certificate(); + } + + public static com.google.backstory.Certificate getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Certificate parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Certificate getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java new file mode 100644 index 000000000000..5f08623ce7b4 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java @@ -0,0 +1,269 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface CertificateOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Certificate) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Certificate version.
+   * 
+ * + * string version = 1; + * + * @return The version. + */ + java.lang.String getVersion(); + + /** + * + * + *
+   * Certificate version.
+   * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + com.google.protobuf.ByteString getVersionBytes(); + + /** + * + * + *
+   * Certificate serial number.
+   * 
+ * + * string serial = 2; + * + * @return The serial. + */ + java.lang.String getSerial(); + + /** + * + * + *
+   * Certificate serial number.
+   * 
+ * + * string serial = 2; + * + * @return The bytes for serial. + */ + com.google.protobuf.ByteString getSerialBytes(); + + /** + * + * + *
+   * Subject of the certificate.
+   * 
+ * + * string subject = 3; + * + * @return The subject. + */ + java.lang.String getSubject(); + + /** + * + * + *
+   * Subject of the certificate.
+   * 
+ * + * string subject = 3; + * + * @return The bytes for subject. + */ + com.google.protobuf.ByteString getSubjectBytes(); + + /** + * + * + *
+   * Issuer of the certificate.
+   * 
+ * + * string issuer = 4; + * + * @return The issuer. + */ + java.lang.String getIssuer(); + + /** + * + * + *
+   * Issuer of the certificate.
+   * 
+ * + * string issuer = 4; + * + * @return The bytes for issuer. + */ + com.google.protobuf.ByteString getIssuerBytes(); + + /** + * + * + *
+   * The MD5 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string md5 = 5; + * + * @return The md5. + */ + java.lang.String getMd5(); + + /** + * + * + *
+   * The MD5 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string md5 = 5; + * + * @return The bytes for md5. + */ + com.google.protobuf.ByteString getMd5Bytes(); + + /** + * + * + *
+   * The SHA1 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha1 = 6; + * + * @return The sha1. + */ + java.lang.String getSha1(); + + /** + * + * + *
+   * The SHA1 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha1 = 6; + * + * @return The bytes for sha1. + */ + com.google.protobuf.ByteString getSha1Bytes(); + + /** + * + * + *
+   * The SHA256 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha256 = 7; + * + * @return The sha256. + */ + java.lang.String getSha256(); + + /** + * + * + *
+   * The SHA256 hash of the certificate, as a hex-encoded string.
+   * 
+ * + * string sha256 = 7; + * + * @return The bytes for sha256. + */ + com.google.protobuf.ByteString getSha256Bytes(); + + /** + * + * + *
+   * Indicates when the certificate is first valid.
+   * 
+ * + * .google.protobuf.Timestamp not_before = 8; + * + * @return Whether the notBefore field is set. + */ + boolean hasNotBefore(); + + /** + * + * + *
+   * Indicates when the certificate is first valid.
+   * 
+ * + * .google.protobuf.Timestamp not_before = 8; + * + * @return The notBefore. + */ + com.google.protobuf.Timestamp getNotBefore(); + + /** + * + * + *
+   * Indicates when the certificate is first valid.
+   * 
+ * + * .google.protobuf.Timestamp not_before = 8; + */ + com.google.protobuf.TimestampOrBuilder getNotBeforeOrBuilder(); + + /** + * + * + *
+   * Indicates when the certificate is no longer valid.
+   * 
+ * + * .google.protobuf.Timestamp not_after = 9; + * + * @return Whether the notAfter field is set. + */ + boolean hasNotAfter(); + + /** + * + * + *
+   * Indicates when the certificate is no longer valid.
+   * 
+ * + * .google.protobuf.Timestamp not_after = 9; + * + * @return The notAfter. + */ + com.google.protobuf.Timestamp getNotAfter(); + + /** + * + * + *
+   * Indicates when the certificate is no longer valid.
+   * 
+ * + * .google.protobuf.Timestamp not_after = 9; + */ + com.google.protobuf.TimestampOrBuilder getNotAfterOrBuilder(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Cloud.java b/java-backstory/src/main/java/com/google/backstory/Cloud.java new file mode 100644 index 000000000000..1f9defe2c916 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Cloud.java @@ -0,0 +1,1537 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Metadata related to the cloud environment.
+ * 
+ * + * Protobuf type {@code google.backstory.Cloud} + */ +@com.google.protobuf.Generated +public final class Cloud extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Cloud) + CloudOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Cloud"); + } + + // Use Cloud.newBuilder() to construct. + private Cloud(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Cloud() { + environment_ = 0; + availabilityZone_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Cloud_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Cloud_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Cloud.class, com.google.backstory.Cloud.Builder.class); + } + + /** + * + * + *
+   * The service provider environment.
+   * 
+ * + * Protobuf enum {@code google.backstory.Cloud.CloudEnvironment} + */ + public enum CloudEnvironment implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default.
+     * 
+ * + * UNSPECIFIED_CLOUD_ENVIRONMENT = 0; + */ + UNSPECIFIED_CLOUD_ENVIRONMENT(0), + /** + * + * + *
+     * Google Cloud Platform.
+     * 
+ * + * GOOGLE_CLOUD_PLATFORM = 1; + */ + GOOGLE_CLOUD_PLATFORM(1), + /** + * + * + *
+     * Amazon Web Services.
+     * 
+ * + * AMAZON_WEB_SERVICES = 2; + */ + AMAZON_WEB_SERVICES(2), + /** + * + * + *
+     * Microsoft Azure.
+     * 
+ * + * MICROSOFT_AZURE = 3; + */ + MICROSOFT_AZURE(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "CloudEnvironment"); + } + + /** + * + * + *
+     * Default.
+     * 
+ * + * UNSPECIFIED_CLOUD_ENVIRONMENT = 0; + */ + public static final int UNSPECIFIED_CLOUD_ENVIRONMENT_VALUE = 0; + + /** + * + * + *
+     * Google Cloud Platform.
+     * 
+ * + * GOOGLE_CLOUD_PLATFORM = 1; + */ + public static final int GOOGLE_CLOUD_PLATFORM_VALUE = 1; + + /** + * + * + *
+     * Amazon Web Services.
+     * 
+ * + * AMAZON_WEB_SERVICES = 2; + */ + public static final int AMAZON_WEB_SERVICES_VALUE = 2; + + /** + * + * + *
+     * Microsoft Azure.
+     * 
+ * + * MICROSOFT_AZURE = 3; + */ + public static final int MICROSOFT_AZURE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static CloudEnvironment valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static CloudEnvironment forNumber(int value) { + switch (value) { + case 0: + return UNSPECIFIED_CLOUD_ENVIRONMENT; + case 1: + return GOOGLE_CLOUD_PLATFORM; + case 2: + return AMAZON_WEB_SERVICES; + case 3: + return MICROSOFT_AZURE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public CloudEnvironment findValueByNumber(int number) { + return CloudEnvironment.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Cloud.getDescriptor().getEnumTypes().get(0); + } + + private static final CloudEnvironment[] VALUES = values(); + + public static CloudEnvironment valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private CloudEnvironment(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Cloud.CloudEnvironment) + } + + private int bitField0_; + public static final int ENVIRONMENT_FIELD_NUMBER = 1; + private int environment_ = 0; + + /** + * + * + *
+   * The Cloud environment.
+   * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return The enum numeric value on the wire for environment. + */ + @java.lang.Override + public int getEnvironmentValue() { + return environment_; + } + + /** + * + * + *
+   * The Cloud environment.
+   * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return The environment. + */ + @java.lang.Override + public com.google.backstory.Cloud.CloudEnvironment getEnvironment() { + com.google.backstory.Cloud.CloudEnvironment result = + com.google.backstory.Cloud.CloudEnvironment.forNumber(environment_); + return result == null ? com.google.backstory.Cloud.CloudEnvironment.UNRECOGNIZED : result; + } + + public static final int VPC_FIELD_NUMBER = 2; + private com.google.backstory.Resource vpc_; + + /** + * + * + *
+   * The cloud environment VPC.
+   * Deprecated.
+   * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.vpc is deprecated. See backstory/udm.proto;l=5686 + * @return Whether the vpc field is set. + */ + @java.lang.Override + @java.lang.Deprecated + public boolean hasVpc() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The cloud environment VPC.
+   * Deprecated.
+   * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.vpc is deprecated. See backstory/udm.proto;l=5686 + * @return The vpc. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.backstory.Resource getVpc() { + return vpc_ == null ? com.google.backstory.Resource.getDefaultInstance() : vpc_; + } + + /** + * + * + *
+   * The cloud environment VPC.
+   * Deprecated.
+   * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.backstory.ResourceOrBuilder getVpcOrBuilder() { + return vpc_ == null ? com.google.backstory.Resource.getDefaultInstance() : vpc_; + } + + public static final int PROJECT_FIELD_NUMBER = 3; + private com.google.backstory.Resource project_; + + /** + * + * + *
+   * The cloud environment project information.
+   * Deprecated: Use Resource.resource_ancestors
+   * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.project is deprecated. See backstory/udm.proto;l=5690 + * @return Whether the project field is set. + */ + @java.lang.Override + @java.lang.Deprecated + public boolean hasProject() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The cloud environment project information.
+   * Deprecated: Use Resource.resource_ancestors
+   * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.project is deprecated. See backstory/udm.proto;l=5690 + * @return The project. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.backstory.Resource getProject() { + return project_ == null ? com.google.backstory.Resource.getDefaultInstance() : project_; + } + + /** + * + * + *
+   * The cloud environment project information.
+   * Deprecated: Use Resource.resource_ancestors
+   * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.backstory.ResourceOrBuilder getProjectOrBuilder() { + return project_ == null ? com.google.backstory.Resource.getDefaultInstance() : project_; + } + + public static final int AVAILABILITY_ZONE_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object availabilityZone_ = ""; + + /** + * + * + *
+   * The cloud environment availability zone (different from region which is
+   * location.name).
+   * 
+ * + * string availability_zone = 4; + * + * @return The availabilityZone. + */ + @java.lang.Override + public java.lang.String getAvailabilityZone() { + java.lang.Object ref = availabilityZone_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + availabilityZone_ = s; + return s; + } + } + + /** + * + * + *
+   * The cloud environment availability zone (different from region which is
+   * location.name).
+   * 
+ * + * string availability_zone = 4; + * + * @return The bytes for availabilityZone. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAvailabilityZoneBytes() { + java.lang.Object ref = availabilityZone_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + availabilityZone_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (environment_ + != com.google.backstory.Cloud.CloudEnvironment.UNSPECIFIED_CLOUD_ENVIRONMENT.getNumber()) { + output.writeEnum(1, environment_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getVpc()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(3, getProject()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(availabilityZone_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, availabilityZone_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (environment_ + != com.google.backstory.Cloud.CloudEnvironment.UNSPECIFIED_CLOUD_ENVIRONMENT.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, environment_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getVpc()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getProject()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(availabilityZone_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, availabilityZone_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Cloud)) { + return super.equals(obj); + } + com.google.backstory.Cloud other = (com.google.backstory.Cloud) obj; + + if (environment_ != other.environment_) return false; + if (hasVpc() != other.hasVpc()) return false; + if (hasVpc()) { + if (!getVpc().equals(other.getVpc())) return false; + } + if (hasProject() != other.hasProject()) return false; + if (hasProject()) { + if (!getProject().equals(other.getProject())) return false; + } + if (!getAvailabilityZone().equals(other.getAvailabilityZone())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ENVIRONMENT_FIELD_NUMBER; + hash = (53 * hash) + environment_; + if (hasVpc()) { + hash = (37 * hash) + VPC_FIELD_NUMBER; + hash = (53 * hash) + getVpc().hashCode(); + } + if (hasProject()) { + hash = (37 * hash) + PROJECT_FIELD_NUMBER; + hash = (53 * hash) + getProject().hashCode(); + } + hash = (37 * hash) + AVAILABILITY_ZONE_FIELD_NUMBER; + hash = (53 * hash) + getAvailabilityZone().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Cloud parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Cloud parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Cloud parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Cloud parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Cloud parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Cloud parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Cloud parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Cloud parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Cloud parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Cloud parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Cloud parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Cloud parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Cloud prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Metadata related to the cloud environment.
+   * 
+ * + * Protobuf type {@code google.backstory.Cloud} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Cloud) + com.google.backstory.CloudOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Cloud_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Cloud_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Cloud.class, com.google.backstory.Cloud.Builder.class); + } + + // Construct using com.google.backstory.Cloud.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetVpcFieldBuilder(); + internalGetProjectFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + environment_ = 0; + vpc_ = null; + if (vpcBuilder_ != null) { + vpcBuilder_.dispose(); + vpcBuilder_ = null; + } + project_ = null; + if (projectBuilder_ != null) { + projectBuilder_.dispose(); + projectBuilder_ = null; + } + availabilityZone_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Cloud_descriptor; + } + + @java.lang.Override + public com.google.backstory.Cloud getDefaultInstanceForType() { + return com.google.backstory.Cloud.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Cloud build() { + com.google.backstory.Cloud result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Cloud buildPartial() { + com.google.backstory.Cloud result = new com.google.backstory.Cloud(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.Cloud result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.environment_ = environment_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.vpc_ = vpcBuilder_ == null ? vpc_ : vpcBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.project_ = projectBuilder_ == null ? project_ : projectBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.availabilityZone_ = availabilityZone_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Cloud) { + return mergeFrom((com.google.backstory.Cloud) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Cloud other) { + if (other == com.google.backstory.Cloud.getDefaultInstance()) return this; + if (other.environment_ != 0) { + setEnvironmentValue(other.getEnvironmentValue()); + } + if (other.hasVpc()) { + mergeVpc(other.getVpc()); + } + if (other.hasProject()) { + mergeProject(other.getProject()); + } + if (!other.getAvailabilityZone().isEmpty()) { + availabilityZone_ = other.availabilityZone_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + environment_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + input.readMessage(internalGetVpcFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(internalGetProjectFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + availabilityZone_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int environment_ = 0; + + /** + * + * + *
+     * The Cloud environment.
+     * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return The enum numeric value on the wire for environment. + */ + @java.lang.Override + public int getEnvironmentValue() { + return environment_; + } + + /** + * + * + *
+     * The Cloud environment.
+     * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @param value The enum numeric value on the wire for environment to set. + * @return This builder for chaining. + */ + public Builder setEnvironmentValue(int value) { + environment_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The Cloud environment.
+     * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return The environment. + */ + @java.lang.Override + public com.google.backstory.Cloud.CloudEnvironment getEnvironment() { + com.google.backstory.Cloud.CloudEnvironment result = + com.google.backstory.Cloud.CloudEnvironment.forNumber(environment_); + return result == null ? com.google.backstory.Cloud.CloudEnvironment.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The Cloud environment.
+     * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @param value The environment to set. + * @return This builder for chaining. + */ + public Builder setEnvironment(com.google.backstory.Cloud.CloudEnvironment value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + environment_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The Cloud environment.
+     * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return This builder for chaining. + */ + public Builder clearEnvironment() { + bitField0_ = (bitField0_ & ~0x00000001); + environment_ = 0; + onChanged(); + return this; + } + + private com.google.backstory.Resource vpc_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Resource, + com.google.backstory.Resource.Builder, + com.google.backstory.ResourceOrBuilder> + vpcBuilder_; + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.vpc is deprecated. See backstory/udm.proto;l=5686 + * @return Whether the vpc field is set. + */ + @java.lang.Deprecated + public boolean hasVpc() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.vpc is deprecated. See backstory/udm.proto;l=5686 + * @return The vpc. + */ + @java.lang.Deprecated + public com.google.backstory.Resource getVpc() { + if (vpcBuilder_ == null) { + return vpc_ == null ? com.google.backstory.Resource.getDefaultInstance() : vpc_; + } else { + return vpcBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setVpc(com.google.backstory.Resource value) { + if (vpcBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + vpc_ = value; + } else { + vpcBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setVpc(com.google.backstory.Resource.Builder builderForValue) { + if (vpcBuilder_ == null) { + vpc_ = builderForValue.build(); + } else { + vpcBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder mergeVpc(com.google.backstory.Resource value) { + if (vpcBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && vpc_ != null + && vpc_ != com.google.backstory.Resource.getDefaultInstance()) { + getVpcBuilder().mergeFrom(value); + } else { + vpc_ = value; + } + } else { + vpcBuilder_.mergeFrom(value); + } + if (vpc_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder clearVpc() { + bitField0_ = (bitField0_ & ~0x00000002); + vpc_ = null; + if (vpcBuilder_ != null) { + vpcBuilder_.dispose(); + vpcBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.Resource.Builder getVpcBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetVpcFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.ResourceOrBuilder getVpcOrBuilder() { + if (vpcBuilder_ != null) { + return vpcBuilder_.getMessageOrBuilder(); + } else { + return vpc_ == null ? com.google.backstory.Resource.getDefaultInstance() : vpc_; + } + } + + /** + * + * + *
+     * The cloud environment VPC.
+     * Deprecated.
+     * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Resource, + com.google.backstory.Resource.Builder, + com.google.backstory.ResourceOrBuilder> + internalGetVpcFieldBuilder() { + if (vpcBuilder_ == null) { + vpcBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Resource, + com.google.backstory.Resource.Builder, + com.google.backstory.ResourceOrBuilder>( + getVpc(), getParentForChildren(), isClean()); + vpc_ = null; + } + return vpcBuilder_; + } + + private com.google.backstory.Resource project_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Resource, + com.google.backstory.Resource.Builder, + com.google.backstory.ResourceOrBuilder> + projectBuilder_; + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.project is deprecated. See backstory/udm.proto;l=5690 + * @return Whether the project field is set. + */ + @java.lang.Deprecated + public boolean hasProject() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.project is deprecated. See backstory/udm.proto;l=5690 + * @return The project. + */ + @java.lang.Deprecated + public com.google.backstory.Resource getProject() { + if (projectBuilder_ == null) { + return project_ == null ? com.google.backstory.Resource.getDefaultInstance() : project_; + } else { + return projectBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setProject(com.google.backstory.Resource value) { + if (projectBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + project_ = value; + } else { + projectBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder setProject(com.google.backstory.Resource.Builder builderForValue) { + if (projectBuilder_ == null) { + project_ = builderForValue.build(); + } else { + projectBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder mergeProject(com.google.backstory.Resource value) { + if (projectBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && project_ != null + && project_ != com.google.backstory.Resource.getDefaultInstance()) { + getProjectBuilder().mergeFrom(value); + } else { + project_ = value; + } + } else { + projectBuilder_.mergeFrom(value); + } + if (project_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + public Builder clearProject() { + bitField0_ = (bitField0_ & ~0x00000004); + project_ = null; + if (projectBuilder_ != null) { + projectBuilder_.dispose(); + projectBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.Resource.Builder getProjectBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetProjectFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + public com.google.backstory.ResourceOrBuilder getProjectOrBuilder() { + if (projectBuilder_ != null) { + return projectBuilder_.getMessageOrBuilder(); + } else { + return project_ == null ? com.google.backstory.Resource.getDefaultInstance() : project_; + } + } + + /** + * + * + *
+     * The cloud environment project information.
+     * Deprecated: Use Resource.resource_ancestors
+     * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Resource, + com.google.backstory.Resource.Builder, + com.google.backstory.ResourceOrBuilder> + internalGetProjectFieldBuilder() { + if (projectBuilder_ == null) { + projectBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Resource, + com.google.backstory.Resource.Builder, + com.google.backstory.ResourceOrBuilder>( + getProject(), getParentForChildren(), isClean()); + project_ = null; + } + return projectBuilder_; + } + + private java.lang.Object availabilityZone_ = ""; + + /** + * + * + *
+     * The cloud environment availability zone (different from region which is
+     * location.name).
+     * 
+ * + * string availability_zone = 4; + * + * @return The availabilityZone. + */ + public java.lang.String getAvailabilityZone() { + java.lang.Object ref = availabilityZone_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + availabilityZone_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The cloud environment availability zone (different from region which is
+     * location.name).
+     * 
+ * + * string availability_zone = 4; + * + * @return The bytes for availabilityZone. + */ + public com.google.protobuf.ByteString getAvailabilityZoneBytes() { + java.lang.Object ref = availabilityZone_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + availabilityZone_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The cloud environment availability zone (different from region which is
+     * location.name).
+     * 
+ * + * string availability_zone = 4; + * + * @param value The availabilityZone to set. + * @return This builder for chaining. + */ + public Builder setAvailabilityZone(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + availabilityZone_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment availability zone (different from region which is
+     * location.name).
+     * 
+ * + * string availability_zone = 4; + * + * @return This builder for chaining. + */ + public Builder clearAvailabilityZone() { + availabilityZone_ = getDefaultInstance().getAvailabilityZone(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * The cloud environment availability zone (different from region which is
+     * location.name).
+     * 
+ * + * string availability_zone = 4; + * + * @param value The bytes for availabilityZone to set. + * @return This builder for chaining. + */ + public Builder setAvailabilityZoneBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + availabilityZone_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Cloud) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Cloud) + private static final com.google.backstory.Cloud DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Cloud(); + } + + public static com.google.backstory.Cloud getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Cloud parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Cloud getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java new file mode 100644 index 000000000000..93f9c7a4d52a --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java @@ -0,0 +1,157 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface CloudOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Cloud) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The Cloud environment.
+   * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return The enum numeric value on the wire for environment. + */ + int getEnvironmentValue(); + + /** + * + * + *
+   * The Cloud environment.
+   * 
+ * + * .google.backstory.Cloud.CloudEnvironment environment = 1; + * + * @return The environment. + */ + com.google.backstory.Cloud.CloudEnvironment getEnvironment(); + + /** + * + * + *
+   * The cloud environment VPC.
+   * Deprecated.
+   * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.vpc is deprecated. See backstory/udm.proto;l=5686 + * @return Whether the vpc field is set. + */ + @java.lang.Deprecated + boolean hasVpc(); + + /** + * + * + *
+   * The cloud environment VPC.
+   * Deprecated.
+   * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.vpc is deprecated. See backstory/udm.proto;l=5686 + * @return The vpc. + */ + @java.lang.Deprecated + com.google.backstory.Resource getVpc(); + + /** + * + * + *
+   * The cloud environment VPC.
+   * Deprecated.
+   * 
+ * + * .google.backstory.Resource vpc = 2 [deprecated = true]; + */ + @java.lang.Deprecated + com.google.backstory.ResourceOrBuilder getVpcOrBuilder(); + + /** + * + * + *
+   * The cloud environment project information.
+   * Deprecated: Use Resource.resource_ancestors
+   * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.project is deprecated. See backstory/udm.proto;l=5690 + * @return Whether the project field is set. + */ + @java.lang.Deprecated + boolean hasProject(); + + /** + * + * + *
+   * The cloud environment project information.
+   * Deprecated: Use Resource.resource_ancestors
+   * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + * + * @deprecated google.backstory.Cloud.project is deprecated. See backstory/udm.proto;l=5690 + * @return The project. + */ + @java.lang.Deprecated + com.google.backstory.Resource getProject(); + + /** + * + * + *
+   * The cloud environment project information.
+   * Deprecated: Use Resource.resource_ancestors
+   * 
+ * + * .google.backstory.Resource project = 3 [deprecated = true]; + */ + @java.lang.Deprecated + com.google.backstory.ResourceOrBuilder getProjectOrBuilder(); + + /** + * + * + *
+   * The cloud environment availability zone (different from region which is
+   * location.name).
+   * 
+ * + * string availability_zone = 4; + * + * @return The availabilityZone. + */ + java.lang.String getAvailabilityZone(); + + /** + * + * + *
+   * The cloud environment availability zone (different from region which is
+   * location.name).
+   * 
+ * + * string availability_zone = 4; + * + * @return The bytes for availabilityZone. + */ + com.google.protobuf.ByteString getAvailabilityZoneBytes(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Collection.java b/java-backstory/src/main/java/com/google/backstory/Collection.java new file mode 100644 index 000000000000..dca44889a710 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Collection.java @@ -0,0 +1,6904 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/collection.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Collection represents a container of objects (such as events, entity
+ * context metadata, detection finding metadata) and state (such as
+ * investigation details).
+ *
+ * An example use case for Collection is to model a detection and investigation
+ * from detection finding metadata to investigative state collected in the
+ * course of the investigation. For more complex investigation and response
+ * workflows a Collection could represent an incident consisting of multiple
+ * child findings or incidents. This can be expanded on to model remediation
+ * elements of a full detection and response workflow.
+ * 
+ * + * Protobuf type {@code google.backstory.Collection} + */ +@com.google.protobuf.Generated +public final class Collection extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Collection) + CollectionOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Collection"); + } + + // Use Collection.newBuilder() to construct. + private Collection(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Collection() { + id_ = ""; + type_ = 0; + idNamespace_ = 0; + collectionElements_ = java.util.Collections.emptyList(); + detection_ = java.util.Collections.emptyList(); + tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + caseName_ = ""; + dataAccessScope_ = ""; + detectionTimingDetails_ = emptyIntList(); + ruleRunFrequency_ = 0; + simulatedEventNames_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_Collection_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_Collection_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Collection.class, com.google.backstory.Collection.Builder.class); + } + + /** + * + * + *
+   * The type of the collection which will indicate which other fields are
+   * relevant. For example, detection finding collections will populate the
+   * detection field. Findings that evolve into investigations will populate the
+   * investigation field.
+   * 
+ * + * Protobuf enum {@code google.backstory.Collection.CollectionType} + */ + public enum CollectionType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * An unspecified collection type.
+     * 
+ * + * COLLECTION_TYPE_UNSPECIFIED = 0; + */ + COLLECTION_TYPE_UNSPECIFIED(0, 0), + /** + * + * + *
+     * An alert reported in customer telemetry.
+     * 
+ * + * TELEMETRY_ALERT = 1; + */ + TELEMETRY_ALERT(1, 1), + /** + * + * + *
+     * A finding from the Uppercase team.
+     * 
+ * + * GCTI_FINDING = 2; + */ + GCTI_FINDING(2, 2), + /** + * + * + *
+     * A detection found by applying a rule.
+     * 
+ * + * RULE_DETECTION = 3; + */ + RULE_DETECTION(4, 3), + /** + * + * + *
+     * An alert generated by Chronicle machine learning models.
+     * 
+ * + * MACHINE_INTELLIGENCE_ALERT = 4; + */ + MACHINE_INTELLIGENCE_ALERT(5, 4), + /** + * + * + *
+     * An alert coming from other SIEMs via Chronicle SOAR.
+     * 
+ * + * SOAR_ALERT = 5; + */ + SOAR_ALERT(6, 5), + UNRECOGNIZED(-1, -1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "CollectionType"); + } + + /** UPPERCASE_ALERT = 2; */ + public static final CollectionType UPPERCASE_ALERT = GCTI_FINDING; + + /** + * + * + *
+     * An unspecified collection type.
+     * 
+ * + * COLLECTION_TYPE_UNSPECIFIED = 0; + */ + public static final int COLLECTION_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * An alert reported in customer telemetry.
+     * 
+ * + * TELEMETRY_ALERT = 1; + */ + public static final int TELEMETRY_ALERT_VALUE = 1; + + /** + * + * + *
+     * A finding from the Uppercase team.
+     * 
+ * + * GCTI_FINDING = 2; + */ + public static final int GCTI_FINDING_VALUE = 2; + + /** UPPERCASE_ALERT = 2; */ + public static final int UPPERCASE_ALERT_VALUE = 2; + + /** + * + * + *
+     * A detection found by applying a rule.
+     * 
+ * + * RULE_DETECTION = 3; + */ + public static final int RULE_DETECTION_VALUE = 3; + + /** + * + * + *
+     * An alert generated by Chronicle machine learning models.
+     * 
+ * + * MACHINE_INTELLIGENCE_ALERT = 4; + */ + public static final int MACHINE_INTELLIGENCE_ALERT_VALUE = 4; + + /** + * + * + *
+     * An alert coming from other SIEMs via Chronicle SOAR.
+     * 
+ * + * SOAR_ALERT = 5; + */ + public static final int SOAR_ALERT_VALUE = 5; + + public final int getNumber() { + if (index == -1) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static CollectionType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static CollectionType forNumber(int value) { + switch (value) { + case 0: + return COLLECTION_TYPE_UNSPECIFIED; + case 1: + return TELEMETRY_ALERT; + case 2: + return GCTI_FINDING; + case 3: + return RULE_DETECTION; + case 4: + return MACHINE_INTELLIGENCE_ALERT; + case 5: + return SOAR_ALERT; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public CollectionType findValueByNumber(int number) { + return CollectionType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (index == -1) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(index); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Collection.getDescriptor().getEnumTypes().get(0); + } + + private static final CollectionType[] VALUES = getStaticValuesArray(); + + private static CollectionType[] getStaticValuesArray() { + return new CollectionType[] { + COLLECTION_TYPE_UNSPECIFIED, + TELEMETRY_ALERT, + GCTI_FINDING, + UPPERCASE_ALERT, + RULE_DETECTION, + MACHINE_INTELLIGENCE_ALERT, + SOAR_ALERT, + }; + } + + public static CollectionType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int index; + private final int value; + + private CollectionType(int index, int value) { + this.index = index; + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Collection.CollectionType) + } + + /** + * + * + *
+   * Detection timing details for the collection.
+   * 
+ * + * Protobuf enum {@code google.backstory.Collection.DetectionTimingDetails} + */ + public enum DetectionTimingDetails implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Detection timing details are unspecified.
+     * 
+ * + * DETECTION_TIMING_DETAILS_UNSPECIFIED = 0; + */ + DETECTION_TIMING_DETAILS_UNSPECIFIED(0), + /** + * + * + *
+     * Detection is generated by a reprocessing run.
+     * 
+ * + * DETECTION_TIMING_DETAILS_REPROCESSING = 1; + */ + DETECTION_TIMING_DETAILS_REPROCESSING(1), + /** + * + * + *
+     * Detection is generated by a retrohunt run.
+     * 
+ * + * DETECTION_TIMING_DETAILS_RETROHUNT = 2; + */ + DETECTION_TIMING_DETAILS_RETROHUNT(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DetectionTimingDetails"); + } + + /** + * + * + *
+     * Detection timing details are unspecified.
+     * 
+ * + * DETECTION_TIMING_DETAILS_UNSPECIFIED = 0; + */ + public static final int DETECTION_TIMING_DETAILS_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Detection is generated by a reprocessing run.
+     * 
+ * + * DETECTION_TIMING_DETAILS_REPROCESSING = 1; + */ + public static final int DETECTION_TIMING_DETAILS_REPROCESSING_VALUE = 1; + + /** + * + * + *
+     * Detection is generated by a retrohunt run.
+     * 
+ * + * DETECTION_TIMING_DETAILS_RETROHUNT = 2; + */ + public static final int DETECTION_TIMING_DETAILS_RETROHUNT_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DetectionTimingDetails valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static DetectionTimingDetails forNumber(int value) { + switch (value) { + case 0: + return DETECTION_TIMING_DETAILS_UNSPECIFIED; + case 1: + return DETECTION_TIMING_DETAILS_REPROCESSING; + case 2: + return DETECTION_TIMING_DETAILS_RETROHUNT; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public DetectionTimingDetails findValueByNumber(int number) { + return DetectionTimingDetails.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Collection.getDescriptor().getEnumTypes().get(1); + } + + private static final DetectionTimingDetails[] VALUES = values(); + + public static DetectionTimingDetails valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private DetectionTimingDetails(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Collection.DetectionTimingDetails) + } + + /** + * + * + *
+   * Run frequencies used by rule executions.
+   * 
+ * + * Protobuf enum {@code google.backstory.Collection.RunFrequency} + */ + public enum RunFrequency implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified run frequency.
+     * 
+ * + * RUN_FREQUENCY_UNSPECIFIED = 0; + */ + RUN_FREQUENCY_UNSPECIFIED(0), + /** + * + * + *
+     * Real-time run frequency.
+     * 
+ * + * RUN_FREQUENCY_REALTIME = 1; + */ + RUN_FREQUENCY_REALTIME(1), + /** + * + * + *
+     * Executes once an hour.
+     * 
+ * + * RUN_FREQUENCY_HOURLY = 2; + */ + RUN_FREQUENCY_HOURLY(2), + /** + * + * + *
+     * Executes once a day.
+     * 
+ * + * RUN_FREQUENCY_DAILY = 3; + */ + RUN_FREQUENCY_DAILY(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "RunFrequency"); + } + + /** + * + * + *
+     * Unspecified run frequency.
+     * 
+ * + * RUN_FREQUENCY_UNSPECIFIED = 0; + */ + public static final int RUN_FREQUENCY_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Real-time run frequency.
+     * 
+ * + * RUN_FREQUENCY_REALTIME = 1; + */ + public static final int RUN_FREQUENCY_REALTIME_VALUE = 1; + + /** + * + * + *
+     * Executes once an hour.
+     * 
+ * + * RUN_FREQUENCY_HOURLY = 2; + */ + public static final int RUN_FREQUENCY_HOURLY_VALUE = 2; + + /** + * + * + *
+     * Executes once a day.
+     * 
+ * + * RUN_FREQUENCY_DAILY = 3; + */ + public static final int RUN_FREQUENCY_DAILY_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static RunFrequency valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static RunFrequency forNumber(int value) { + switch (value) { + case 0: + return RUN_FREQUENCY_UNSPECIFIED; + case 1: + return RUN_FREQUENCY_REALTIME; + case 2: + return RUN_FREQUENCY_HOURLY; + case 3: + return RUN_FREQUENCY_DAILY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public RunFrequency findValueByNumber(int number) { + return RunFrequency.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Collection.getDescriptor().getEnumTypes().get(2); + } + + private static final RunFrequency[] VALUES = values(); + + public static RunFrequency valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private RunFrequency(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Collection.RunFrequency) + } + + private int bitField0_; + public static final int ID_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object id_ = ""; + + /** + * + * + *
+   * Unique ID for the collection.
+   * The ID is specific to the type of collection. For example, with rule
+   * detections this is the detection ID.
+   * 
+ * + * string id = 7; + * + * @return The id. + */ + @java.lang.Override + public java.lang.String getId() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } + } + + /** + * + * + *
+   * Unique ID for the collection.
+   * The ID is specific to the type of collection. For example, with rule
+   * detections this is the detection ID.
+   * 
+ * + * string id = 7; + * + * @return The bytes for id. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TYPE_FIELD_NUMBER = 1; + private int type_ = 0; + + /** + * + * + *
+   * What the collection represents.
+   * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+   * What the collection represents.
+   * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.backstory.Collection.CollectionType getType() { + com.google.backstory.Collection.CollectionType result = + com.google.backstory.Collection.CollectionType.forNumber(type_); + return result == null ? com.google.backstory.Collection.CollectionType.UNRECOGNIZED : result; + } + + public static final int ID_NAMESPACE_FIELD_NUMBER = 12; + private int idNamespace_ = 0; + + /** + * + * + *
+   * The ID namespace used for the Collection.
+   * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return The enum numeric value on the wire for idNamespace. + */ + @java.lang.Override + public int getIdNamespaceValue() { + return idNamespace_; + } + + /** + * + * + *
+   * The ID namespace used for the Collection.
+   * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return The idNamespace. + */ + @java.lang.Override + public com.google.backstory.Id.Namespace getIdNamespace() { + com.google.backstory.Id.Namespace result = + com.google.backstory.Id.Namespace.forNumber(idNamespace_); + return result == null ? com.google.backstory.Id.Namespace.UNRECOGNIZED : result; + } + + public static final int CREATED_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createdTime_; + + /** + * + * + *
+   * Time the collection was created.
+   * 
+ * + * .google.protobuf.Timestamp created_time = 5; + * + * @return Whether the createdTime field is set. + */ + @java.lang.Override + public boolean hasCreatedTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Time the collection was created.
+   * 
+ * + * .google.protobuf.Timestamp created_time = 5; + * + * @return The createdTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreatedTime() { + return createdTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdTime_; + } + + /** + * + * + *
+   * Time the collection was created.
+   * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreatedTimeOrBuilder() { + return createdTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdTime_; + } + + public static final int LAST_UPDATED_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp lastUpdatedTime_; + + /** + * + * + *
+   * Time the collection was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + * + * @return Whether the lastUpdatedTime field is set. + */ + @java.lang.Override + public boolean hasLastUpdatedTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Time the collection was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + * + * @return The lastUpdatedTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastUpdatedTime() { + return lastUpdatedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdatedTime_; + } + + /** + * + * + *
+   * Time the collection was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastUpdatedTimeOrBuilder() { + return lastUpdatedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdatedTime_; + } + + public static final int TIME_WINDOW_FIELD_NUMBER = 8; + private com.google.type.Interval timeWindow_; + + /** + * + * + *
+   * Time interval that the collection represents.
+   * 
+ * + * .google.type.Interval time_window = 8; + * + * @return Whether the timeWindow field is set. + */ + @java.lang.Override + public boolean hasTimeWindow() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Time interval that the collection represents.
+   * 
+ * + * .google.type.Interval time_window = 8; + * + * @return The timeWindow. + */ + @java.lang.Override + public com.google.type.Interval getTimeWindow() { + return timeWindow_ == null ? com.google.type.Interval.getDefaultInstance() : timeWindow_; + } + + /** + * + * + *
+   * Time interval that the collection represents.
+   * 
+ * + * .google.type.Interval time_window = 8; + */ + @java.lang.Override + public com.google.type.IntervalOrBuilder getTimeWindowOrBuilder() { + return timeWindow_ == null ? com.google.type.Interval.getDefaultInstance() : timeWindow_; + } + + public static final int COLLECTION_ELEMENTS_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private java.util.List collectionElements_; + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + @java.lang.Override + public java.util.List getCollectionElementsList() { + return collectionElements_; + } + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + @java.lang.Override + public java.util.List + getCollectionElementsOrBuilderList() { + return collectionElements_; + } + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + @java.lang.Override + public int getCollectionElementsCount() { + return collectionElements_.size(); + } + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + @java.lang.Override + public com.google.backstory.Element getCollectionElements(int index) { + return collectionElements_.get(index); + } + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + @java.lang.Override + public com.google.backstory.ElementOrBuilder getCollectionElementsOrBuilder(int index) { + return collectionElements_.get(index); + } + + public static final int DETECTION_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private java.util.List detection_; + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + @java.lang.Override + public java.util.List getDetectionList() { + return detection_; + } + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + @java.lang.Override + public java.util.List + getDetectionOrBuilderList() { + return detection_; + } + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + @java.lang.Override + public int getDetectionCount() { + return detection_.size(); + } + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + @java.lang.Override + public com.google.backstory.SecurityResult getDetection(int index) { + return detection_.get(index); + } + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + @java.lang.Override + public com.google.backstory.SecurityResultOrBuilder getDetectionOrBuilder(int index) { + return detection_.get(index); + } + + public static final int DETECTION_TIME_FIELD_NUMBER = 10; + private com.google.protobuf.Timestamp detectionTime_; + + /** + * + * + *
+   * Timestamp within the time_window related to the time of the
+   * collection_elements. For Rule Detections, this timestamp is the end of the
+   * the time_window for multi-event rules or the time of the event for single
+   * event rules. For late-arriving events that trigger new alerts, the
+   * detection_time will be the event time of the event.
+   * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + * + * @return Whether the detectionTime field is set. + */ + @java.lang.Override + public boolean hasDetectionTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+   * Timestamp within the time_window related to the time of the
+   * collection_elements. For Rule Detections, this timestamp is the end of the
+   * the time_window for multi-event rules or the time of the event for single
+   * event rules. For late-arriving events that trigger new alerts, the
+   * detection_time will be the event time of the event.
+   * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + * + * @return The detectionTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getDetectionTime() { + return detectionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : detectionTime_; + } + + /** + * + * + *
+   * Timestamp within the time_window related to the time of the
+   * collection_elements. For Rule Detections, this timestamp is the end of the
+   * the time_window for multi-event rules or the time of the event for single
+   * event rules. For late-arriving events that trigger new alerts, the
+   * detection_time will be the event time of the event.
+   * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getDetectionTimeOrBuilder() { + return detectionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : detectionTime_; + } + + public static final int INVESTIGATION_FIELD_NUMBER = 4; + private com.google.backstory.Investigation investigation_; + + /** + * + * + *
+   * Consolidated investigation details (categorization, status, etc) typically
+   * for collections that begin as detection findings and then evolve with
+   * analyst action and feedback into investigations around the detection
+   * output.
+   * 
+ * + * .google.backstory.Investigation investigation = 4; + * + * @return Whether the investigation field is set. + */ + @java.lang.Override + public boolean hasInvestigation() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+   * Consolidated investigation details (categorization, status, etc) typically
+   * for collections that begin as detection findings and then evolve with
+   * analyst action and feedback into investigations around the detection
+   * output.
+   * 
+ * + * .google.backstory.Investigation investigation = 4; + * + * @return The investigation. + */ + @java.lang.Override + public com.google.backstory.Investigation getInvestigation() { + return investigation_ == null + ? com.google.backstory.Investigation.getDefaultInstance() + : investigation_; + } + + /** + * + * + *
+   * Consolidated investigation details (categorization, status, etc) typically
+   * for collections that begin as detection findings and then evolve with
+   * analyst action and feedback into investigations around the detection
+   * output.
+   * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + @java.lang.Override + public com.google.backstory.InvestigationOrBuilder getInvestigationOrBuilder() { + return investigation_ == null + ? com.google.backstory.Investigation.getDefaultInstance() + : investigation_; + } + + public static final int TAGS_FIELD_NUMBER = 11; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList tags_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @return A list containing the tags. + */ + public com.google.protobuf.ProtocolStringList getTagsList() { + return tags_; + } + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @return The count of tags. + */ + public int getTagsCount() { + return tags_.size(); + } + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @param index The index of the element to return. + * @return The tags at the given index. + */ + public java.lang.String getTags(int index) { + return tags_.get(index); + } + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @param index The index of the value to return. + * @return The bytes of the tags at the given index. + */ + public com.google.protobuf.ByteString getTagsBytes(int index) { + return tags_.getByteString(index); + } + + public static final int RESPONSE_PLATFORM_INFO_FIELD_NUMBER = 13; + private com.google.backstory.ResponsePlatformInfo responsePlatformInfo_; + + /** + * + * + *
+   * Alert related info of this same alert in customer's SOAR platform.
+   * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + * + * @return Whether the responsePlatformInfo field is set. + */ + @java.lang.Override + public boolean hasResponsePlatformInfo() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+   * Alert related info of this same alert in customer's SOAR platform.
+   * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + * + * @return The responsePlatformInfo. + */ + @java.lang.Override + public com.google.backstory.ResponsePlatformInfo getResponsePlatformInfo() { + return responsePlatformInfo_ == null + ? com.google.backstory.ResponsePlatformInfo.getDefaultInstance() + : responsePlatformInfo_; + } + + /** + * + * + *
+   * Alert related info of this same alert in customer's SOAR platform.
+   * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + @java.lang.Override + public com.google.backstory.ResponsePlatformInfoOrBuilder getResponsePlatformInfoOrBuilder() { + return responsePlatformInfo_ == null + ? com.google.backstory.ResponsePlatformInfo.getDefaultInstance() + : responsePlatformInfo_; + } + + public static final int CASE_NAME_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private volatile java.lang.Object caseName_ = ""; + + /** + * + * + *
+   * The resource name of the Case that this collection belongs to.
+   * Example:
+   * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+   * 
+ * + * string case_name = 14; + * + * @return The caseName. + */ + @java.lang.Override + public java.lang.String getCaseName() { + java.lang.Object ref = caseName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + caseName_ = s; + return s; + } + } + + /** + * + * + *
+   * The resource name of the Case that this collection belongs to.
+   * Example:
+   * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+   * 
+ * + * string case_name = 14; + * + * @return The bytes for caseName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCaseNameBytes() { + java.lang.Object ref = caseName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + caseName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SOAR_ALERT_FIELD_NUMBER = 17; + private boolean soarAlert_ = false; + + /** + * + * + *
+   * A boolean field indicating that the alert is present in SOAR.
+   * 
+ * + * bool soar_alert = 17; + * + * @return The soarAlert. + */ + @java.lang.Override + public boolean getSoarAlert() { + return soarAlert_; + } + + public static final int SOAR_ALERT_METADATA_FIELD_NUMBER = 18; + private com.google.backstory.SoarAlertMetadata soarAlertMetadata_; + + /** + * + * + *
+   * Metadata fields of alerts coming from other SIEM systems via SOAR.
+   * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + * + * @return Whether the soarAlertMetadata field is set. + */ + @java.lang.Override + public boolean hasSoarAlertMetadata() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+   * Metadata fields of alerts coming from other SIEM systems via SOAR.
+   * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + * + * @return The soarAlertMetadata. + */ + @java.lang.Override + public com.google.backstory.SoarAlertMetadata getSoarAlertMetadata() { + return soarAlertMetadata_ == null + ? com.google.backstory.SoarAlertMetadata.getDefaultInstance() + : soarAlertMetadata_; + } + + /** + * + * + *
+   * Metadata fields of alerts coming from other SIEM systems via SOAR.
+   * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + @java.lang.Override + public com.google.backstory.SoarAlertMetadataOrBuilder getSoarAlertMetadataOrBuilder() { + return soarAlertMetadata_ == null + ? com.google.backstory.SoarAlertMetadata.getDefaultInstance() + : soarAlertMetadata_; + } + + public static final int DATA_ACCESS_SCOPE_FIELD_NUMBER = 19; + + @SuppressWarnings("serial") + private volatile java.lang.Object dataAccessScope_ = ""; + + /** + * + * + *
+   * The resource name of the DataAccessScope of this collection.
+   * 
+ * + * string data_access_scope = 19; + * + * @return The dataAccessScope. + */ + @java.lang.Override + public java.lang.String getDataAccessScope() { + java.lang.Object ref = dataAccessScope_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dataAccessScope_ = s; + return s; + } + } + + /** + * + * + *
+   * The resource name of the DataAccessScope of this collection.
+   * 
+ * + * string data_access_scope = 19; + * + * @return The bytes for dataAccessScope. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDataAccessScopeBytes() { + java.lang.Object ref = dataAccessScope_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dataAccessScope_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DETECTION_TIMING_DETAILS_FIELD_NUMBER = 20; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.IntList detectionTimingDetails_ = emptyIntList(); + + private static final com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.backstory.Collection.DetectionTimingDetails> + detectionTimingDetails_converter_ = + new com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.backstory.Collection.DetectionTimingDetails>() { + public com.google.backstory.Collection.DetectionTimingDetails convert(int from) { + com.google.backstory.Collection.DetectionTimingDetails result = + com.google.backstory.Collection.DetectionTimingDetails.forNumber(from); + return result == null + ? com.google.backstory.Collection.DetectionTimingDetails.UNRECOGNIZED + : result; + } + }; + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return A list containing the detectionTimingDetails. + */ + @java.lang.Override + public java.util.List + getDetectionTimingDetailsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.backstory.Collection.DetectionTimingDetails>( + detectionTimingDetails_, detectionTimingDetails_converter_); + } + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return The count of detectionTimingDetails. + */ + @java.lang.Override + public int getDetectionTimingDetailsCount() { + return detectionTimingDetails_.size(); + } + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index of the element to return. + * @return The detectionTimingDetails at the given index. + */ + @java.lang.Override + public com.google.backstory.Collection.DetectionTimingDetails getDetectionTimingDetails( + int index) { + return detectionTimingDetails_converter_.convert(detectionTimingDetails_.getInt(index)); + } + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return A list containing the enum numeric values on the wire for detectionTimingDetails. + */ + @java.lang.Override + public java.util.List getDetectionTimingDetailsValueList() { + return detectionTimingDetails_; + } + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of detectionTimingDetails at the given index. + */ + @java.lang.Override + public int getDetectionTimingDetailsValue(int index) { + return detectionTimingDetails_.getInt(index); + } + + private int detectionTimingDetailsMemoizedSerializedSize; + + public static final int LATENCY_METRICS_FIELD_NUMBER = 21; + private com.google.backstory.LatencyMetrics latencyMetrics_; + + /** + * + * + *
+   * The latency metrics for the specific detection. These metrics are
+   * calculated from ALL of the events that contribute to the detection, not
+   * just the sampled ones.
+   * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + * + * @return Whether the latencyMetrics field is set. + */ + @java.lang.Override + public boolean hasLatencyMetrics() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
+   * The latency metrics for the specific detection. These metrics are
+   * calculated from ALL of the events that contribute to the detection, not
+   * just the sampled ones.
+   * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + * + * @return The latencyMetrics. + */ + @java.lang.Override + public com.google.backstory.LatencyMetrics getLatencyMetrics() { + return latencyMetrics_ == null + ? com.google.backstory.LatencyMetrics.getDefaultInstance() + : latencyMetrics_; + } + + /** + * + * + *
+   * The latency metrics for the specific detection. These metrics are
+   * calculated from ALL of the events that contribute to the detection, not
+   * just the sampled ones.
+   * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + @java.lang.Override + public com.google.backstory.LatencyMetricsOrBuilder getLatencyMetricsOrBuilder() { + return latencyMetrics_ == null + ? com.google.backstory.LatencyMetrics.getDefaultInstance() + : latencyMetrics_; + } + + public static final int RULE_RUN_FREQUENCY_FIELD_NUMBER = 22; + private int ruleRunFrequency_ = 0; + + /** + * + * + *
+   * The run frequency of the rule when it generated the detection.
+   * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return The enum numeric value on the wire for ruleRunFrequency. + */ + @java.lang.Override + public int getRuleRunFrequencyValue() { + return ruleRunFrequency_; + } + + /** + * + * + *
+   * The run frequency of the rule when it generated the detection.
+   * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return The ruleRunFrequency. + */ + @java.lang.Override + public com.google.backstory.Collection.RunFrequency getRuleRunFrequency() { + com.google.backstory.Collection.RunFrequency result = + com.google.backstory.Collection.RunFrequency.forNumber(ruleRunFrequency_); + return result == null ? com.google.backstory.Collection.RunFrequency.UNRECOGNIZED : result; + } + + public static final int SIMULATED_EVENT_COUNT_FIELD_NUMBER = 23; + private long simulatedEventCount_ = 0L; + + /** + * + * + *
+   * The total number of simulated events that contributed to this detection.
+   * Simulated events are realistic threat sequences (Raw Logs or UDM)
+   * programmatically delivered into the production ingestion pipeline to verify
+   * the entire detection lifecycle—from identification to action.
+   * 
+ * + * int64 simulated_event_count = 23; + * + * @return The simulatedEventCount. + */ + @java.lang.Override + public long getSimulatedEventCount() { + return simulatedEventCount_; + } + + public static final int SIMULATED_EVENT_NAMES_FIELD_NUMBER = 24; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList simulatedEventNames_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @return A list containing the simulatedEventNames. + */ + public com.google.protobuf.ProtocolStringList getSimulatedEventNamesList() { + return simulatedEventNames_; + } + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @return The count of simulatedEventNames. + */ + public int getSimulatedEventNamesCount() { + return simulatedEventNames_.size(); + } + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index of the element to return. + * @return The simulatedEventNames at the given index. + */ + public java.lang.String getSimulatedEventNames(int index) { + return simulatedEventNames_.get(index); + } + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index of the value to return. + * @return The bytes of the simulatedEventNames at the given index. + */ + public com.google.protobuf.ByteString getSimulatedEventNamesBytes(int index) { + return simulatedEventNames_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getSerializedSize(); + if (type_ + != com.google.backstory.Collection.CollectionType.COLLECTION_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(1, type_); + } + for (int i = 0; i < detection_.size(); i++) { + output.writeMessage(3, detection_.get(i)); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(4, getInvestigation()); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreatedTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getLastUpdatedTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, id_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(8, getTimeWindow()); + } + for (int i = 0; i < collectionElements_.size(); i++) { + output.writeMessage(9, collectionElements_.get(i)); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(10, getDetectionTime()); + } + for (int i = 0; i < tags_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 11, tags_.getRaw(i)); + } + if (idNamespace_ != com.google.backstory.Id.Namespace.NORMALIZED_TELEMETRY.getNumber()) { + output.writeEnum(12, idNamespace_); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeMessage(13, getResponsePlatformInfo()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(caseName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 14, caseName_); + } + if (soarAlert_ != false) { + output.writeBool(17, soarAlert_); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeMessage(18, getSoarAlertMetadata()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(dataAccessScope_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 19, dataAccessScope_); + } + if (getDetectionTimingDetailsList().size() > 0) { + output.writeUInt32NoTag(162); + output.writeUInt32NoTag(detectionTimingDetailsMemoizedSerializedSize); + } + for (int i = 0; i < detectionTimingDetails_.size(); i++) { + output.writeEnumNoTag(detectionTimingDetails_.getInt(i)); + } + if (((bitField0_ & 0x00000080) != 0)) { + output.writeMessage(21, getLatencyMetrics()); + } + if (ruleRunFrequency_ + != com.google.backstory.Collection.RunFrequency.RUN_FREQUENCY_UNSPECIFIED.getNumber()) { + output.writeEnum(22, ruleRunFrequency_); + } + if (simulatedEventCount_ != 0L) { + output.writeInt64(23, simulatedEventCount_); + } + for (int i = 0; i < simulatedEventNames_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 24, simulatedEventNames_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (type_ + != com.google.backstory.Collection.CollectionType.COLLECTION_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); + } + for (int i = 0; i < detection_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, detection_.get(i)); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getInvestigation()); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreatedTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getLastUpdatedTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(7, id_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getTimeWindow()); + } + for (int i = 0; i < collectionElements_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(9, collectionElements_.get(i)); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getDetectionTime()); + } + { + int dataSize = 0; + for (int i = 0; i < tags_.size(); i++) { + dataSize += computeStringSizeNoTag(tags_.getRaw(i)); + } + size += dataSize; + size += 1 * getTagsList().size(); + } + if (idNamespace_ != com.google.backstory.Id.Namespace.NORMALIZED_TELEMETRY.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(12, idNamespace_); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(13, getResponsePlatformInfo()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(caseName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(14, caseName_); + } + if (soarAlert_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(17, soarAlert_); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getSoarAlertMetadata()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(dataAccessScope_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(19, dataAccessScope_); + } + { + int dataSize = 0; + for (int i = 0; i < detectionTimingDetails_.size(); i++) { + dataSize += + com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag( + detectionTimingDetails_.getInt(i)); + } + size += dataSize; + if (!getDetectionTimingDetailsList().isEmpty()) { + size += 2; + size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); + } + detectionTimingDetailsMemoizedSerializedSize = dataSize; + } + if (((bitField0_ & 0x00000080) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(21, getLatencyMetrics()); + } + if (ruleRunFrequency_ + != com.google.backstory.Collection.RunFrequency.RUN_FREQUENCY_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(22, ruleRunFrequency_); + } + if (simulatedEventCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(23, simulatedEventCount_); + } + { + int dataSize = 0; + for (int i = 0; i < simulatedEventNames_.size(); i++) { + dataSize += computeStringSizeNoTag(simulatedEventNames_.getRaw(i)); + } + size += dataSize; + size += 2 * getSimulatedEventNamesList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Collection)) { + return super.equals(obj); + } + com.google.backstory.Collection other = (com.google.backstory.Collection) obj; + + if (!getId().equals(other.getId())) return false; + if (type_ != other.type_) return false; + if (idNamespace_ != other.idNamespace_) return false; + if (hasCreatedTime() != other.hasCreatedTime()) return false; + if (hasCreatedTime()) { + if (!getCreatedTime().equals(other.getCreatedTime())) return false; + } + if (hasLastUpdatedTime() != other.hasLastUpdatedTime()) return false; + if (hasLastUpdatedTime()) { + if (!getLastUpdatedTime().equals(other.getLastUpdatedTime())) return false; + } + if (hasTimeWindow() != other.hasTimeWindow()) return false; + if (hasTimeWindow()) { + if (!getTimeWindow().equals(other.getTimeWindow())) return false; + } + if (!getCollectionElementsList().equals(other.getCollectionElementsList())) return false; + if (!getDetectionList().equals(other.getDetectionList())) return false; + if (hasDetectionTime() != other.hasDetectionTime()) return false; + if (hasDetectionTime()) { + if (!getDetectionTime().equals(other.getDetectionTime())) return false; + } + if (hasInvestigation() != other.hasInvestigation()) return false; + if (hasInvestigation()) { + if (!getInvestigation().equals(other.getInvestigation())) return false; + } + if (!getTagsList().equals(other.getTagsList())) return false; + if (hasResponsePlatformInfo() != other.hasResponsePlatformInfo()) return false; + if (hasResponsePlatformInfo()) { + if (!getResponsePlatformInfo().equals(other.getResponsePlatformInfo())) return false; + } + if (!getCaseName().equals(other.getCaseName())) return false; + if (getSoarAlert() != other.getSoarAlert()) return false; + if (hasSoarAlertMetadata() != other.hasSoarAlertMetadata()) return false; + if (hasSoarAlertMetadata()) { + if (!getSoarAlertMetadata().equals(other.getSoarAlertMetadata())) return false; + } + if (!getDataAccessScope().equals(other.getDataAccessScope())) return false; + if (!detectionTimingDetails_.equals(other.detectionTimingDetails_)) return false; + if (hasLatencyMetrics() != other.hasLatencyMetrics()) return false; + if (hasLatencyMetrics()) { + if (!getLatencyMetrics().equals(other.getLatencyMetrics())) return false; + } + if (ruleRunFrequency_ != other.ruleRunFrequency_) return false; + if (getSimulatedEventCount() != other.getSimulatedEventCount()) return false; + if (!getSimulatedEventNamesList().equals(other.getSimulatedEventNamesList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ID_FIELD_NUMBER; + hash = (53 * hash) + getId().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + hash = (37 * hash) + ID_NAMESPACE_FIELD_NUMBER; + hash = (53 * hash) + idNamespace_; + if (hasCreatedTime()) { + hash = (37 * hash) + CREATED_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreatedTime().hashCode(); + } + if (hasLastUpdatedTime()) { + hash = (37 * hash) + LAST_UPDATED_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastUpdatedTime().hashCode(); + } + if (hasTimeWindow()) { + hash = (37 * hash) + TIME_WINDOW_FIELD_NUMBER; + hash = (53 * hash) + getTimeWindow().hashCode(); + } + if (getCollectionElementsCount() > 0) { + hash = (37 * hash) + COLLECTION_ELEMENTS_FIELD_NUMBER; + hash = (53 * hash) + getCollectionElementsList().hashCode(); + } + if (getDetectionCount() > 0) { + hash = (37 * hash) + DETECTION_FIELD_NUMBER; + hash = (53 * hash) + getDetectionList().hashCode(); + } + if (hasDetectionTime()) { + hash = (37 * hash) + DETECTION_TIME_FIELD_NUMBER; + hash = (53 * hash) + getDetectionTime().hashCode(); + } + if (hasInvestigation()) { + hash = (37 * hash) + INVESTIGATION_FIELD_NUMBER; + hash = (53 * hash) + getInvestigation().hashCode(); + } + if (getTagsCount() > 0) { + hash = (37 * hash) + TAGS_FIELD_NUMBER; + hash = (53 * hash) + getTagsList().hashCode(); + } + if (hasResponsePlatformInfo()) { + hash = (37 * hash) + RESPONSE_PLATFORM_INFO_FIELD_NUMBER; + hash = (53 * hash) + getResponsePlatformInfo().hashCode(); + } + hash = (37 * hash) + CASE_NAME_FIELD_NUMBER; + hash = (53 * hash) + getCaseName().hashCode(); + hash = (37 * hash) + SOAR_ALERT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSoarAlert()); + if (hasSoarAlertMetadata()) { + hash = (37 * hash) + SOAR_ALERT_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getSoarAlertMetadata().hashCode(); + } + hash = (37 * hash) + DATA_ACCESS_SCOPE_FIELD_NUMBER; + hash = (53 * hash) + getDataAccessScope().hashCode(); + if (getDetectionTimingDetailsCount() > 0) { + hash = (37 * hash) + DETECTION_TIMING_DETAILS_FIELD_NUMBER; + hash = (53 * hash) + detectionTimingDetails_.hashCode(); + } + if (hasLatencyMetrics()) { + hash = (37 * hash) + LATENCY_METRICS_FIELD_NUMBER; + hash = (53 * hash) + getLatencyMetrics().hashCode(); + } + hash = (37 * hash) + RULE_RUN_FREQUENCY_FIELD_NUMBER; + hash = (53 * hash) + ruleRunFrequency_; + hash = (37 * hash) + SIMULATED_EVENT_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSimulatedEventCount()); + if (getSimulatedEventNamesCount() > 0) { + hash = (37 * hash) + SIMULATED_EVENT_NAMES_FIELD_NUMBER; + hash = (53 * hash) + getSimulatedEventNamesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Collection parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Collection parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Collection parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Collection parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Collection parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Collection parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Collection parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Collection parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Collection parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Collection parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Collection parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Collection parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Collection prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Collection represents a container of objects (such as events, entity
+   * context metadata, detection finding metadata) and state (such as
+   * investigation details).
+   *
+   * An example use case for Collection is to model a detection and investigation
+   * from detection finding metadata to investigative state collected in the
+   * course of the investigation. For more complex investigation and response
+   * workflows a Collection could represent an incident consisting of multiple
+   * child findings or incidents. This can be expanded on to model remediation
+   * elements of a full detection and response workflow.
+   * 
+ * + * Protobuf type {@code google.backstory.Collection} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Collection) + com.google.backstory.CollectionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_Collection_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_Collection_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Collection.class, com.google.backstory.Collection.Builder.class); + } + + // Construct using com.google.backstory.Collection.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreatedTimeFieldBuilder(); + internalGetLastUpdatedTimeFieldBuilder(); + internalGetTimeWindowFieldBuilder(); + internalGetCollectionElementsFieldBuilder(); + internalGetDetectionFieldBuilder(); + internalGetDetectionTimeFieldBuilder(); + internalGetInvestigationFieldBuilder(); + internalGetResponsePlatformInfoFieldBuilder(); + internalGetSoarAlertMetadataFieldBuilder(); + internalGetLatencyMetricsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + id_ = ""; + type_ = 0; + idNamespace_ = 0; + createdTime_ = null; + if (createdTimeBuilder_ != null) { + createdTimeBuilder_.dispose(); + createdTimeBuilder_ = null; + } + lastUpdatedTime_ = null; + if (lastUpdatedTimeBuilder_ != null) { + lastUpdatedTimeBuilder_.dispose(); + lastUpdatedTimeBuilder_ = null; + } + timeWindow_ = null; + if (timeWindowBuilder_ != null) { + timeWindowBuilder_.dispose(); + timeWindowBuilder_ = null; + } + if (collectionElementsBuilder_ == null) { + collectionElements_ = java.util.Collections.emptyList(); + } else { + collectionElements_ = null; + collectionElementsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000040); + if (detectionBuilder_ == null) { + detection_ = java.util.Collections.emptyList(); + } else { + detection_ = null; + detectionBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000080); + detectionTime_ = null; + if (detectionTimeBuilder_ != null) { + detectionTimeBuilder_.dispose(); + detectionTimeBuilder_ = null; + } + investigation_ = null; + if (investigationBuilder_ != null) { + investigationBuilder_.dispose(); + investigationBuilder_ = null; + } + tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + responsePlatformInfo_ = null; + if (responsePlatformInfoBuilder_ != null) { + responsePlatformInfoBuilder_.dispose(); + responsePlatformInfoBuilder_ = null; + } + caseName_ = ""; + soarAlert_ = false; + soarAlertMetadata_ = null; + if (soarAlertMetadataBuilder_ != null) { + soarAlertMetadataBuilder_.dispose(); + soarAlertMetadataBuilder_ = null; + } + dataAccessScope_ = ""; + detectionTimingDetails_ = emptyIntList(); + latencyMetrics_ = null; + if (latencyMetricsBuilder_ != null) { + latencyMetricsBuilder_.dispose(); + latencyMetricsBuilder_ = null; + } + ruleRunFrequency_ = 0; + simulatedEventCount_ = 0L; + simulatedEventNames_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_Collection_descriptor; + } + + @java.lang.Override + public com.google.backstory.Collection getDefaultInstanceForType() { + return com.google.backstory.Collection.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Collection build() { + com.google.backstory.Collection result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Collection buildPartial() { + com.google.backstory.Collection result = new com.google.backstory.Collection(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.Collection result) { + if (collectionElementsBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0)) { + collectionElements_ = java.util.Collections.unmodifiableList(collectionElements_); + bitField0_ = (bitField0_ & ~0x00000040); + } + result.collectionElements_ = collectionElements_; + } else { + result.collectionElements_ = collectionElementsBuilder_.build(); + } + if (detectionBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0)) { + detection_ = java.util.Collections.unmodifiableList(detection_); + bitField0_ = (bitField0_ & ~0x00000080); + } + result.detection_ = detection_; + } else { + result.detection_ = detectionBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.Collection result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.id_ = id_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.type_ = type_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.idNamespace_ = idNamespace_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000008) != 0)) { + result.createdTime_ = + createdTimeBuilder_ == null ? createdTime_ : createdTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.lastUpdatedTime_ = + lastUpdatedTimeBuilder_ == null ? lastUpdatedTime_ : lastUpdatedTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.timeWindow_ = timeWindowBuilder_ == null ? timeWindow_ : timeWindowBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.detectionTime_ = + detectionTimeBuilder_ == null ? detectionTime_ : detectionTimeBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.investigation_ = + investigationBuilder_ == null ? investigation_ : investigationBuilder_.build(); + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + tags_.makeImmutable(); + result.tags_ = tags_; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.responsePlatformInfo_ = + responsePlatformInfoBuilder_ == null + ? responsePlatformInfo_ + : responsePlatformInfoBuilder_.build(); + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.caseName_ = caseName_; + } + if (((from_bitField0_ & 0x00002000) != 0)) { + result.soarAlert_ = soarAlert_; + } + if (((from_bitField0_ & 0x00004000) != 0)) { + result.soarAlertMetadata_ = + soarAlertMetadataBuilder_ == null + ? soarAlertMetadata_ + : soarAlertMetadataBuilder_.build(); + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00008000) != 0)) { + result.dataAccessScope_ = dataAccessScope_; + } + if (((from_bitField0_ & 0x00010000) != 0)) { + detectionTimingDetails_.makeImmutable(); + result.detectionTimingDetails_ = detectionTimingDetails_; + } + if (((from_bitField0_ & 0x00020000) != 0)) { + result.latencyMetrics_ = + latencyMetricsBuilder_ == null ? latencyMetrics_ : latencyMetricsBuilder_.build(); + to_bitField0_ |= 0x00000080; + } + if (((from_bitField0_ & 0x00040000) != 0)) { + result.ruleRunFrequency_ = ruleRunFrequency_; + } + if (((from_bitField0_ & 0x00080000) != 0)) { + result.simulatedEventCount_ = simulatedEventCount_; + } + if (((from_bitField0_ & 0x00100000) != 0)) { + simulatedEventNames_.makeImmutable(); + result.simulatedEventNames_ = simulatedEventNames_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Collection) { + return mergeFrom((com.google.backstory.Collection) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Collection other) { + if (other == com.google.backstory.Collection.getDefaultInstance()) return this; + if (!other.getId().isEmpty()) { + id_ = other.id_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + if (other.idNamespace_ != 0) { + setIdNamespaceValue(other.getIdNamespaceValue()); + } + if (other.hasCreatedTime()) { + mergeCreatedTime(other.getCreatedTime()); + } + if (other.hasLastUpdatedTime()) { + mergeLastUpdatedTime(other.getLastUpdatedTime()); + } + if (other.hasTimeWindow()) { + mergeTimeWindow(other.getTimeWindow()); + } + if (collectionElementsBuilder_ == null) { + if (!other.collectionElements_.isEmpty()) { + if (collectionElements_.isEmpty()) { + collectionElements_ = other.collectionElements_; + bitField0_ = (bitField0_ & ~0x00000040); + } else { + ensureCollectionElementsIsMutable(); + collectionElements_.addAll(other.collectionElements_); + } + onChanged(); + } + } else { + if (!other.collectionElements_.isEmpty()) { + if (collectionElementsBuilder_.isEmpty()) { + collectionElementsBuilder_.dispose(); + collectionElementsBuilder_ = null; + collectionElements_ = other.collectionElements_; + bitField0_ = (bitField0_ & ~0x00000040); + collectionElementsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetCollectionElementsFieldBuilder() + : null; + } else { + collectionElementsBuilder_.addAllMessages(other.collectionElements_); + } + } + } + if (detectionBuilder_ == null) { + if (!other.detection_.isEmpty()) { + if (detection_.isEmpty()) { + detection_ = other.detection_; + bitField0_ = (bitField0_ & ~0x00000080); + } else { + ensureDetectionIsMutable(); + detection_.addAll(other.detection_); + } + onChanged(); + } + } else { + if (!other.detection_.isEmpty()) { + if (detectionBuilder_.isEmpty()) { + detectionBuilder_.dispose(); + detectionBuilder_ = null; + detection_ = other.detection_; + bitField0_ = (bitField0_ & ~0x00000080); + detectionBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetDetectionFieldBuilder() + : null; + } else { + detectionBuilder_.addAllMessages(other.detection_); + } + } + } + if (other.hasDetectionTime()) { + mergeDetectionTime(other.getDetectionTime()); + } + if (other.hasInvestigation()) { + mergeInvestigation(other.getInvestigation()); + } + if (!other.tags_.isEmpty()) { + if (tags_.isEmpty()) { + tags_ = other.tags_; + bitField0_ |= 0x00000400; + } else { + ensureTagsIsMutable(); + tags_.addAll(other.tags_); + } + onChanged(); + } + if (other.hasResponsePlatformInfo()) { + mergeResponsePlatformInfo(other.getResponsePlatformInfo()); + } + if (!other.getCaseName().isEmpty()) { + caseName_ = other.caseName_; + bitField0_ |= 0x00001000; + onChanged(); + } + if (other.getSoarAlert() != false) { + setSoarAlert(other.getSoarAlert()); + } + if (other.hasSoarAlertMetadata()) { + mergeSoarAlertMetadata(other.getSoarAlertMetadata()); + } + if (!other.getDataAccessScope().isEmpty()) { + dataAccessScope_ = other.dataAccessScope_; + bitField0_ |= 0x00008000; + onChanged(); + } + if (!other.detectionTimingDetails_.isEmpty()) { + if (detectionTimingDetails_.isEmpty()) { + detectionTimingDetails_ = other.detectionTimingDetails_; + detectionTimingDetails_.makeImmutable(); + bitField0_ |= 0x00010000; + } else { + ensureDetectionTimingDetailsIsMutable(); + detectionTimingDetails_.addAll(other.detectionTimingDetails_); + } + onChanged(); + } + if (other.hasLatencyMetrics()) { + mergeLatencyMetrics(other.getLatencyMetrics()); + } + if (other.ruleRunFrequency_ != 0) { + setRuleRunFrequencyValue(other.getRuleRunFrequencyValue()); + } + if (other.getSimulatedEventCount() != 0L) { + setSimulatedEventCount(other.getSimulatedEventCount()); + } + if (!other.simulatedEventNames_.isEmpty()) { + if (simulatedEventNames_.isEmpty()) { + simulatedEventNames_ = other.simulatedEventNames_; + bitField0_ |= 0x00100000; + } else { + ensureSimulatedEventNamesIsMutable(); + simulatedEventNames_.addAll(other.simulatedEventNames_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + type_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 8 + case 26: + { + com.google.backstory.SecurityResult m = + input.readMessage( + com.google.backstory.SecurityResult.parser(), extensionRegistry); + if (detectionBuilder_ == null) { + ensureDetectionIsMutable(); + detection_.add(m); + } else { + detectionBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetInvestigationFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000200; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetCreatedTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 42 + case 50: + { + input.readMessage( + internalGetLastUpdatedTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 50 + case 58: + { + id_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 58 + case 66: + { + input.readMessage( + internalGetTimeWindowFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 66 + case 74: + { + com.google.backstory.Element m = + input.readMessage(com.google.backstory.Element.parser(), extensionRegistry); + if (collectionElementsBuilder_ == null) { + ensureCollectionElementsIsMutable(); + collectionElements_.add(m); + } else { + collectionElementsBuilder_.addMessage(m); + } + break; + } // case 74 + case 82: + { + input.readMessage( + internalGetDetectionTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 82 + case 90: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureTagsIsMutable(); + tags_.add(s); + break; + } // case 90 + case 96: + { + idNamespace_ = input.readEnum(); + bitField0_ |= 0x00000004; + break; + } // case 96 + case 106: + { + input.readMessage( + internalGetResponsePlatformInfoFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000800; + break; + } // case 106 + case 114: + { + caseName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00001000; + break; + } // case 114 + case 136: + { + soarAlert_ = input.readBool(); + bitField0_ |= 0x00002000; + break; + } // case 136 + case 146: + { + input.readMessage( + internalGetSoarAlertMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00004000; + break; + } // case 146 + case 154: + { + dataAccessScope_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00008000; + break; + } // case 154 + case 160: + { + int tmpRaw = input.readEnum(); + ensureDetectionTimingDetailsIsMutable(); + detectionTimingDetails_.addInt(tmpRaw); + break; + } // case 160 + case 162: + { + int length = input.readRawVarint32(); + int limit = input.pushLimit(length); + ensureDetectionTimingDetailsIsMutable(); + while (input.getBytesUntilLimit() > 0) { + detectionTimingDetails_.addInt(input.readEnum()); + } + input.popLimit(limit); + break; + } // case 162 + case 170: + { + input.readMessage( + internalGetLatencyMetricsFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00020000; + break; + } // case 170 + case 176: + { + ruleRunFrequency_ = input.readEnum(); + bitField0_ |= 0x00040000; + break; + } // case 176 + case 184: + { + simulatedEventCount_ = input.readInt64(); + bitField0_ |= 0x00080000; + break; + } // case 184 + case 194: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureSimulatedEventNamesIsMutable(); + simulatedEventNames_.add(s); + break; + } // case 194 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object id_ = ""; + + /** + * + * + *
+     * Unique ID for the collection.
+     * The ID is specific to the type of collection. For example, with rule
+     * detections this is the detection ID.
+     * 
+ * + * string id = 7; + * + * @return The id. + */ + public java.lang.String getId() { + java.lang.Object ref = id_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Unique ID for the collection.
+     * The ID is specific to the type of collection. For example, with rule
+     * detections this is the detection ID.
+     * 
+ * + * string id = 7; + * + * @return The bytes for id. + */ + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Unique ID for the collection.
+     * The ID is specific to the type of collection. For example, with rule
+     * detections this is the detection ID.
+     * 
+ * + * string id = 7; + * + * @param value The id to set. + * @return This builder for chaining. + */ + public Builder setId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + id_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unique ID for the collection.
+     * The ID is specific to the type of collection. For example, with rule
+     * detections this is the detection ID.
+     * 
+ * + * string id = 7; + * + * @return This builder for chaining. + */ + public Builder clearId() { + id_ = getDefaultInstance().getId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Unique ID for the collection.
+     * The ID is specific to the type of collection. For example, with rule
+     * detections this is the detection ID.
+     * 
+ * + * string id = 7; + * + * @param value The bytes for id to set. + * @return This builder for chaining. + */ + public Builder setIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + id_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int type_ = 0; + + /** + * + * + *
+     * What the collection represents.
+     * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+     * What the collection represents.
+     * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @param value The enum numeric value on the wire for type to set. + * @return This builder for chaining. + */ + public Builder setTypeValue(int value) { + type_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * What the collection represents.
+     * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.backstory.Collection.CollectionType getType() { + com.google.backstory.Collection.CollectionType result = + com.google.backstory.Collection.CollectionType.forNumber(type_); + return result == null ? com.google.backstory.Collection.CollectionType.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * What the collection represents.
+     * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.backstory.Collection.CollectionType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + type_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * What the collection represents.
+     * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return This builder for chaining. + */ + public Builder clearType() { + bitField0_ = (bitField0_ & ~0x00000002); + type_ = 0; + onChanged(); + return this; + } + + private int idNamespace_ = 0; + + /** + * + * + *
+     * The ID namespace used for the Collection.
+     * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return The enum numeric value on the wire for idNamespace. + */ + @java.lang.Override + public int getIdNamespaceValue() { + return idNamespace_; + } + + /** + * + * + *
+     * The ID namespace used for the Collection.
+     * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @param value The enum numeric value on the wire for idNamespace to set. + * @return This builder for chaining. + */ + public Builder setIdNamespaceValue(int value) { + idNamespace_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The ID namespace used for the Collection.
+     * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return The idNamespace. + */ + @java.lang.Override + public com.google.backstory.Id.Namespace getIdNamespace() { + com.google.backstory.Id.Namespace result = + com.google.backstory.Id.Namespace.forNumber(idNamespace_); + return result == null ? com.google.backstory.Id.Namespace.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The ID namespace used for the Collection.
+     * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @param value The idNamespace to set. + * @return This builder for chaining. + */ + public Builder setIdNamespace(com.google.backstory.Id.Namespace value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + idNamespace_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The ID namespace used for the Collection.
+     * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return This builder for chaining. + */ + public Builder clearIdNamespace() { + bitField0_ = (bitField0_ & ~0x00000004); + idNamespace_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createdTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createdTimeBuilder_; + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + * + * @return Whether the createdTime field is set. + */ + public boolean hasCreatedTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + * + * @return The createdTime. + */ + public com.google.protobuf.Timestamp getCreatedTime() { + if (createdTimeBuilder_ == null) { + return createdTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createdTime_; + } else { + return createdTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + public Builder setCreatedTime(com.google.protobuf.Timestamp value) { + if (createdTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createdTime_ = value; + } else { + createdTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + public Builder setCreatedTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createdTimeBuilder_ == null) { + createdTime_ = builderForValue.build(); + } else { + createdTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + public Builder mergeCreatedTime(com.google.protobuf.Timestamp value) { + if (createdTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && createdTime_ != null + && createdTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreatedTimeBuilder().mergeFrom(value); + } else { + createdTime_ = value; + } + } else { + createdTimeBuilder_.mergeFrom(value); + } + if (createdTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + public Builder clearCreatedTime() { + bitField0_ = (bitField0_ & ~0x00000008); + createdTime_ = null; + if (createdTimeBuilder_ != null) { + createdTimeBuilder_.dispose(); + createdTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getCreatedTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetCreatedTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getCreatedTimeOrBuilder() { + if (createdTimeBuilder_ != null) { + return createdTimeBuilder_.getMessageOrBuilder(); + } else { + return createdTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createdTime_; + } + } + + /** + * + * + *
+     * Time the collection was created.
+     * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreatedTimeFieldBuilder() { + if (createdTimeBuilder_ == null) { + createdTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreatedTime(), getParentForChildren(), isClean()); + createdTime_ = null; + } + return createdTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastUpdatedTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastUpdatedTimeBuilder_; + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + * + * @return Whether the lastUpdatedTime field is set. + */ + public boolean hasLastUpdatedTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + * + * @return The lastUpdatedTime. + */ + public com.google.protobuf.Timestamp getLastUpdatedTime() { + if (lastUpdatedTimeBuilder_ == null) { + return lastUpdatedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdatedTime_; + } else { + return lastUpdatedTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + public Builder setLastUpdatedTime(com.google.protobuf.Timestamp value) { + if (lastUpdatedTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastUpdatedTime_ = value; + } else { + lastUpdatedTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + public Builder setLastUpdatedTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastUpdatedTimeBuilder_ == null) { + lastUpdatedTime_ = builderForValue.build(); + } else { + lastUpdatedTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + public Builder mergeLastUpdatedTime(com.google.protobuf.Timestamp value) { + if (lastUpdatedTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && lastUpdatedTime_ != null + && lastUpdatedTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLastUpdatedTimeBuilder().mergeFrom(value); + } else { + lastUpdatedTime_ = value; + } + } else { + lastUpdatedTimeBuilder_.mergeFrom(value); + } + if (lastUpdatedTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + public Builder clearLastUpdatedTime() { + bitField0_ = (bitField0_ & ~0x00000010); + lastUpdatedTime_ = null; + if (lastUpdatedTimeBuilder_ != null) { + lastUpdatedTimeBuilder_.dispose(); + lastUpdatedTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + public com.google.protobuf.Timestamp.Builder getLastUpdatedTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetLastUpdatedTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + public com.google.protobuf.TimestampOrBuilder getLastUpdatedTimeOrBuilder() { + if (lastUpdatedTimeBuilder_ != null) { + return lastUpdatedTimeBuilder_.getMessageOrBuilder(); + } else { + return lastUpdatedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdatedTime_; + } + } + + /** + * + * + *
+     * Time the collection was last updated.
+     * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLastUpdatedTimeFieldBuilder() { + if (lastUpdatedTimeBuilder_ == null) { + lastUpdatedTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastUpdatedTime(), getParentForChildren(), isClean()); + lastUpdatedTime_ = null; + } + return lastUpdatedTimeBuilder_; + } + + private com.google.type.Interval timeWindow_; + private com.google.protobuf.SingleFieldBuilder< + com.google.type.Interval, + com.google.type.Interval.Builder, + com.google.type.IntervalOrBuilder> + timeWindowBuilder_; + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + * + * @return Whether the timeWindow field is set. + */ + public boolean hasTimeWindow() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + * + * @return The timeWindow. + */ + public com.google.type.Interval getTimeWindow() { + if (timeWindowBuilder_ == null) { + return timeWindow_ == null ? com.google.type.Interval.getDefaultInstance() : timeWindow_; + } else { + return timeWindowBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + public Builder setTimeWindow(com.google.type.Interval value) { + if (timeWindowBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + timeWindow_ = value; + } else { + timeWindowBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + public Builder setTimeWindow(com.google.type.Interval.Builder builderForValue) { + if (timeWindowBuilder_ == null) { + timeWindow_ = builderForValue.build(); + } else { + timeWindowBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + public Builder mergeTimeWindow(com.google.type.Interval value) { + if (timeWindowBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && timeWindow_ != null + && timeWindow_ != com.google.type.Interval.getDefaultInstance()) { + getTimeWindowBuilder().mergeFrom(value); + } else { + timeWindow_ = value; + } + } else { + timeWindowBuilder_.mergeFrom(value); + } + if (timeWindow_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + public Builder clearTimeWindow() { + bitField0_ = (bitField0_ & ~0x00000020); + timeWindow_ = null; + if (timeWindowBuilder_ != null) { + timeWindowBuilder_.dispose(); + timeWindowBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + public com.google.type.Interval.Builder getTimeWindowBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetTimeWindowFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + public com.google.type.IntervalOrBuilder getTimeWindowOrBuilder() { + if (timeWindowBuilder_ != null) { + return timeWindowBuilder_.getMessageOrBuilder(); + } else { + return timeWindow_ == null ? com.google.type.Interval.getDefaultInstance() : timeWindow_; + } + } + + /** + * + * + *
+     * Time interval that the collection represents.
+     * 
+ * + * .google.type.Interval time_window = 8; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.type.Interval, + com.google.type.Interval.Builder, + com.google.type.IntervalOrBuilder> + internalGetTimeWindowFieldBuilder() { + if (timeWindowBuilder_ == null) { + timeWindowBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.type.Interval, + com.google.type.Interval.Builder, + com.google.type.IntervalOrBuilder>( + getTimeWindow(), getParentForChildren(), isClean()); + timeWindow_ = null; + } + return timeWindowBuilder_; + } + + private java.util.List collectionElements_ = + java.util.Collections.emptyList(); + + private void ensureCollectionElementsIsMutable() { + if (!((bitField0_ & 0x00000040) != 0)) { + collectionElements_ = + new java.util.ArrayList(collectionElements_); + bitField0_ |= 0x00000040; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Element, + com.google.backstory.Element.Builder, + com.google.backstory.ElementOrBuilder> + collectionElementsBuilder_; + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public java.util.List getCollectionElementsList() { + if (collectionElementsBuilder_ == null) { + return java.util.Collections.unmodifiableList(collectionElements_); + } else { + return collectionElementsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public int getCollectionElementsCount() { + if (collectionElementsBuilder_ == null) { + return collectionElements_.size(); + } else { + return collectionElementsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public com.google.backstory.Element getCollectionElements(int index) { + if (collectionElementsBuilder_ == null) { + return collectionElements_.get(index); + } else { + return collectionElementsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder setCollectionElements(int index, com.google.backstory.Element value) { + if (collectionElementsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCollectionElementsIsMutable(); + collectionElements_.set(index, value); + onChanged(); + } else { + collectionElementsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder setCollectionElements( + int index, com.google.backstory.Element.Builder builderForValue) { + if (collectionElementsBuilder_ == null) { + ensureCollectionElementsIsMutable(); + collectionElements_.set(index, builderForValue.build()); + onChanged(); + } else { + collectionElementsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder addCollectionElements(com.google.backstory.Element value) { + if (collectionElementsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCollectionElementsIsMutable(); + collectionElements_.add(value); + onChanged(); + } else { + collectionElementsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder addCollectionElements(int index, com.google.backstory.Element value) { + if (collectionElementsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCollectionElementsIsMutable(); + collectionElements_.add(index, value); + onChanged(); + } else { + collectionElementsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder addCollectionElements(com.google.backstory.Element.Builder builderForValue) { + if (collectionElementsBuilder_ == null) { + ensureCollectionElementsIsMutable(); + collectionElements_.add(builderForValue.build()); + onChanged(); + } else { + collectionElementsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder addCollectionElements( + int index, com.google.backstory.Element.Builder builderForValue) { + if (collectionElementsBuilder_ == null) { + ensureCollectionElementsIsMutable(); + collectionElements_.add(index, builderForValue.build()); + onChanged(); + } else { + collectionElementsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder addAllCollectionElements( + java.lang.Iterable values) { + if (collectionElementsBuilder_ == null) { + ensureCollectionElementsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, collectionElements_); + onChanged(); + } else { + collectionElementsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder clearCollectionElements() { + if (collectionElementsBuilder_ == null) { + collectionElements_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000040); + onChanged(); + } else { + collectionElementsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public Builder removeCollectionElements(int index) { + if (collectionElementsBuilder_ == null) { + ensureCollectionElementsIsMutable(); + collectionElements_.remove(index); + onChanged(); + } else { + collectionElementsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public com.google.backstory.Element.Builder getCollectionElementsBuilder(int index) { + return internalGetCollectionElementsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public com.google.backstory.ElementOrBuilder getCollectionElementsOrBuilder(int index) { + if (collectionElementsBuilder_ == null) { + return collectionElements_.get(index); + } else { + return collectionElementsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public java.util.List + getCollectionElementsOrBuilderList() { + if (collectionElementsBuilder_ != null) { + return collectionElementsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(collectionElements_); + } + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public com.google.backstory.Element.Builder addCollectionElementsBuilder() { + return internalGetCollectionElementsFieldBuilder() + .addBuilder(com.google.backstory.Element.getDefaultInstance()); + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public com.google.backstory.Element.Builder addCollectionElementsBuilder(int index) { + return internalGetCollectionElementsFieldBuilder() + .addBuilder(index, com.google.backstory.Element.getDefaultInstance()); + } + + /** + * + * + *
+     * Constituent elements of the collection. Each element shares an association
+     * that groups it together and is a component of the overall collection. For
+     * example, a detection collection may have several constituent elements that
+     * each share a correlation association that together represent a particular
+     * pattern or behavior.
+     * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + public java.util.List getCollectionElementsBuilderList() { + return internalGetCollectionElementsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Element, + com.google.backstory.Element.Builder, + com.google.backstory.ElementOrBuilder> + internalGetCollectionElementsFieldBuilder() { + if (collectionElementsBuilder_ == null) { + collectionElementsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.Element, + com.google.backstory.Element.Builder, + com.google.backstory.ElementOrBuilder>( + collectionElements_, + ((bitField0_ & 0x00000040) != 0), + getParentForChildren(), + isClean()); + collectionElements_ = null; + } + return collectionElementsBuilder_; + } + + private java.util.List detection_ = + java.util.Collections.emptyList(); + + private void ensureDetectionIsMutable() { + if (!((bitField0_ & 0x00000080) != 0)) { + detection_ = new java.util.ArrayList(detection_); + bitField0_ |= 0x00000080; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult, + com.google.backstory.SecurityResult.Builder, + com.google.backstory.SecurityResultOrBuilder> + detectionBuilder_; + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public java.util.List getDetectionList() { + if (detectionBuilder_ == null) { + return java.util.Collections.unmodifiableList(detection_); + } else { + return detectionBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public int getDetectionCount() { + if (detectionBuilder_ == null) { + return detection_.size(); + } else { + return detectionBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public com.google.backstory.SecurityResult getDetection(int index) { + if (detectionBuilder_ == null) { + return detection_.get(index); + } else { + return detectionBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder setDetection(int index, com.google.backstory.SecurityResult value) { + if (detectionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectionIsMutable(); + detection_.set(index, value); + onChanged(); + } else { + detectionBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder setDetection( + int index, com.google.backstory.SecurityResult.Builder builderForValue) { + if (detectionBuilder_ == null) { + ensureDetectionIsMutable(); + detection_.set(index, builderForValue.build()); + onChanged(); + } else { + detectionBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder addDetection(com.google.backstory.SecurityResult value) { + if (detectionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectionIsMutable(); + detection_.add(value); + onChanged(); + } else { + detectionBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder addDetection(int index, com.google.backstory.SecurityResult value) { + if (detectionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectionIsMutable(); + detection_.add(index, value); + onChanged(); + } else { + detectionBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder addDetection(com.google.backstory.SecurityResult.Builder builderForValue) { + if (detectionBuilder_ == null) { + ensureDetectionIsMutable(); + detection_.add(builderForValue.build()); + onChanged(); + } else { + detectionBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder addDetection( + int index, com.google.backstory.SecurityResult.Builder builderForValue) { + if (detectionBuilder_ == null) { + ensureDetectionIsMutable(); + detection_.add(index, builderForValue.build()); + onChanged(); + } else { + detectionBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder addAllDetection( + java.lang.Iterable values) { + if (detectionBuilder_ == null) { + ensureDetectionIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, detection_); + onChanged(); + } else { + detectionBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder clearDetection() { + if (detectionBuilder_ == null) { + detection_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + } else { + detectionBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public Builder removeDetection(int index) { + if (detectionBuilder_ == null) { + ensureDetectionIsMutable(); + detection_.remove(index); + onChanged(); + } else { + detectionBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public com.google.backstory.SecurityResult.Builder getDetectionBuilder(int index) { + return internalGetDetectionFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public com.google.backstory.SecurityResultOrBuilder getDetectionOrBuilder(int index) { + if (detectionBuilder_ == null) { + return detection_.get(index); + } else { + return detectionBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public java.util.List + getDetectionOrBuilderList() { + if (detectionBuilder_ != null) { + return detectionBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(detection_); + } + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public com.google.backstory.SecurityResult.Builder addDetectionBuilder() { + return internalGetDetectionFieldBuilder() + .addBuilder(com.google.backstory.SecurityResult.getDefaultInstance()); + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public com.google.backstory.SecurityResult.Builder addDetectionBuilder(int index) { + return internalGetDetectionFieldBuilder() + .addBuilder(index, com.google.backstory.SecurityResult.getDefaultInstance()); + } + + /** + * + * + *
+     * Detection metadata for findings that represent detections, can include
+     * rule details, machine learning model metadata, and indicators implicated
+     * in the detection (using the .about field).
+     * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + public java.util.List getDetectionBuilderList() { + return internalGetDetectionFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult, + com.google.backstory.SecurityResult.Builder, + com.google.backstory.SecurityResultOrBuilder> + internalGetDetectionFieldBuilder() { + if (detectionBuilder_ == null) { + detectionBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.SecurityResult, + com.google.backstory.SecurityResult.Builder, + com.google.backstory.SecurityResultOrBuilder>( + detection_, ((bitField0_ & 0x00000080) != 0), getParentForChildren(), isClean()); + detection_ = null; + } + return detectionBuilder_; + } + + private com.google.protobuf.Timestamp detectionTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + detectionTimeBuilder_; + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + * + * @return Whether the detectionTime field is set. + */ + public boolean hasDetectionTime() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + * + * @return The detectionTime. + */ + public com.google.protobuf.Timestamp getDetectionTime() { + if (detectionTimeBuilder_ == null) { + return detectionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : detectionTime_; + } else { + return detectionTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + public Builder setDetectionTime(com.google.protobuf.Timestamp value) { + if (detectionTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + detectionTime_ = value; + } else { + detectionTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + public Builder setDetectionTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (detectionTimeBuilder_ == null) { + detectionTime_ = builderForValue.build(); + } else { + detectionTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + public Builder mergeDetectionTime(com.google.protobuf.Timestamp value) { + if (detectionTimeBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && detectionTime_ != null + && detectionTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getDetectionTimeBuilder().mergeFrom(value); + } else { + detectionTime_ = value; + } + } else { + detectionTimeBuilder_.mergeFrom(value); + } + if (detectionTime_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + public Builder clearDetectionTime() { + bitField0_ = (bitField0_ & ~0x00000100); + detectionTime_ = null; + if (detectionTimeBuilder_ != null) { + detectionTimeBuilder_.dispose(); + detectionTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + public com.google.protobuf.Timestamp.Builder getDetectionTimeBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return internalGetDetectionTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + public com.google.protobuf.TimestampOrBuilder getDetectionTimeOrBuilder() { + if (detectionTimeBuilder_ != null) { + return detectionTimeBuilder_.getMessageOrBuilder(); + } else { + return detectionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : detectionTime_; + } + } + + /** + * + * + *
+     * Timestamp within the time_window related to the time of the
+     * collection_elements. For Rule Detections, this timestamp is the end of the
+     * the time_window for multi-event rules or the time of the event for single
+     * event rules. For late-arriving events that trigger new alerts, the
+     * detection_time will be the event time of the event.
+     * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetDetectionTimeFieldBuilder() { + if (detectionTimeBuilder_ == null) { + detectionTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getDetectionTime(), getParentForChildren(), isClean()); + detectionTime_ = null; + } + return detectionTimeBuilder_; + } + + private com.google.backstory.Investigation investigation_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Investigation, + com.google.backstory.Investigation.Builder, + com.google.backstory.InvestigationOrBuilder> + investigationBuilder_; + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + * + * @return Whether the investigation field is set. + */ + public boolean hasInvestigation() { + return ((bitField0_ & 0x00000200) != 0); + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + * + * @return The investigation. + */ + public com.google.backstory.Investigation getInvestigation() { + if (investigationBuilder_ == null) { + return investigation_ == null + ? com.google.backstory.Investigation.getDefaultInstance() + : investigation_; + } else { + return investigationBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + public Builder setInvestigation(com.google.backstory.Investigation value) { + if (investigationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + investigation_ = value; + } else { + investigationBuilder_.setMessage(value); + } + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + public Builder setInvestigation(com.google.backstory.Investigation.Builder builderForValue) { + if (investigationBuilder_ == null) { + investigation_ = builderForValue.build(); + } else { + investigationBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + public Builder mergeInvestigation(com.google.backstory.Investigation value) { + if (investigationBuilder_ == null) { + if (((bitField0_ & 0x00000200) != 0) + && investigation_ != null + && investigation_ != com.google.backstory.Investigation.getDefaultInstance()) { + getInvestigationBuilder().mergeFrom(value); + } else { + investigation_ = value; + } + } else { + investigationBuilder_.mergeFrom(value); + } + if (investigation_ != null) { + bitField0_ |= 0x00000200; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + public Builder clearInvestigation() { + bitField0_ = (bitField0_ & ~0x00000200); + investigation_ = null; + if (investigationBuilder_ != null) { + investigationBuilder_.dispose(); + investigationBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + public com.google.backstory.Investigation.Builder getInvestigationBuilder() { + bitField0_ |= 0x00000200; + onChanged(); + return internalGetInvestigationFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + public com.google.backstory.InvestigationOrBuilder getInvestigationOrBuilder() { + if (investigationBuilder_ != null) { + return investigationBuilder_.getMessageOrBuilder(); + } else { + return investigation_ == null + ? com.google.backstory.Investigation.getDefaultInstance() + : investigation_; + } + } + + /** + * + * + *
+     * Consolidated investigation details (categorization, status, etc) typically
+     * for collections that begin as detection findings and then evolve with
+     * analyst action and feedback into investigations around the detection
+     * output.
+     * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Investigation, + com.google.backstory.Investigation.Builder, + com.google.backstory.InvestigationOrBuilder> + internalGetInvestigationFieldBuilder() { + if (investigationBuilder_ == null) { + investigationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.Investigation, + com.google.backstory.Investigation.Builder, + com.google.backstory.InvestigationOrBuilder>( + getInvestigation(), getParentForChildren(), isClean()); + investigation_ = null; + } + return investigationBuilder_; + } + + private com.google.protobuf.LazyStringArrayList tags_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureTagsIsMutable() { + if (!tags_.isModifiable()) { + tags_ = new com.google.protobuf.LazyStringArrayList(tags_); + } + bitField0_ |= 0x00000400; + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @return A list containing the tags. + */ + public com.google.protobuf.ProtocolStringList getTagsList() { + tags_.makeImmutable(); + return tags_; + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @return The count of tags. + */ + public int getTagsCount() { + return tags_.size(); + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @param index The index of the element to return. + * @return The tags at the given index. + */ + public java.lang.String getTags(int index) { + return tags_.get(index); + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @param index The index of the value to return. + * @return The bytes of the tags at the given index. + */ + public com.google.protobuf.ByteString getTagsBytes(int index) { + return tags_.getByteString(index); + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @param index The index to set the value at. + * @param value The tags to set. + * @return This builder for chaining. + */ + public Builder setTags(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureTagsIsMutable(); + tags_.set(index, value); + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @param value The tags to add. + * @return This builder for chaining. + */ + public Builder addTags(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureTagsIsMutable(); + tags_.add(value); + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @param values The tags to add. + * @return This builder for chaining. + */ + public Builder addAllTags(java.lang.Iterable values) { + ensureTagsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tags_); + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @return This builder for chaining. + */ + public Builder clearTags() { + tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000400); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * Tags set by UC/DSML/RE for the Finding during creation.
+     * 
+ * + * repeated string tags = 11; + * + * @param value The bytes of the tags to add. + * @return This builder for chaining. + */ + public Builder addTagsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureTagsIsMutable(); + tags_.add(value); + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + private com.google.backstory.ResponsePlatformInfo responsePlatformInfo_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.ResponsePlatformInfo, + com.google.backstory.ResponsePlatformInfo.Builder, + com.google.backstory.ResponsePlatformInfoOrBuilder> + responsePlatformInfoBuilder_; + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + * + * @return Whether the responsePlatformInfo field is set. + */ + public boolean hasResponsePlatformInfo() { + return ((bitField0_ & 0x00000800) != 0); + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + * + * @return The responsePlatformInfo. + */ + public com.google.backstory.ResponsePlatformInfo getResponsePlatformInfo() { + if (responsePlatformInfoBuilder_ == null) { + return responsePlatformInfo_ == null + ? com.google.backstory.ResponsePlatformInfo.getDefaultInstance() + : responsePlatformInfo_; + } else { + return responsePlatformInfoBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + public Builder setResponsePlatformInfo(com.google.backstory.ResponsePlatformInfo value) { + if (responsePlatformInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + responsePlatformInfo_ = value; + } else { + responsePlatformInfoBuilder_.setMessage(value); + } + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + public Builder setResponsePlatformInfo( + com.google.backstory.ResponsePlatformInfo.Builder builderForValue) { + if (responsePlatformInfoBuilder_ == null) { + responsePlatformInfo_ = builderForValue.build(); + } else { + responsePlatformInfoBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + public Builder mergeResponsePlatformInfo(com.google.backstory.ResponsePlatformInfo value) { + if (responsePlatformInfoBuilder_ == null) { + if (((bitField0_ & 0x00000800) != 0) + && responsePlatformInfo_ != null + && responsePlatformInfo_ + != com.google.backstory.ResponsePlatformInfo.getDefaultInstance()) { + getResponsePlatformInfoBuilder().mergeFrom(value); + } else { + responsePlatformInfo_ = value; + } + } else { + responsePlatformInfoBuilder_.mergeFrom(value); + } + if (responsePlatformInfo_ != null) { + bitField0_ |= 0x00000800; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + public Builder clearResponsePlatformInfo() { + bitField0_ = (bitField0_ & ~0x00000800); + responsePlatformInfo_ = null; + if (responsePlatformInfoBuilder_ != null) { + responsePlatformInfoBuilder_.dispose(); + responsePlatformInfoBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + public com.google.backstory.ResponsePlatformInfo.Builder getResponsePlatformInfoBuilder() { + bitField0_ |= 0x00000800; + onChanged(); + return internalGetResponsePlatformInfoFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + public com.google.backstory.ResponsePlatformInfoOrBuilder getResponsePlatformInfoOrBuilder() { + if (responsePlatformInfoBuilder_ != null) { + return responsePlatformInfoBuilder_.getMessageOrBuilder(); + } else { + return responsePlatformInfo_ == null + ? com.google.backstory.ResponsePlatformInfo.getDefaultInstance() + : responsePlatformInfo_; + } + } + + /** + * + * + *
+     * Alert related info of this same alert in customer's SOAR platform.
+     * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.ResponsePlatformInfo, + com.google.backstory.ResponsePlatformInfo.Builder, + com.google.backstory.ResponsePlatformInfoOrBuilder> + internalGetResponsePlatformInfoFieldBuilder() { + if (responsePlatformInfoBuilder_ == null) { + responsePlatformInfoBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.ResponsePlatformInfo, + com.google.backstory.ResponsePlatformInfo.Builder, + com.google.backstory.ResponsePlatformInfoOrBuilder>( + getResponsePlatformInfo(), getParentForChildren(), isClean()); + responsePlatformInfo_ = null; + } + return responsePlatformInfoBuilder_; + } + + private java.lang.Object caseName_ = ""; + + /** + * + * + *
+     * The resource name of the Case that this collection belongs to.
+     * Example:
+     * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+     * 
+ * + * string case_name = 14; + * + * @return The caseName. + */ + public java.lang.String getCaseName() { + java.lang.Object ref = caseName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + caseName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The resource name of the Case that this collection belongs to.
+     * Example:
+     * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+     * 
+ * + * string case_name = 14; + * + * @return The bytes for caseName. + */ + public com.google.protobuf.ByteString getCaseNameBytes() { + java.lang.Object ref = caseName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + caseName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The resource name of the Case that this collection belongs to.
+     * Example:
+     * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+     * 
+ * + * string case_name = 14; + * + * @param value The caseName to set. + * @return This builder for chaining. + */ + public Builder setCaseName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + caseName_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The resource name of the Case that this collection belongs to.
+     * Example:
+     * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+     * 
+ * + * string case_name = 14; + * + * @return This builder for chaining. + */ + public Builder clearCaseName() { + caseName_ = getDefaultInstance().getCaseName(); + bitField0_ = (bitField0_ & ~0x00001000); + onChanged(); + return this; + } + + /** + * + * + *
+     * The resource name of the Case that this collection belongs to.
+     * Example:
+     * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+     * 
+ * + * string case_name = 14; + * + * @param value The bytes for caseName to set. + * @return This builder for chaining. + */ + public Builder setCaseNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + caseName_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + private boolean soarAlert_; + + /** + * + * + *
+     * A boolean field indicating that the alert is present in SOAR.
+     * 
+ * + * bool soar_alert = 17; + * + * @return The soarAlert. + */ + @java.lang.Override + public boolean getSoarAlert() { + return soarAlert_; + } + + /** + * + * + *
+     * A boolean field indicating that the alert is present in SOAR.
+     * 
+ * + * bool soar_alert = 17; + * + * @param value The soarAlert to set. + * @return This builder for chaining. + */ + public Builder setSoarAlert(boolean value) { + + soarAlert_ = value; + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
+     * A boolean field indicating that the alert is present in SOAR.
+     * 
+ * + * bool soar_alert = 17; + * + * @return This builder for chaining. + */ + public Builder clearSoarAlert() { + bitField0_ = (bitField0_ & ~0x00002000); + soarAlert_ = false; + onChanged(); + return this; + } + + private com.google.backstory.SoarAlertMetadata soarAlertMetadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.SoarAlertMetadata, + com.google.backstory.SoarAlertMetadata.Builder, + com.google.backstory.SoarAlertMetadataOrBuilder> + soarAlertMetadataBuilder_; + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + * + * @return Whether the soarAlertMetadata field is set. + */ + public boolean hasSoarAlertMetadata() { + return ((bitField0_ & 0x00004000) != 0); + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + * + * @return The soarAlertMetadata. + */ + public com.google.backstory.SoarAlertMetadata getSoarAlertMetadata() { + if (soarAlertMetadataBuilder_ == null) { + return soarAlertMetadata_ == null + ? com.google.backstory.SoarAlertMetadata.getDefaultInstance() + : soarAlertMetadata_; + } else { + return soarAlertMetadataBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + public Builder setSoarAlertMetadata(com.google.backstory.SoarAlertMetadata value) { + if (soarAlertMetadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + soarAlertMetadata_ = value; + } else { + soarAlertMetadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + public Builder setSoarAlertMetadata( + com.google.backstory.SoarAlertMetadata.Builder builderForValue) { + if (soarAlertMetadataBuilder_ == null) { + soarAlertMetadata_ = builderForValue.build(); + } else { + soarAlertMetadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + public Builder mergeSoarAlertMetadata(com.google.backstory.SoarAlertMetadata value) { + if (soarAlertMetadataBuilder_ == null) { + if (((bitField0_ & 0x00004000) != 0) + && soarAlertMetadata_ != null + && soarAlertMetadata_ != com.google.backstory.SoarAlertMetadata.getDefaultInstance()) { + getSoarAlertMetadataBuilder().mergeFrom(value); + } else { + soarAlertMetadata_ = value; + } + } else { + soarAlertMetadataBuilder_.mergeFrom(value); + } + if (soarAlertMetadata_ != null) { + bitField0_ |= 0x00004000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + public Builder clearSoarAlertMetadata() { + bitField0_ = (bitField0_ & ~0x00004000); + soarAlertMetadata_ = null; + if (soarAlertMetadataBuilder_ != null) { + soarAlertMetadataBuilder_.dispose(); + soarAlertMetadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + public com.google.backstory.SoarAlertMetadata.Builder getSoarAlertMetadataBuilder() { + bitField0_ |= 0x00004000; + onChanged(); + return internalGetSoarAlertMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + public com.google.backstory.SoarAlertMetadataOrBuilder getSoarAlertMetadataOrBuilder() { + if (soarAlertMetadataBuilder_ != null) { + return soarAlertMetadataBuilder_.getMessageOrBuilder(); + } else { + return soarAlertMetadata_ == null + ? com.google.backstory.SoarAlertMetadata.getDefaultInstance() + : soarAlertMetadata_; + } + } + + /** + * + * + *
+     * Metadata fields of alerts coming from other SIEM systems via SOAR.
+     * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.SoarAlertMetadata, + com.google.backstory.SoarAlertMetadata.Builder, + com.google.backstory.SoarAlertMetadataOrBuilder> + internalGetSoarAlertMetadataFieldBuilder() { + if (soarAlertMetadataBuilder_ == null) { + soarAlertMetadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.SoarAlertMetadata, + com.google.backstory.SoarAlertMetadata.Builder, + com.google.backstory.SoarAlertMetadataOrBuilder>( + getSoarAlertMetadata(), getParentForChildren(), isClean()); + soarAlertMetadata_ = null; + } + return soarAlertMetadataBuilder_; + } + + private java.lang.Object dataAccessScope_ = ""; + + /** + * + * + *
+     * The resource name of the DataAccessScope of this collection.
+     * 
+ * + * string data_access_scope = 19; + * + * @return The dataAccessScope. + */ + public java.lang.String getDataAccessScope() { + java.lang.Object ref = dataAccessScope_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dataAccessScope_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The resource name of the DataAccessScope of this collection.
+     * 
+ * + * string data_access_scope = 19; + * + * @return The bytes for dataAccessScope. + */ + public com.google.protobuf.ByteString getDataAccessScopeBytes() { + java.lang.Object ref = dataAccessScope_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dataAccessScope_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The resource name of the DataAccessScope of this collection.
+     * 
+ * + * string data_access_scope = 19; + * + * @param value The dataAccessScope to set. + * @return This builder for chaining. + */ + public Builder setDataAccessScope(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + dataAccessScope_ = value; + bitField0_ |= 0x00008000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The resource name of the DataAccessScope of this collection.
+     * 
+ * + * string data_access_scope = 19; + * + * @return This builder for chaining. + */ + public Builder clearDataAccessScope() { + dataAccessScope_ = getDefaultInstance().getDataAccessScope(); + bitField0_ = (bitField0_ & ~0x00008000); + onChanged(); + return this; + } + + /** + * + * + *
+     * The resource name of the DataAccessScope of this collection.
+     * 
+ * + * string data_access_scope = 19; + * + * @param value The bytes for dataAccessScope to set. + * @return This builder for chaining. + */ + public Builder setDataAccessScopeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + dataAccessScope_ = value; + bitField0_ |= 0x00008000; + onChanged(); + return this; + } + + private com.google.protobuf.Internal.IntList detectionTimingDetails_ = emptyIntList(); + + private void ensureDetectionTimingDetailsIsMutable() { + if (!detectionTimingDetails_.isModifiable()) { + detectionTimingDetails_ = makeMutableCopy(detectionTimingDetails_); + } + bitField0_ |= 0x00010000; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return A list containing the detectionTimingDetails. + */ + public java.util.List + getDetectionTimingDetailsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.backstory.Collection.DetectionTimingDetails>( + detectionTimingDetails_, detectionTimingDetails_converter_); + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return The count of detectionTimingDetails. + */ + public int getDetectionTimingDetailsCount() { + return detectionTimingDetails_.size(); + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index of the element to return. + * @return The detectionTimingDetails at the given index. + */ + public com.google.backstory.Collection.DetectionTimingDetails getDetectionTimingDetails( + int index) { + return detectionTimingDetails_converter_.convert(detectionTimingDetails_.getInt(index)); + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index to set the value at. + * @param value The detectionTimingDetails to set. + * @return This builder for chaining. + */ + public Builder setDetectionTimingDetails( + int index, com.google.backstory.Collection.DetectionTimingDetails value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectionTimingDetailsIsMutable(); + detectionTimingDetails_.setInt(index, value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param value The detectionTimingDetails to add. + * @return This builder for chaining. + */ + public Builder addDetectionTimingDetails( + com.google.backstory.Collection.DetectionTimingDetails value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectionTimingDetailsIsMutable(); + detectionTimingDetails_.addInt(value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param values The detectionTimingDetails to add. + * @return This builder for chaining. + */ + public Builder addAllDetectionTimingDetails( + java.lang.Iterable + values) { + ensureDetectionTimingDetailsIsMutable(); + for (com.google.backstory.Collection.DetectionTimingDetails value : values) { + detectionTimingDetails_.addInt(value.getNumber()); + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return This builder for chaining. + */ + public Builder clearDetectionTimingDetails() { + detectionTimingDetails_ = emptyIntList(); + bitField0_ = (bitField0_ & ~0x00010000); + onChanged(); + return this; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return A list containing the enum numeric values on the wire for detectionTimingDetails. + */ + public java.util.List getDetectionTimingDetailsValueList() { + detectionTimingDetails_.makeImmutable(); + return detectionTimingDetails_; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of detectionTimingDetails at the given index. + */ + public int getDetectionTimingDetailsValue(int index) { + return detectionTimingDetails_.getInt(index); + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index to set the value at. + * @param value The enum numeric value on the wire for detectionTimingDetails to set. + * @return This builder for chaining. + */ + public Builder setDetectionTimingDetailsValue(int index, int value) { + ensureDetectionTimingDetailsIsMutable(); + detectionTimingDetails_.setInt(index, value); + onChanged(); + return this; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param value The enum numeric value on the wire for detectionTimingDetails to add. + * @return This builder for chaining. + */ + public Builder addDetectionTimingDetailsValue(int value) { + ensureDetectionTimingDetailsIsMutable(); + detectionTimingDetails_.addInt(value); + onChanged(); + return this; + } + + /** + * + * + *
+     * Detection timing details for the collection. These details are used to
+     * determine prossible causes of latency for the detection.
+     * This field is only set for detections that are generated by rules.
+     * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param values The enum numeric values on the wire for detectionTimingDetails to add. + * @return This builder for chaining. + */ + public Builder addAllDetectionTimingDetailsValue(java.lang.Iterable values) { + ensureDetectionTimingDetailsIsMutable(); + for (int value : values) { + detectionTimingDetails_.addInt(value); + } + onChanged(); + return this; + } + + private com.google.backstory.LatencyMetrics latencyMetrics_; + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.LatencyMetrics, + com.google.backstory.LatencyMetrics.Builder, + com.google.backstory.LatencyMetricsOrBuilder> + latencyMetricsBuilder_; + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + * + * @return Whether the latencyMetrics field is set. + */ + public boolean hasLatencyMetrics() { + return ((bitField0_ & 0x00020000) != 0); + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + * + * @return The latencyMetrics. + */ + public com.google.backstory.LatencyMetrics getLatencyMetrics() { + if (latencyMetricsBuilder_ == null) { + return latencyMetrics_ == null + ? com.google.backstory.LatencyMetrics.getDefaultInstance() + : latencyMetrics_; + } else { + return latencyMetricsBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + public Builder setLatencyMetrics(com.google.backstory.LatencyMetrics value) { + if (latencyMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + latencyMetrics_ = value; + } else { + latencyMetricsBuilder_.setMessage(value); + } + bitField0_ |= 0x00020000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + public Builder setLatencyMetrics(com.google.backstory.LatencyMetrics.Builder builderForValue) { + if (latencyMetricsBuilder_ == null) { + latencyMetrics_ = builderForValue.build(); + } else { + latencyMetricsBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00020000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + public Builder mergeLatencyMetrics(com.google.backstory.LatencyMetrics value) { + if (latencyMetricsBuilder_ == null) { + if (((bitField0_ & 0x00020000) != 0) + && latencyMetrics_ != null + && latencyMetrics_ != com.google.backstory.LatencyMetrics.getDefaultInstance()) { + getLatencyMetricsBuilder().mergeFrom(value); + } else { + latencyMetrics_ = value; + } + } else { + latencyMetricsBuilder_.mergeFrom(value); + } + if (latencyMetrics_ != null) { + bitField0_ |= 0x00020000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + public Builder clearLatencyMetrics() { + bitField0_ = (bitField0_ & ~0x00020000); + latencyMetrics_ = null; + if (latencyMetricsBuilder_ != null) { + latencyMetricsBuilder_.dispose(); + latencyMetricsBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + public com.google.backstory.LatencyMetrics.Builder getLatencyMetricsBuilder() { + bitField0_ |= 0x00020000; + onChanged(); + return internalGetLatencyMetricsFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + public com.google.backstory.LatencyMetricsOrBuilder getLatencyMetricsOrBuilder() { + if (latencyMetricsBuilder_ != null) { + return latencyMetricsBuilder_.getMessageOrBuilder(); + } else { + return latencyMetrics_ == null + ? com.google.backstory.LatencyMetrics.getDefaultInstance() + : latencyMetrics_; + } + } + + /** + * + * + *
+     * The latency metrics for the specific detection. These metrics are
+     * calculated from ALL of the events that contribute to the detection, not
+     * just the sampled ones.
+     * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.backstory.LatencyMetrics, + com.google.backstory.LatencyMetrics.Builder, + com.google.backstory.LatencyMetricsOrBuilder> + internalGetLatencyMetricsFieldBuilder() { + if (latencyMetricsBuilder_ == null) { + latencyMetricsBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.backstory.LatencyMetrics, + com.google.backstory.LatencyMetrics.Builder, + com.google.backstory.LatencyMetricsOrBuilder>( + getLatencyMetrics(), getParentForChildren(), isClean()); + latencyMetrics_ = null; + } + return latencyMetricsBuilder_; + } + + private int ruleRunFrequency_ = 0; + + /** + * + * + *
+     * The run frequency of the rule when it generated the detection.
+     * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return The enum numeric value on the wire for ruleRunFrequency. + */ + @java.lang.Override + public int getRuleRunFrequencyValue() { + return ruleRunFrequency_; + } + + /** + * + * + *
+     * The run frequency of the rule when it generated the detection.
+     * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @param value The enum numeric value on the wire for ruleRunFrequency to set. + * @return This builder for chaining. + */ + public Builder setRuleRunFrequencyValue(int value) { + ruleRunFrequency_ = value; + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The run frequency of the rule when it generated the detection.
+     * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return The ruleRunFrequency. + */ + @java.lang.Override + public com.google.backstory.Collection.RunFrequency getRuleRunFrequency() { + com.google.backstory.Collection.RunFrequency result = + com.google.backstory.Collection.RunFrequency.forNumber(ruleRunFrequency_); + return result == null ? com.google.backstory.Collection.RunFrequency.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * The run frequency of the rule when it generated the detection.
+     * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @param value The ruleRunFrequency to set. + * @return This builder for chaining. + */ + public Builder setRuleRunFrequency(com.google.backstory.Collection.RunFrequency value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00040000; + ruleRunFrequency_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * The run frequency of the rule when it generated the detection.
+     * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return This builder for chaining. + */ + public Builder clearRuleRunFrequency() { + bitField0_ = (bitField0_ & ~0x00040000); + ruleRunFrequency_ = 0; + onChanged(); + return this; + } + + private long simulatedEventCount_; + + /** + * + * + *
+     * The total number of simulated events that contributed to this detection.
+     * Simulated events are realistic threat sequences (Raw Logs or UDM)
+     * programmatically delivered into the production ingestion pipeline to verify
+     * the entire detection lifecycle—from identification to action.
+     * 
+ * + * int64 simulated_event_count = 23; + * + * @return The simulatedEventCount. + */ + @java.lang.Override + public long getSimulatedEventCount() { + return simulatedEventCount_; + } + + /** + * + * + *
+     * The total number of simulated events that contributed to this detection.
+     * Simulated events are realistic threat sequences (Raw Logs or UDM)
+     * programmatically delivered into the production ingestion pipeline to verify
+     * the entire detection lifecycle—from identification to action.
+     * 
+ * + * int64 simulated_event_count = 23; + * + * @param value The simulatedEventCount to set. + * @return This builder for chaining. + */ + public Builder setSimulatedEventCount(long value) { + + simulatedEventCount_ = value; + bitField0_ |= 0x00080000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The total number of simulated events that contributed to this detection.
+     * Simulated events are realistic threat sequences (Raw Logs or UDM)
+     * programmatically delivered into the production ingestion pipeline to verify
+     * the entire detection lifecycle—from identification to action.
+     * 
+ * + * int64 simulated_event_count = 23; + * + * @return This builder for chaining. + */ + public Builder clearSimulatedEventCount() { + bitField0_ = (bitField0_ & ~0x00080000); + simulatedEventCount_ = 0L; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList simulatedEventNames_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureSimulatedEventNamesIsMutable() { + if (!simulatedEventNames_.isModifiable()) { + simulatedEventNames_ = new com.google.protobuf.LazyStringArrayList(simulatedEventNames_); + } + bitField0_ |= 0x00100000; + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @return A list containing the simulatedEventNames. + */ + public com.google.protobuf.ProtocolStringList getSimulatedEventNamesList() { + simulatedEventNames_.makeImmutable(); + return simulatedEventNames_; + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @return The count of simulatedEventNames. + */ + public int getSimulatedEventNamesCount() { + return simulatedEventNames_.size(); + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index of the element to return. + * @return The simulatedEventNames at the given index. + */ + public java.lang.String getSimulatedEventNames(int index) { + return simulatedEventNames_.get(index); + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index of the value to return. + * @return The bytes of the simulatedEventNames at the given index. + */ + public com.google.protobuf.ByteString getSimulatedEventNamesBytes(int index) { + return simulatedEventNames_.getByteString(index); + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index to set the value at. + * @param value The simulatedEventNames to set. + * @return This builder for chaining. + */ + public Builder setSimulatedEventNames(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSimulatedEventNamesIsMutable(); + simulatedEventNames_.set(index, value); + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @param value The simulatedEventNames to add. + * @return This builder for chaining. + */ + public Builder addSimulatedEventNames(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSimulatedEventNamesIsMutable(); + simulatedEventNames_.add(value); + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @param values The simulatedEventNames to add. + * @return This builder for chaining. + */ + public Builder addAllSimulatedEventNames(java.lang.Iterable values) { + ensureSimulatedEventNamesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, simulatedEventNames_); + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @return This builder for chaining. + */ + public Builder clearSimulatedEventNames() { + simulatedEventNames_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00100000); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * The set of all values from event ingestion_labels where SIMULATED is set as
+     * the key, for all simulated events that participated in this detection.
+     * 
+ * + * repeated string simulated_event_names = 24; + * + * @param value The bytes of the simulatedEventNames to add. + * @return This builder for chaining. + */ + public Builder addSimulatedEventNamesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureSimulatedEventNamesIsMutable(); + simulatedEventNames_.add(value); + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Collection) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Collection) + private static final com.google.backstory.Collection DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Collection(); + } + + public static com.google.backstory.Collection getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Collection parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.Collection getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java new file mode 100644 index 000000000000..ab48999dee7f --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java @@ -0,0 +1,871 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/collection.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface CollectionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Collection) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Unique ID for the collection.
+   * The ID is specific to the type of collection. For example, with rule
+   * detections this is the detection ID.
+   * 
+ * + * string id = 7; + * + * @return The id. + */ + java.lang.String getId(); + + /** + * + * + *
+   * Unique ID for the collection.
+   * The ID is specific to the type of collection. For example, with rule
+   * detections this is the detection ID.
+   * 
+ * + * string id = 7; + * + * @return The bytes for id. + */ + com.google.protobuf.ByteString getIdBytes(); + + /** + * + * + *
+   * What the collection represents.
+   * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + + /** + * + * + *
+   * What the collection represents.
+   * 
+ * + * .google.backstory.Collection.CollectionType type = 1; + * + * @return The type. + */ + com.google.backstory.Collection.CollectionType getType(); + + /** + * + * + *
+   * The ID namespace used for the Collection.
+   * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return The enum numeric value on the wire for idNamespace. + */ + int getIdNamespaceValue(); + + /** + * + * + *
+   * The ID namespace used for the Collection.
+   * 
+ * + * .google.backstory.Id.Namespace id_namespace = 12; + * + * @return The idNamespace. + */ + com.google.backstory.Id.Namespace getIdNamespace(); + + /** + * + * + *
+   * Time the collection was created.
+   * 
+ * + * .google.protobuf.Timestamp created_time = 5; + * + * @return Whether the createdTime field is set. + */ + boolean hasCreatedTime(); + + /** + * + * + *
+   * Time the collection was created.
+   * 
+ * + * .google.protobuf.Timestamp created_time = 5; + * + * @return The createdTime. + */ + com.google.protobuf.Timestamp getCreatedTime(); + + /** + * + * + *
+   * Time the collection was created.
+   * 
+ * + * .google.protobuf.Timestamp created_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getCreatedTimeOrBuilder(); + + /** + * + * + *
+   * Time the collection was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + * + * @return Whether the lastUpdatedTime field is set. + */ + boolean hasLastUpdatedTime(); + + /** + * + * + *
+   * Time the collection was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + * + * @return The lastUpdatedTime. + */ + com.google.protobuf.Timestamp getLastUpdatedTime(); + + /** + * + * + *
+   * Time the collection was last updated.
+   * 
+ * + * .google.protobuf.Timestamp last_updated_time = 6; + */ + com.google.protobuf.TimestampOrBuilder getLastUpdatedTimeOrBuilder(); + + /** + * + * + *
+   * Time interval that the collection represents.
+   * 
+ * + * .google.type.Interval time_window = 8; + * + * @return Whether the timeWindow field is set. + */ + boolean hasTimeWindow(); + + /** + * + * + *
+   * Time interval that the collection represents.
+   * 
+ * + * .google.type.Interval time_window = 8; + * + * @return The timeWindow. + */ + com.google.type.Interval getTimeWindow(); + + /** + * + * + *
+   * Time interval that the collection represents.
+   * 
+ * + * .google.type.Interval time_window = 8; + */ + com.google.type.IntervalOrBuilder getTimeWindowOrBuilder(); + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + java.util.List getCollectionElementsList(); + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + com.google.backstory.Element getCollectionElements(int index); + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + int getCollectionElementsCount(); + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + java.util.List + getCollectionElementsOrBuilderList(); + + /** + * + * + *
+   * Constituent elements of the collection. Each element shares an association
+   * that groups it together and is a component of the overall collection. For
+   * example, a detection collection may have several constituent elements that
+   * each share a correlation association that together represent a particular
+   * pattern or behavior.
+   * 
+ * + * repeated .google.backstory.Element collection_elements = 9; + */ + com.google.backstory.ElementOrBuilder getCollectionElementsOrBuilder(int index); + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + java.util.List getDetectionList(); + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + com.google.backstory.SecurityResult getDetection(int index); + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + int getDetectionCount(); + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + java.util.List + getDetectionOrBuilderList(); + + /** + * + * + *
+   * Detection metadata for findings that represent detections, can include
+   * rule details, machine learning model metadata, and indicators implicated
+   * in the detection (using the .about field).
+   * 
+ * + * repeated .google.backstory.SecurityResult detection = 3; + */ + com.google.backstory.SecurityResultOrBuilder getDetectionOrBuilder(int index); + + /** + * + * + *
+   * Timestamp within the time_window related to the time of the
+   * collection_elements. For Rule Detections, this timestamp is the end of the
+   * the time_window for multi-event rules or the time of the event for single
+   * event rules. For late-arriving events that trigger new alerts, the
+   * detection_time will be the event time of the event.
+   * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + * + * @return Whether the detectionTime field is set. + */ + boolean hasDetectionTime(); + + /** + * + * + *
+   * Timestamp within the time_window related to the time of the
+   * collection_elements. For Rule Detections, this timestamp is the end of the
+   * the time_window for multi-event rules or the time of the event for single
+   * event rules. For late-arriving events that trigger new alerts, the
+   * detection_time will be the event time of the event.
+   * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + * + * @return The detectionTime. + */ + com.google.protobuf.Timestamp getDetectionTime(); + + /** + * + * + *
+   * Timestamp within the time_window related to the time of the
+   * collection_elements. For Rule Detections, this timestamp is the end of the
+   * the time_window for multi-event rules or the time of the event for single
+   * event rules. For late-arriving events that trigger new alerts, the
+   * detection_time will be the event time of the event.
+   * 
+ * + * .google.protobuf.Timestamp detection_time = 10; + */ + com.google.protobuf.TimestampOrBuilder getDetectionTimeOrBuilder(); + + /** + * + * + *
+   * Consolidated investigation details (categorization, status, etc) typically
+   * for collections that begin as detection findings and then evolve with
+   * analyst action and feedback into investigations around the detection
+   * output.
+   * 
+ * + * .google.backstory.Investigation investigation = 4; + * + * @return Whether the investigation field is set. + */ + boolean hasInvestigation(); + + /** + * + * + *
+   * Consolidated investigation details (categorization, status, etc) typically
+   * for collections that begin as detection findings and then evolve with
+   * analyst action and feedback into investigations around the detection
+   * output.
+   * 
+ * + * .google.backstory.Investigation investigation = 4; + * + * @return The investigation. + */ + com.google.backstory.Investigation getInvestigation(); + + /** + * + * + *
+   * Consolidated investigation details (categorization, status, etc) typically
+   * for collections that begin as detection findings and then evolve with
+   * analyst action and feedback into investigations around the detection
+   * output.
+   * 
+ * + * .google.backstory.Investigation investigation = 4; + */ + com.google.backstory.InvestigationOrBuilder getInvestigationOrBuilder(); + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @return A list containing the tags. + */ + java.util.List getTagsList(); + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @return The count of tags. + */ + int getTagsCount(); + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @param index The index of the element to return. + * @return The tags at the given index. + */ + java.lang.String getTags(int index); + + /** + * + * + *
+   * Tags set by UC/DSML/RE for the Finding during creation.
+   * 
+ * + * repeated string tags = 11; + * + * @param index The index of the value to return. + * @return The bytes of the tags at the given index. + */ + com.google.protobuf.ByteString getTagsBytes(int index); + + /** + * + * + *
+   * Alert related info of this same alert in customer's SOAR platform.
+   * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + * + * @return Whether the responsePlatformInfo field is set. + */ + boolean hasResponsePlatformInfo(); + + /** + * + * + *
+   * Alert related info of this same alert in customer's SOAR platform.
+   * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + * + * @return The responsePlatformInfo. + */ + com.google.backstory.ResponsePlatformInfo getResponsePlatformInfo(); + + /** + * + * + *
+   * Alert related info of this same alert in customer's SOAR platform.
+   * 
+ * + * .google.backstory.ResponsePlatformInfo response_platform_info = 13; + */ + com.google.backstory.ResponsePlatformInfoOrBuilder getResponsePlatformInfoOrBuilder(); + + /** + * + * + *
+   * The resource name of the Case that this collection belongs to.
+   * Example:
+   * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+   * 
+ * + * string case_name = 14; + * + * @return The caseName. + */ + java.lang.String getCaseName(); + + /** + * + * + *
+   * The resource name of the Case that this collection belongs to.
+   * Example:
+   * projects/{project id}/locations/{region}/chronicle/cases/{internal_case_id}
+   * 
+ * + * string case_name = 14; + * + * @return The bytes for caseName. + */ + com.google.protobuf.ByteString getCaseNameBytes(); + + /** + * + * + *
+   * A boolean field indicating that the alert is present in SOAR.
+   * 
+ * + * bool soar_alert = 17; + * + * @return The soarAlert. + */ + boolean getSoarAlert(); + + /** + * + * + *
+   * Metadata fields of alerts coming from other SIEM systems via SOAR.
+   * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + * + * @return Whether the soarAlertMetadata field is set. + */ + boolean hasSoarAlertMetadata(); + + /** + * + * + *
+   * Metadata fields of alerts coming from other SIEM systems via SOAR.
+   * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + * + * @return The soarAlertMetadata. + */ + com.google.backstory.SoarAlertMetadata getSoarAlertMetadata(); + + /** + * + * + *
+   * Metadata fields of alerts coming from other SIEM systems via SOAR.
+   * 
+ * + * .google.backstory.SoarAlertMetadata soar_alert_metadata = 18; + */ + com.google.backstory.SoarAlertMetadataOrBuilder getSoarAlertMetadataOrBuilder(); + + /** + * + * + *
+   * The resource name of the DataAccessScope of this collection.
+   * 
+ * + * string data_access_scope = 19; + * + * @return The dataAccessScope. + */ + java.lang.String getDataAccessScope(); + + /** + * + * + *
+   * The resource name of the DataAccessScope of this collection.
+   * 
+ * + * string data_access_scope = 19; + * + * @return The bytes for dataAccessScope. + */ + com.google.protobuf.ByteString getDataAccessScopeBytes(); + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return A list containing the detectionTimingDetails. + */ + java.util.List + getDetectionTimingDetailsList(); + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return The count of detectionTimingDetails. + */ + int getDetectionTimingDetailsCount(); + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index of the element to return. + * @return The detectionTimingDetails at the given index. + */ + com.google.backstory.Collection.DetectionTimingDetails getDetectionTimingDetails(int index); + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @return A list containing the enum numeric values on the wire for detectionTimingDetails. + */ + java.util.List getDetectionTimingDetailsValueList(); + + /** + * + * + *
+   * Detection timing details for the collection. These details are used to
+   * determine prossible causes of latency for the detection.
+   * This field is only set for detections that are generated by rules.
+   * 
+ * + * + * repeated .google.backstory.Collection.DetectionTimingDetails detection_timing_details = 20; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of detectionTimingDetails at the given index. + */ + int getDetectionTimingDetailsValue(int index); + + /** + * + * + *
+   * The latency metrics for the specific detection. These metrics are
+   * calculated from ALL of the events that contribute to the detection, not
+   * just the sampled ones.
+   * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + * + * @return Whether the latencyMetrics field is set. + */ + boolean hasLatencyMetrics(); + + /** + * + * + *
+   * The latency metrics for the specific detection. These metrics are
+   * calculated from ALL of the events that contribute to the detection, not
+   * just the sampled ones.
+   * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + * + * @return The latencyMetrics. + */ + com.google.backstory.LatencyMetrics getLatencyMetrics(); + + /** + * + * + *
+   * The latency metrics for the specific detection. These metrics are
+   * calculated from ALL of the events that contribute to the detection, not
+   * just the sampled ones.
+   * 
+ * + * .google.backstory.LatencyMetrics latency_metrics = 21; + */ + com.google.backstory.LatencyMetricsOrBuilder getLatencyMetricsOrBuilder(); + + /** + * + * + *
+   * The run frequency of the rule when it generated the detection.
+   * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return The enum numeric value on the wire for ruleRunFrequency. + */ + int getRuleRunFrequencyValue(); + + /** + * + * + *
+   * The run frequency of the rule when it generated the detection.
+   * 
+ * + * .google.backstory.Collection.RunFrequency rule_run_frequency = 22; + * + * @return The ruleRunFrequency. + */ + com.google.backstory.Collection.RunFrequency getRuleRunFrequency(); + + /** + * + * + *
+   * The total number of simulated events that contributed to this detection.
+   * Simulated events are realistic threat sequences (Raw Logs or UDM)
+   * programmatically delivered into the production ingestion pipeline to verify
+   * the entire detection lifecycle—from identification to action.
+   * 
+ * + * int64 simulated_event_count = 23; + * + * @return The simulatedEventCount. + */ + long getSimulatedEventCount(); + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @return A list containing the simulatedEventNames. + */ + java.util.List getSimulatedEventNamesList(); + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @return The count of simulatedEventNames. + */ + int getSimulatedEventNamesCount(); + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index of the element to return. + * @return The simulatedEventNames at the given index. + */ + java.lang.String getSimulatedEventNames(int index); + + /** + * + * + *
+   * The set of all values from event ingestion_labels where SIMULATED is set as
+   * the key, for all simulated events that participated in this detection.
+   * 
+ * + * repeated string simulated_event_names = 24; + * + * @param index The index of the value to return. + * @return The bytes of the simulatedEventNames at the given index. + */ + com.google.protobuf.ByteString getSimulatedEventNamesBytes(int index); +} diff --git a/java-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java b/java-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java new file mode 100644 index 000000000000..0543a6632760 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java @@ -0,0 +1,285 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/collection.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public final class CollectionOuterClass extends com.google.protobuf.GeneratedFile { + private CollectionOuterClass() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "CollectionOuterClass"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_Collection_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_Collection_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_EntityGraphEnrichment_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_EntityGraphEnrichment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_DataTableRowInfo_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_DataTableRowInfo_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_LatencyMetrics_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_LatencyMetrics_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_Reference_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_Reference_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_Element_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_Element_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_ResponsePlatformInfo_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_ResponsePlatformInfo_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_SoarAlertMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_SoarAlertMetadata_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "\032backstory/collection.proto\022\020google.bac" + + "kstory\032\026backstory/entity.proto\032\022backstor" + + "y/id.proto\032\023backstory/udm.proto\032\036google/" + + "protobuf/duration.proto\032\034google/protobuf" + + "/struct.proto\032\037google/protobuf/timestamp.proto\032\032google/type/interval.proto\"\302\013\n\n" + + "Collection\022\n\n" + + "\002id\030\007 \001(\t\0229\n" + + "\004type\030\001 \001(\0162+.google.backstory.Collection.CollectionType\0224\n" + + "\014id_namespace\030\014 \001(\0162\036.google.backstory.Id.Namespace\0220\n" + + "\014created_time\030\005 \001(\0132\032.google.protobuf.Timestamp\0225\n" + + "\021last_updated_time\030\006 \001(\0132\032.google.protobuf.Timestamp\022*\n" + + "\013time_window\030\010 \001(\0132\025.google.type.Interval\0226\n" + + "\023collection_elements\030\t \003(\0132\031.google.backstory.Element\0223\n" + + "\tdetection\030\003 \003(\0132 .google.backstory.SecurityResult\0222\n" + + "\016detection_time\030\n" + + " \001(\0132\032.google.protobuf.Timestamp\0226\n\r" + + "investigation\030\004 \001(\0132\037.google.backstory.Investigation\022\014\n" + + "\004tags\030\013 \003(\t\022F\n" + + "\026response_platform_info\030\r" + + " \001(\0132&.google.backstory.ResponsePlatformInfo\022\021\n" + + "\tcase_name\030\016 \001(\t\022\022\n\n" + + "soar_alert\030\021 \001(\010\022@\n" + + "\023soar_alert_metadata\030\022" + + " \001(\0132#.google.backstory.SoarAlertMetadata\022\031\n" + + "\021data_access_scope\030\023 \001(\t\022U\n" + + "\030detection_timing_details\030\024 \003(\01623.googl" + + "e.backstory.Collection.DetectionTimingDetails\0229\n" + + "\017latency_metrics\030\025 \001(\0132 .google.backstory.LatencyMetrics\022E\n" + + "\022rule_run_frequency\030\026" + + " \001(\0162).google.backstory.Collection.RunFrequency\022\035\n" + + "\025simulated_event_count\030\027 \001(\003\022\035\n" + + "\025simulated_event_names\030\030 \003(\t\"\265\001\n" + + "\016CollectionType\022\037\n" + + "\033COLLECTION_TYPE_UNSPECIFIED\020\000\022\023\n" + + "\017TELEMETRY_ALERT\020\001\022\020\n" + + "\014GCTI_FINDING\020\002\022\023\n" + + "\017UPPERCASE_ALERT\020\002\022\022\n" + + "\016RULE_DETECTION\020\003\022\036\n" + + "\032MACHINE_INTELLIGENCE_ALERT\020\004\022\016\n\n" + + "SOAR_ALERT\020\005\032\002\020\001\"\225\001\n" + + "\026DetectionTimingDetails\022(\n" + + "$DETECTION_TIMING_DETAILS_UNSPECIFIED\020\000\022)\n" + + "%DETECTION_TIMING_DETAILS_REPROCESSING\020\001\022&\n" + + "\"DETECTION_TIMING_DETAILS_RETROHUNT\020\002\"|\n" + + "\014RunFrequency\022\035\n" + + "\031RUN_FREQUENCY_UNSPECIFIED\020\000\022\032\n" + + "\026RUN_FREQUENCY_REALTIME\020\001\022\030\n" + + "\024RUN_FREQUENCY_HOURLY\020\002\022\027\n" + + "\023RUN_FREQUENCY_DAILY\020\003J\004\010\017\020\020J\004\010\020\020\021\"\376\001\n" + + "\025EntityGraphEnrichment\022\022\n\n" + + "data_table\030\001 \001(\t\022O\n" + + "\017enrichment_type\030\003 \001(\01626.google.backstor" + + "y.EntityGraphEnrichment.EnrichmentType\0223\n" + + "\021overridden_entity\030\002 \001(\0132\030.google.backstory.Entity\"K\n" + + "\016EnrichmentType\022\037\n" + + "\033ENRICHMENT_TYPE_UNSPECIFIED\020\000\022\n\n" + + "\006APPEND\020\001\022\014\n" + + "\010OVERRIDE\020\002\"\\\n" + + "\020DataTableRowInfo\022\022\n\n" + + "data_table\030\001 \001(\t\022$\n" + + "\003row\030\002 \001(\0132\027.google.protobuf.Struct\022\016\n" + + "\006row_id\030\003 \001(\t\"\252\002\n" + + "\016LatencyMetrics\0229\n" + + "\025oldest_ingestion_time\030\001 \001(\0132\032.google.protobuf.Timestamp\0229\n" + + "\025newest_ingestion_time\030\002 \001(\0132\032.google.protobuf.Timestamp\0225\n" + + "\021oldest_event_time\030\003 \001(\0132\032.google.protobuf.Timestamp\0225\n" + + "\021newest_event_time\030\004 \001(\0132\032.google.protobuf.Timestamp\0224\n" + + "\021ingestion_latency\030\005 \001(\0132\031.google.protobuf.Duration\"\235\002\n" + + "\tReference\022$\n" + + "\005event\030\001 \001(\0132\025.google.backstory.UDM\022(\n" + + "\006entity\030\002 \001(\0132\030.google.backstory.Entity\022B\n" + + "\026joined_data_table_rows\030\004" + + " \003(\0132\".google.backstory.DataTableRowInfo\022A\n" + + "\020graph_enrichment\030\005 \001(\0132\'.google.backstory.EntityGraphEnrichment\022" + + " \n" + + "\002id\030\003 \001(\0132\024.google.backstory.Id\022\027\n" + + "\017log_batch_token\030\006 \001(\t\"\327\001\n" + + "\007Element\0225\n" + + "\013association\030\001 \001(\0132 .google.backstory.SecurityResult\022/\n\n" + + "references\030\002 \003(\0132\033.google.backstory.Reference\022\r\n" + + "\005label\030\003 \001(\t\022\032\n" + + "\022references_sampled\030\004 \001(\010\0229\n" + + "\017latency_metrics\030\005 \001(\0132 .google.backstory.LatencyMetrics\"\353\001\n" + + "\024ResponsePlatformInfo\022\020\n" + + "\010alert_id\030\002 \001(\t\022[\n" + + "\026response_platform_type\030\003 \001(\0162;.google.backst" + + "ory.ResponsePlatformInfo.ResponsePlatformType\"d\n" + + "\024ResponsePlatformType\022&\n" + + "\"RESPONSE_PLATFORM_TYPE_UNSPECIFIED\020\000\022$\n" + + " RESPONSE_PLATFORM_TYPE_SIEMPLIFY\020\001\"\256\001\n" + + "\021SoarAlertMetadata\022\020\n" + + "\010alert_id\030\001 \001(\t\022\023\n" + + "\013source_rule\030\002 \001(\t\022\016\n" + + "\006vendor\030\003 \001(\t\022\025\n\r" + + "source_system\030\004 \001(\t\022\017\n" + + "\007product\030\005 \001(\t\022\037\n" + + "\027source_system_ticket_id\030\006 \001(\t\022\031\n" + + "\021source_system_uri\030\007 \001(\tB\215\001\n" + + "\024com.google.backstoryP\001Z9google.golang.org/genproto/googleapis/backstory" + + ";backstory\252\002\020Google.Backstory\312\002\020Google\\B" + + "ackstory\352\002\021Google::Backstoryb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.backstory.EntityProto.getDescriptor(), + com.google.backstory.IdOuterClass.getDescriptor(), + com.google.backstory.Udm.getDescriptor(), + com.google.protobuf.DurationProto.getDescriptor(), + com.google.protobuf.StructProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + com.google.type.IntervalProto.getDescriptor(), + }); + internal_static_google_backstory_Collection_descriptor = getDescriptor().getMessageType(0); + internal_static_google_backstory_Collection_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_Collection_descriptor, + new java.lang.String[] { + "Id", + "Type", + "IdNamespace", + "CreatedTime", + "LastUpdatedTime", + "TimeWindow", + "CollectionElements", + "Detection", + "DetectionTime", + "Investigation", + "Tags", + "ResponsePlatformInfo", + "CaseName", + "SoarAlert", + "SoarAlertMetadata", + "DataAccessScope", + "DetectionTimingDetails", + "LatencyMetrics", + "RuleRunFrequency", + "SimulatedEventCount", + "SimulatedEventNames", + }); + internal_static_google_backstory_EntityGraphEnrichment_descriptor = + getDescriptor().getMessageType(1); + internal_static_google_backstory_EntityGraphEnrichment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_EntityGraphEnrichment_descriptor, + new java.lang.String[] { + "DataTable", "EnrichmentType", "OverriddenEntity", + }); + internal_static_google_backstory_DataTableRowInfo_descriptor = + getDescriptor().getMessageType(2); + internal_static_google_backstory_DataTableRowInfo_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_DataTableRowInfo_descriptor, + new java.lang.String[] { + "DataTable", "Row", "RowId", + }); + internal_static_google_backstory_LatencyMetrics_descriptor = getDescriptor().getMessageType(3); + internal_static_google_backstory_LatencyMetrics_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_LatencyMetrics_descriptor, + new java.lang.String[] { + "OldestIngestionTime", + "NewestIngestionTime", + "OldestEventTime", + "NewestEventTime", + "IngestionLatency", + }); + internal_static_google_backstory_Reference_descriptor = getDescriptor().getMessageType(4); + internal_static_google_backstory_Reference_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_Reference_descriptor, + new java.lang.String[] { + "Event", "Entity", "JoinedDataTableRows", "GraphEnrichment", "Id", "LogBatchToken", + }); + internal_static_google_backstory_Element_descriptor = getDescriptor().getMessageType(5); + internal_static_google_backstory_Element_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_Element_descriptor, + new java.lang.String[] { + "Association", "References", "Label", "ReferencesSampled", "LatencyMetrics", + }); + internal_static_google_backstory_ResponsePlatformInfo_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_backstory_ResponsePlatformInfo_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_ResponsePlatformInfo_descriptor, + new java.lang.String[] { + "AlertId", "ResponsePlatformType", + }); + internal_static_google_backstory_SoarAlertMetadata_descriptor = + getDescriptor().getMessageType(7); + internal_static_google_backstory_SoarAlertMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_SoarAlertMetadata_descriptor, + new java.lang.String[] { + "AlertId", + "SourceRule", + "Vendor", + "SourceSystem", + "Product", + "SourceSystemTicketId", + "SourceSystemUri", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.backstory.EntityProto.getDescriptor(); + com.google.backstory.IdOuterClass.getDescriptor(); + com.google.backstory.Udm.getDescriptor(); + com.google.protobuf.DurationProto.getDescriptor(); + com.google.protobuf.StructProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.type.IntervalProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-backstory/src/main/java/com/google/backstory/DNSRecord.java b/java-backstory/src/main/java/com/google/backstory/DNSRecord.java new file mode 100644 index 000000000000..125c26072e4a --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DNSRecord.java @@ -0,0 +1,2337 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * DNS record.
+ * 
+ * + * Protobuf type {@code google.backstory.DNSRecord} + */ +@com.google.protobuf.Generated +public final class DNSRecord extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.DNSRecord) + DNSRecordOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DNSRecord"); + } + + // Use DNSRecord.newBuilder() to construct. + private DNSRecord(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DNSRecord() { + type_ = ""; + value_ = ""; + rname_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_DNSRecord_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_DNSRecord_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DNSRecord.class, com.google.backstory.DNSRecord.Builder.class); + } + + private int bitField0_; + public static final int TYPE_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object type_ = ""; + + /** + * + * + *
+   * Type.
+   * 
+ * + * string type = 1; + * + * @return The type. + */ + @java.lang.Override + public java.lang.String getType() { + java.lang.Object ref = type_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + type_ = s; + return s; + } + } + + /** + * + * + *
+   * Type.
+   * 
+ * + * string type = 1; + * + * @return The bytes for type. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTypeBytes() { + java.lang.Object ref = type_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + type_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALUE_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object value_ = ""; + + /** + * + * + *
+   * Value.
+   * 
+ * + * string value = 2; + * + * @return The value. + */ + @java.lang.Override + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } + } + + /** + * + * + *
+   * Value.
+   * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + @java.lang.Override + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TTL_FIELD_NUMBER = 3; + private com.google.protobuf.Duration ttl_; + + /** + * + * + *
+   * Time to live.
+   * 
+ * + * .google.protobuf.Duration ttl = 3; + * + * @return Whether the ttl field is set. + */ + @java.lang.Override + public boolean hasTtl() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Time to live.
+   * 
+ * + * .google.protobuf.Duration ttl = 3; + * + * @return The ttl. + */ + @java.lang.Override + public com.google.protobuf.Duration getTtl() { + return ttl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : ttl_; + } + + /** + * + * + *
+   * Time to live.
+   * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getTtlOrBuilder() { + return ttl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : ttl_; + } + + public static final int PRIORITY_FIELD_NUMBER = 4; + private long priority_ = 0L; + + /** + * + * + *
+   * Priority.
+   * 
+ * + * int64 priority = 4; + * + * @return The priority. + */ + @java.lang.Override + public long getPriority() { + return priority_; + } + + public static final int RETRY_FIELD_NUMBER = 5; + private long retry_ = 0L; + + /** + * + * + *
+   * Retry.
+   * 
+ * + * int64 retry = 5; + * + * @return The retry. + */ + @java.lang.Override + public long getRetry() { + return retry_; + } + + public static final int REFRESH_FIELD_NUMBER = 6; + private com.google.protobuf.Duration refresh_; + + /** + * + * + *
+   * Refresh.
+   * 
+ * + * .google.protobuf.Duration refresh = 6; + * + * @return Whether the refresh field is set. + */ + @java.lang.Override + public boolean hasRefresh() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Refresh.
+   * 
+ * + * .google.protobuf.Duration refresh = 6; + * + * @return The refresh. + */ + @java.lang.Override + public com.google.protobuf.Duration getRefresh() { + return refresh_ == null ? com.google.protobuf.Duration.getDefaultInstance() : refresh_; + } + + /** + * + * + *
+   * Refresh.
+   * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getRefreshOrBuilder() { + return refresh_ == null ? com.google.protobuf.Duration.getDefaultInstance() : refresh_; + } + + public static final int MINIMUM_FIELD_NUMBER = 7; + private com.google.protobuf.Duration minimum_; + + /** + * + * + *
+   * Minimum.
+   * 
+ * + * .google.protobuf.Duration minimum = 7; + * + * @return Whether the minimum field is set. + */ + @java.lang.Override + public boolean hasMinimum() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Minimum.
+   * 
+ * + * .google.protobuf.Duration minimum = 7; + * + * @return The minimum. + */ + @java.lang.Override + public com.google.protobuf.Duration getMinimum() { + return minimum_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minimum_; + } + + /** + * + * + *
+   * Minimum.
+   * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getMinimumOrBuilder() { + return minimum_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minimum_; + } + + public static final int EXPIRE_FIELD_NUMBER = 8; + private com.google.protobuf.Duration expire_; + + /** + * + * + *
+   * Expire.
+   * 
+ * + * .google.protobuf.Duration expire = 8; + * + * @return Whether the expire field is set. + */ + @java.lang.Override + public boolean hasExpire() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+   * Expire.
+   * 
+ * + * .google.protobuf.Duration expire = 8; + * + * @return The expire. + */ + @java.lang.Override + public com.google.protobuf.Duration getExpire() { + return expire_ == null ? com.google.protobuf.Duration.getDefaultInstance() : expire_; + } + + /** + * + * + *
+   * Expire.
+   * 
+ * + * .google.protobuf.Duration expire = 8; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getExpireOrBuilder() { + return expire_ == null ? com.google.protobuf.Duration.getDefaultInstance() : expire_; + } + + public static final int SERIAL_FIELD_NUMBER = 9; + private long serial_ = 0L; + + /** + * + * + *
+   * Serial.
+   * 
+ * + * int64 serial = 9; + * + * @return The serial. + */ + @java.lang.Override + public long getSerial() { + return serial_; + } + + public static final int RNAME_FIELD_NUMBER = 10; + + @SuppressWarnings("serial") + private volatile java.lang.Object rname_ = ""; + + /** + * + * + *
+   * Rname.
+   * 
+ * + * string rname = 10; + * + * @return The rname. + */ + @java.lang.Override + public java.lang.String getRname() { + java.lang.Object ref = rname_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + rname_ = s; + return s; + } + } + + /** + * + * + *
+   * Rname.
+   * 
+ * + * string rname = 10; + * + * @return The bytes for rname. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRnameBytes() { + java.lang.Object ref = rname_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + rname_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(type_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, type_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(value_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, value_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getTtl()); + } + if (priority_ != 0L) { + output.writeInt64(4, priority_); + } + if (retry_ != 0L) { + output.writeInt64(5, retry_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getRefresh()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(7, getMinimum()); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(8, getExpire()); + } + if (serial_ != 0L) { + output.writeInt64(9, serial_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(rname_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 10, rname_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(type_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, type_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(value_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, value_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTtl()); + } + if (priority_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(4, priority_); + } + if (retry_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(5, retry_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getRefresh()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getMinimum()); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getExpire()); + } + if (serial_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(9, serial_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(rname_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(10, rname_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.DNSRecord)) { + return super.equals(obj); + } + com.google.backstory.DNSRecord other = (com.google.backstory.DNSRecord) obj; + + if (!getType().equals(other.getType())) return false; + if (!getValue().equals(other.getValue())) return false; + if (hasTtl() != other.hasTtl()) return false; + if (hasTtl()) { + if (!getTtl().equals(other.getTtl())) return false; + } + if (getPriority() != other.getPriority()) return false; + if (getRetry() != other.getRetry()) return false; + if (hasRefresh() != other.hasRefresh()) return false; + if (hasRefresh()) { + if (!getRefresh().equals(other.getRefresh())) return false; + } + if (hasMinimum() != other.hasMinimum()) return false; + if (hasMinimum()) { + if (!getMinimum().equals(other.getMinimum())) return false; + } + if (hasExpire() != other.hasExpire()) return false; + if (hasExpire()) { + if (!getExpire().equals(other.getExpire())) return false; + } + if (getSerial() != other.getSerial()) return false; + if (!getRname().equals(other.getRname())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + getType().hashCode(); + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + if (hasTtl()) { + hash = (37 * hash) + TTL_FIELD_NUMBER; + hash = (53 * hash) + getTtl().hashCode(); + } + hash = (37 * hash) + PRIORITY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getPriority()); + hash = (37 * hash) + RETRY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getRetry()); + if (hasRefresh()) { + hash = (37 * hash) + REFRESH_FIELD_NUMBER; + hash = (53 * hash) + getRefresh().hashCode(); + } + if (hasMinimum()) { + hash = (37 * hash) + MINIMUM_FIELD_NUMBER; + hash = (53 * hash) + getMinimum().hashCode(); + } + if (hasExpire()) { + hash = (37 * hash) + EXPIRE_FIELD_NUMBER; + hash = (53 * hash) + getExpire().hashCode(); + } + hash = (37 * hash) + SERIAL_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSerial()); + hash = (37 * hash) + RNAME_FIELD_NUMBER; + hash = (53 * hash) + getRname().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.DNSRecord parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DNSRecord parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DNSRecord parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DNSRecord parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DNSRecord parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DNSRecord parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DNSRecord parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DNSRecord parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DNSRecord parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.DNSRecord parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DNSRecord parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DNSRecord parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.DNSRecord prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * DNS record.
+   * 
+ * + * Protobuf type {@code google.backstory.DNSRecord} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.DNSRecord) + com.google.backstory.DNSRecordOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_DNSRecord_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_DNSRecord_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DNSRecord.class, com.google.backstory.DNSRecord.Builder.class); + } + + // Construct using com.google.backstory.DNSRecord.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetTtlFieldBuilder(); + internalGetRefreshFieldBuilder(); + internalGetMinimumFieldBuilder(); + internalGetExpireFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + type_ = ""; + value_ = ""; + ttl_ = null; + if (ttlBuilder_ != null) { + ttlBuilder_.dispose(); + ttlBuilder_ = null; + } + priority_ = 0L; + retry_ = 0L; + refresh_ = null; + if (refreshBuilder_ != null) { + refreshBuilder_.dispose(); + refreshBuilder_ = null; + } + minimum_ = null; + if (minimumBuilder_ != null) { + minimumBuilder_.dispose(); + minimumBuilder_ = null; + } + expire_ = null; + if (expireBuilder_ != null) { + expireBuilder_.dispose(); + expireBuilder_ = null; + } + serial_ = 0L; + rname_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_DNSRecord_descriptor; + } + + @java.lang.Override + public com.google.backstory.DNSRecord getDefaultInstanceForType() { + return com.google.backstory.DNSRecord.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.DNSRecord build() { + com.google.backstory.DNSRecord result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.DNSRecord buildPartial() { + com.google.backstory.DNSRecord result = new com.google.backstory.DNSRecord(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.DNSRecord result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.type_ = type_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.value_ = value_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.ttl_ = ttlBuilder_ == null ? ttl_ : ttlBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.priority_ = priority_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.retry_ = retry_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.refresh_ = refreshBuilder_ == null ? refresh_ : refreshBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.minimum_ = minimumBuilder_ == null ? minimum_ : minimumBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.expire_ = expireBuilder_ == null ? expire_ : expireBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.serial_ = serial_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.rname_ = rname_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.DNSRecord) { + return mergeFrom((com.google.backstory.DNSRecord) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.DNSRecord other) { + if (other == com.google.backstory.DNSRecord.getDefaultInstance()) return this; + if (!other.getType().isEmpty()) { + type_ = other.type_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getValue().isEmpty()) { + value_ = other.value_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasTtl()) { + mergeTtl(other.getTtl()); + } + if (other.getPriority() != 0L) { + setPriority(other.getPriority()); + } + if (other.getRetry() != 0L) { + setRetry(other.getRetry()); + } + if (other.hasRefresh()) { + mergeRefresh(other.getRefresh()); + } + if (other.hasMinimum()) { + mergeMinimum(other.getMinimum()); + } + if (other.hasExpire()) { + mergeExpire(other.getExpire()); + } + if (other.getSerial() != 0L) { + setSerial(other.getSerial()); + } + if (!other.getRname().isEmpty()) { + rname_ = other.rname_; + bitField0_ |= 0x00000200; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + type_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + value_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(internalGetTtlFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + priority_ = input.readInt64(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 40: + { + retry_ = input.readInt64(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 50: + { + input.readMessage(internalGetRefreshFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 58: + { + input.readMessage(internalGetMinimumFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 66: + { + input.readMessage(internalGetExpireFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000080; + break; + } // case 66 + case 72: + { + serial_ = input.readInt64(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 82: + { + rname_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000200; + break; + } // case 82 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object type_ = ""; + + /** + * + * + *
+     * Type.
+     * 
+ * + * string type = 1; + * + * @return The type. + */ + public java.lang.String getType() { + java.lang.Object ref = type_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + type_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Type.
+     * 
+ * + * string type = 1; + * + * @return The bytes for type. + */ + public com.google.protobuf.ByteString getTypeBytes() { + java.lang.Object ref = type_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + type_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Type.
+     * 
+ * + * string type = 1; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + type_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Type.
+     * 
+ * + * string type = 1; + * + * @return This builder for chaining. + */ + public Builder clearType() { + type_ = getDefaultInstance().getType(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Type.
+     * 
+ * + * string type = 1; + * + * @param value The bytes for type to set. + * @return This builder for chaining. + */ + public Builder setTypeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + type_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object value_ = ""; + + /** + * + * + *
+     * Value.
+     * 
+ * + * string value = 2; + * + * @return The value. + */ + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Value.
+     * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Value.
+     * 
+ * + * string value = 2; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Value.
+     * 
+ * + * string value = 2; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + value_ = getDefaultInstance().getValue(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Value.
+     * 
+ * + * string value = 2; + * + * @param value The bytes for value to set. + * @return This builder for chaining. + */ + public Builder setValueBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Duration ttl_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + ttlBuilder_; + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + * + * @return Whether the ttl field is set. + */ + public boolean hasTtl() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + * + * @return The ttl. + */ + public com.google.protobuf.Duration getTtl() { + if (ttlBuilder_ == null) { + return ttl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : ttl_; + } else { + return ttlBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + public Builder setTtl(com.google.protobuf.Duration value) { + if (ttlBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ttl_ = value; + } else { + ttlBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + public Builder setTtl(com.google.protobuf.Duration.Builder builderForValue) { + if (ttlBuilder_ == null) { + ttl_ = builderForValue.build(); + } else { + ttlBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + public Builder mergeTtl(com.google.protobuf.Duration value) { + if (ttlBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && ttl_ != null + && ttl_ != com.google.protobuf.Duration.getDefaultInstance()) { + getTtlBuilder().mergeFrom(value); + } else { + ttl_ = value; + } + } else { + ttlBuilder_.mergeFrom(value); + } + if (ttl_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + public Builder clearTtl() { + bitField0_ = (bitField0_ & ~0x00000004); + ttl_ = null; + if (ttlBuilder_ != null) { + ttlBuilder_.dispose(); + ttlBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + public com.google.protobuf.Duration.Builder getTtlBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetTtlFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + public com.google.protobuf.DurationOrBuilder getTtlOrBuilder() { + if (ttlBuilder_ != null) { + return ttlBuilder_.getMessageOrBuilder(); + } else { + return ttl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : ttl_; + } + } + + /** + * + * + *
+     * Time to live.
+     * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + internalGetTtlFieldBuilder() { + if (ttlBuilder_ == null) { + ttlBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>(getTtl(), getParentForChildren(), isClean()); + ttl_ = null; + } + return ttlBuilder_; + } + + private long priority_; + + /** + * + * + *
+     * Priority.
+     * 
+ * + * int64 priority = 4; + * + * @return The priority. + */ + @java.lang.Override + public long getPriority() { + return priority_; + } + + /** + * + * + *
+     * Priority.
+     * 
+ * + * int64 priority = 4; + * + * @param value The priority to set. + * @return This builder for chaining. + */ + public Builder setPriority(long value) { + + priority_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Priority.
+     * 
+ * + * int64 priority = 4; + * + * @return This builder for chaining. + */ + public Builder clearPriority() { + bitField0_ = (bitField0_ & ~0x00000008); + priority_ = 0L; + onChanged(); + return this; + } + + private long retry_; + + /** + * + * + *
+     * Retry.
+     * 
+ * + * int64 retry = 5; + * + * @return The retry. + */ + @java.lang.Override + public long getRetry() { + return retry_; + } + + /** + * + * + *
+     * Retry.
+     * 
+ * + * int64 retry = 5; + * + * @param value The retry to set. + * @return This builder for chaining. + */ + public Builder setRetry(long value) { + + retry_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Retry.
+     * 
+ * + * int64 retry = 5; + * + * @return This builder for chaining. + */ + public Builder clearRetry() { + bitField0_ = (bitField0_ & ~0x00000010); + retry_ = 0L; + onChanged(); + return this; + } + + private com.google.protobuf.Duration refresh_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + refreshBuilder_; + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + * + * @return Whether the refresh field is set. + */ + public boolean hasRefresh() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + * + * @return The refresh. + */ + public com.google.protobuf.Duration getRefresh() { + if (refreshBuilder_ == null) { + return refresh_ == null ? com.google.protobuf.Duration.getDefaultInstance() : refresh_; + } else { + return refreshBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + public Builder setRefresh(com.google.protobuf.Duration value) { + if (refreshBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + refresh_ = value; + } else { + refreshBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + public Builder setRefresh(com.google.protobuf.Duration.Builder builderForValue) { + if (refreshBuilder_ == null) { + refresh_ = builderForValue.build(); + } else { + refreshBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + public Builder mergeRefresh(com.google.protobuf.Duration value) { + if (refreshBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && refresh_ != null + && refresh_ != com.google.protobuf.Duration.getDefaultInstance()) { + getRefreshBuilder().mergeFrom(value); + } else { + refresh_ = value; + } + } else { + refreshBuilder_.mergeFrom(value); + } + if (refresh_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + public Builder clearRefresh() { + bitField0_ = (bitField0_ & ~0x00000020); + refresh_ = null; + if (refreshBuilder_ != null) { + refreshBuilder_.dispose(); + refreshBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + public com.google.protobuf.Duration.Builder getRefreshBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetRefreshFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + public com.google.protobuf.DurationOrBuilder getRefreshOrBuilder() { + if (refreshBuilder_ != null) { + return refreshBuilder_.getMessageOrBuilder(); + } else { + return refresh_ == null ? com.google.protobuf.Duration.getDefaultInstance() : refresh_; + } + } + + /** + * + * + *
+     * Refresh.
+     * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + internalGetRefreshFieldBuilder() { + if (refreshBuilder_ == null) { + refreshBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getRefresh(), getParentForChildren(), isClean()); + refresh_ = null; + } + return refreshBuilder_; + } + + private com.google.protobuf.Duration minimum_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + minimumBuilder_; + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + * + * @return Whether the minimum field is set. + */ + public boolean hasMinimum() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + * + * @return The minimum. + */ + public com.google.protobuf.Duration getMinimum() { + if (minimumBuilder_ == null) { + return minimum_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minimum_; + } else { + return minimumBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + public Builder setMinimum(com.google.protobuf.Duration value) { + if (minimumBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + minimum_ = value; + } else { + minimumBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + public Builder setMinimum(com.google.protobuf.Duration.Builder builderForValue) { + if (minimumBuilder_ == null) { + minimum_ = builderForValue.build(); + } else { + minimumBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + public Builder mergeMinimum(com.google.protobuf.Duration value) { + if (minimumBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && minimum_ != null + && minimum_ != com.google.protobuf.Duration.getDefaultInstance()) { + getMinimumBuilder().mergeFrom(value); + } else { + minimum_ = value; + } + } else { + minimumBuilder_.mergeFrom(value); + } + if (minimum_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + public Builder clearMinimum() { + bitField0_ = (bitField0_ & ~0x00000040); + minimum_ = null; + if (minimumBuilder_ != null) { + minimumBuilder_.dispose(); + minimumBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + public com.google.protobuf.Duration.Builder getMinimumBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetMinimumFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + public com.google.protobuf.DurationOrBuilder getMinimumOrBuilder() { + if (minimumBuilder_ != null) { + return minimumBuilder_.getMessageOrBuilder(); + } else { + return minimum_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minimum_; + } + } + + /** + * + * + *
+     * Minimum.
+     * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + internalGetMinimumFieldBuilder() { + if (minimumBuilder_ == null) { + minimumBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getMinimum(), getParentForChildren(), isClean()); + minimum_ = null; + } + return minimumBuilder_; + } + + private com.google.protobuf.Duration expire_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + expireBuilder_; + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + * + * @return Whether the expire field is set. + */ + public boolean hasExpire() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + * + * @return The expire. + */ + public com.google.protobuf.Duration getExpire() { + if (expireBuilder_ == null) { + return expire_ == null ? com.google.protobuf.Duration.getDefaultInstance() : expire_; + } else { + return expireBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + public Builder setExpire(com.google.protobuf.Duration value) { + if (expireBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expire_ = value; + } else { + expireBuilder_.setMessage(value); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + public Builder setExpire(com.google.protobuf.Duration.Builder builderForValue) { + if (expireBuilder_ == null) { + expire_ = builderForValue.build(); + } else { + expireBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + public Builder mergeExpire(com.google.protobuf.Duration value) { + if (expireBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0) + && expire_ != null + && expire_ != com.google.protobuf.Duration.getDefaultInstance()) { + getExpireBuilder().mergeFrom(value); + } else { + expire_ = value; + } + } else { + expireBuilder_.mergeFrom(value); + } + if (expire_ != null) { + bitField0_ |= 0x00000080; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + public Builder clearExpire() { + bitField0_ = (bitField0_ & ~0x00000080); + expire_ = null; + if (expireBuilder_ != null) { + expireBuilder_.dispose(); + expireBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + public com.google.protobuf.Duration.Builder getExpireBuilder() { + bitField0_ |= 0x00000080; + onChanged(); + return internalGetExpireFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + public com.google.protobuf.DurationOrBuilder getExpireOrBuilder() { + if (expireBuilder_ != null) { + return expireBuilder_.getMessageOrBuilder(); + } else { + return expire_ == null ? com.google.protobuf.Duration.getDefaultInstance() : expire_; + } + } + + /** + * + * + *
+     * Expire.
+     * 
+ * + * .google.protobuf.Duration expire = 8; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + internalGetExpireFieldBuilder() { + if (expireBuilder_ == null) { + expireBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getExpire(), getParentForChildren(), isClean()); + expire_ = null; + } + return expireBuilder_; + } + + private long serial_; + + /** + * + * + *
+     * Serial.
+     * 
+ * + * int64 serial = 9; + * + * @return The serial. + */ + @java.lang.Override + public long getSerial() { + return serial_; + } + + /** + * + * + *
+     * Serial.
+     * 
+ * + * int64 serial = 9; + * + * @param value The serial to set. + * @return This builder for chaining. + */ + public Builder setSerial(long value) { + + serial_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Serial.
+     * 
+ * + * int64 serial = 9; + * + * @return This builder for chaining. + */ + public Builder clearSerial() { + bitField0_ = (bitField0_ & ~0x00000100); + serial_ = 0L; + onChanged(); + return this; + } + + private java.lang.Object rname_ = ""; + + /** + * + * + *
+     * Rname.
+     * 
+ * + * string rname = 10; + * + * @return The rname. + */ + public java.lang.String getRname() { + java.lang.Object ref = rname_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + rname_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Rname.
+     * 
+ * + * string rname = 10; + * + * @return The bytes for rname. + */ + public com.google.protobuf.ByteString getRnameBytes() { + java.lang.Object ref = rname_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + rname_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Rname.
+     * 
+ * + * string rname = 10; + * + * @param value The rname to set. + * @return This builder for chaining. + */ + public Builder setRname(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + rname_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Rname.
+     * 
+ * + * string rname = 10; + * + * @return This builder for chaining. + */ + public Builder clearRname() { + rname_ = getDefaultInstance().getRname(); + bitField0_ = (bitField0_ & ~0x00000200); + onChanged(); + return this; + } + + /** + * + * + *
+     * Rname.
+     * 
+ * + * string rname = 10; + * + * @param value The bytes for rname to set. + * @return This builder for chaining. + */ + public Builder setRnameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + rname_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.DNSRecord) + } + + // @@protoc_insertion_point(class_scope:google.backstory.DNSRecord) + private static final com.google.backstory.DNSRecord DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.DNSRecord(); + } + + public static com.google.backstory.DNSRecord getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DNSRecord parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.DNSRecord getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java new file mode 100644 index 000000000000..22b3c72b124b --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java @@ -0,0 +1,278 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface DNSRecordOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.DNSRecord) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Type.
+   * 
+ * + * string type = 1; + * + * @return The type. + */ + java.lang.String getType(); + + /** + * + * + *
+   * Type.
+   * 
+ * + * string type = 1; + * + * @return The bytes for type. + */ + com.google.protobuf.ByteString getTypeBytes(); + + /** + * + * + *
+   * Value.
+   * 
+ * + * string value = 2; + * + * @return The value. + */ + java.lang.String getValue(); + + /** + * + * + *
+   * Value.
+   * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); + + /** + * + * + *
+   * Time to live.
+   * 
+ * + * .google.protobuf.Duration ttl = 3; + * + * @return Whether the ttl field is set. + */ + boolean hasTtl(); + + /** + * + * + *
+   * Time to live.
+   * 
+ * + * .google.protobuf.Duration ttl = 3; + * + * @return The ttl. + */ + com.google.protobuf.Duration getTtl(); + + /** + * + * + *
+   * Time to live.
+   * 
+ * + * .google.protobuf.Duration ttl = 3; + */ + com.google.protobuf.DurationOrBuilder getTtlOrBuilder(); + + /** + * + * + *
+   * Priority.
+   * 
+ * + * int64 priority = 4; + * + * @return The priority. + */ + long getPriority(); + + /** + * + * + *
+   * Retry.
+   * 
+ * + * int64 retry = 5; + * + * @return The retry. + */ + long getRetry(); + + /** + * + * + *
+   * Refresh.
+   * 
+ * + * .google.protobuf.Duration refresh = 6; + * + * @return Whether the refresh field is set. + */ + boolean hasRefresh(); + + /** + * + * + *
+   * Refresh.
+   * 
+ * + * .google.protobuf.Duration refresh = 6; + * + * @return The refresh. + */ + com.google.protobuf.Duration getRefresh(); + + /** + * + * + *
+   * Refresh.
+   * 
+ * + * .google.protobuf.Duration refresh = 6; + */ + com.google.protobuf.DurationOrBuilder getRefreshOrBuilder(); + + /** + * + * + *
+   * Minimum.
+   * 
+ * + * .google.protobuf.Duration minimum = 7; + * + * @return Whether the minimum field is set. + */ + boolean hasMinimum(); + + /** + * + * + *
+   * Minimum.
+   * 
+ * + * .google.protobuf.Duration minimum = 7; + * + * @return The minimum. + */ + com.google.protobuf.Duration getMinimum(); + + /** + * + * + *
+   * Minimum.
+   * 
+ * + * .google.protobuf.Duration minimum = 7; + */ + com.google.protobuf.DurationOrBuilder getMinimumOrBuilder(); + + /** + * + * + *
+   * Expire.
+   * 
+ * + * .google.protobuf.Duration expire = 8; + * + * @return Whether the expire field is set. + */ + boolean hasExpire(); + + /** + * + * + *
+   * Expire.
+   * 
+ * + * .google.protobuf.Duration expire = 8; + * + * @return The expire. + */ + com.google.protobuf.Duration getExpire(); + + /** + * + * + *
+   * Expire.
+   * 
+ * + * .google.protobuf.Duration expire = 8; + */ + com.google.protobuf.DurationOrBuilder getExpireOrBuilder(); + + /** + * + * + *
+   * Serial.
+   * 
+ * + * int64 serial = 9; + * + * @return The serial. + */ + long getSerial(); + + /** + * + * + *
+   * Rname.
+   * 
+ * + * string rname = 10; + * + * @return The rname. + */ + java.lang.String getRname(); + + /** + * + * + *
+   * Rname.
+   * 
+ * + * string rname = 10; + * + * @return The bytes for rname. + */ + com.google.protobuf.ByteString getRnameBytes(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccess.java b/java-backstory/src/main/java/com/google/backstory/DataAccess.java new file mode 100644 index 000000000000..138b6e152d0e --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataAccess.java @@ -0,0 +1,86 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/data_access.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public final class DataAccess extends com.google.protobuf.GeneratedFile { + private DataAccess() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DataAccess"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_DataAccessIngestionLabel_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_DataAccessIngestionLabel_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_backstory_DataAccessLabels_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_backstory_DataAccessLabels_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n\033backstory/data_access.proto\022\020google.ba" + + "ckstory\"6\n\030DataAccessIngestionLabel\022\013\n\003k" + + "ey\030\001 \001(\t\022\r\n\005value\030\002 \001(\t\"\324\001\n\020DataAccessLa" + + "bels\022\021\n\tlog_types\030\001 \003(\t\022\034\n\020ingestion_lab" + + "els\030\002 \003(\tB\002\030\001\022\022\n\nnamespaces\030\003 \003(\t\022\025\n\rcus" + + "tom_labels\030\004 \003(\t\022G\n\023ingestion_kv_labels\030" + + "\005 \003(\0132*.google.backstory.DataAccessInges" + + "tionLabel\022\033\n\023allow_scoped_access\030\006 \001(\010B\215" + + "\001\n\024com.google.backstoryP\001Z9google.golang" + + ".org/genproto/googleapis/backstory;backs" + + "tory\252\002\020Google.Backstory\312\002\020Google\\Backsto" + + "ry\352\002\021Google::Backstoryb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] {}); + internal_static_google_backstory_DataAccessIngestionLabel_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_backstory_DataAccessIngestionLabel_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_DataAccessIngestionLabel_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_backstory_DataAccessLabels_descriptor = + getDescriptor().getMessageType(1); + internal_static_google_backstory_DataAccessLabels_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_backstory_DataAccessLabels_descriptor, + new java.lang.String[] { + "LogTypes", + "IngestionLabels", + "Namespaces", + "CustomLabels", + "IngestionKvLabels", + "AllowScopedAccess", + }); + descriptor.resolveAllFeaturesImmutable(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java b/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java new file mode 100644 index 000000000000..10d81f67303f --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java @@ -0,0 +1,769 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/data_access.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Label used in data access for ingestion.
+ * 
+ * + * Protobuf type {@code google.backstory.DataAccessIngestionLabel} + */ +@com.google.protobuf.Generated +public final class DataAccessIngestionLabel extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.DataAccessIngestionLabel) + DataAccessIngestionLabelOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DataAccessIngestionLabel"); + } + + // Use DataAccessIngestionLabel.newBuilder() to construct. + private DataAccessIngestionLabel(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DataAccessIngestionLabel() { + key_ = ""; + value_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessIngestionLabel_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessIngestionLabel_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DataAccessIngestionLabel.class, + com.google.backstory.DataAccessIngestionLabel.Builder.class); + } + + public static final int KEY_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object key_ = ""; + + /** + * + * + *
+   * The key.
+   * 
+ * + * string key = 1; + * + * @return The key. + */ + @java.lang.Override + public java.lang.String getKey() { + java.lang.Object ref = key_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + key_ = s; + return s; + } + } + + /** + * + * + *
+   * The key.
+   * 
+ * + * string key = 1; + * + * @return The bytes for key. + */ + @java.lang.Override + public com.google.protobuf.ByteString getKeyBytes() { + java.lang.Object ref = key_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + key_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALUE_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object value_ = ""; + + /** + * + * + *
+   * The value.
+   * 
+ * + * string value = 2; + * + * @return The value. + */ + @java.lang.Override + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } + } + + /** + * + * + *
+   * The value.
+   * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + @java.lang.Override + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(key_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, key_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(value_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, value_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(key_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, key_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(value_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, value_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.DataAccessIngestionLabel)) { + return super.equals(obj); + } + com.google.backstory.DataAccessIngestionLabel other = + (com.google.backstory.DataAccessIngestionLabel) obj; + + if (!getKey().equals(other.getKey())) return false; + if (!getValue().equals(other.getValue())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + KEY_FIELD_NUMBER; + hash = (53 * hash) + getKey().hashCode(); + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DataAccessIngestionLabel parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.DataAccessIngestionLabel parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DataAccessIngestionLabel parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.DataAccessIngestionLabel prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Label used in data access for ingestion.
+   * 
+ * + * Protobuf type {@code google.backstory.DataAccessIngestionLabel} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.DataAccessIngestionLabel) + com.google.backstory.DataAccessIngestionLabelOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessIngestionLabel_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessIngestionLabel_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DataAccessIngestionLabel.class, + com.google.backstory.DataAccessIngestionLabel.Builder.class); + } + + // Construct using com.google.backstory.DataAccessIngestionLabel.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + key_ = ""; + value_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessIngestionLabel_descriptor; + } + + @java.lang.Override + public com.google.backstory.DataAccessIngestionLabel getDefaultInstanceForType() { + return com.google.backstory.DataAccessIngestionLabel.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.DataAccessIngestionLabel build() { + com.google.backstory.DataAccessIngestionLabel result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.DataAccessIngestionLabel buildPartial() { + com.google.backstory.DataAccessIngestionLabel result = + new com.google.backstory.DataAccessIngestionLabel(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.DataAccessIngestionLabel result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.key_ = key_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.value_ = value_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.DataAccessIngestionLabel) { + return mergeFrom((com.google.backstory.DataAccessIngestionLabel) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.DataAccessIngestionLabel other) { + if (other == com.google.backstory.DataAccessIngestionLabel.getDefaultInstance()) return this; + if (!other.getKey().isEmpty()) { + key_ = other.key_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getValue().isEmpty()) { + value_ = other.value_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + key_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + value_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object key_ = ""; + + /** + * + * + *
+     * The key.
+     * 
+ * + * string key = 1; + * + * @return The key. + */ + public java.lang.String getKey() { + java.lang.Object ref = key_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + key_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The key.
+     * 
+ * + * string key = 1; + * + * @return The bytes for key. + */ + public com.google.protobuf.ByteString getKeyBytes() { + java.lang.Object ref = key_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + key_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The key.
+     * 
+ * + * string key = 1; + * + * @param value The key to set. + * @return This builder for chaining. + */ + public Builder setKey(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + key_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The key.
+     * 
+ * + * string key = 1; + * + * @return This builder for chaining. + */ + public Builder clearKey() { + key_ = getDefaultInstance().getKey(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * The key.
+     * 
+ * + * string key = 1; + * + * @param value The bytes for key to set. + * @return This builder for chaining. + */ + public Builder setKeyBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + key_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object value_ = ""; + + /** + * + * + *
+     * The value.
+     * 
+ * + * string value = 2; + * + * @return The value. + */ + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The value.
+     * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The value.
+     * 
+ * + * string value = 2; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The value.
+     * 
+ * + * string value = 2; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + value_ = getDefaultInstance().getValue(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * The value.
+     * 
+ * + * string value = 2; + * + * @param value The bytes for value to set. + * @return This builder for chaining. + */ + public Builder setValueBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.DataAccessIngestionLabel) + } + + // @@protoc_insertion_point(class_scope:google.backstory.DataAccessIngestionLabel) + private static final com.google.backstory.DataAccessIngestionLabel DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.DataAccessIngestionLabel(); + } + + public static com.google.backstory.DataAccessIngestionLabel getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DataAccessIngestionLabel parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.DataAccessIngestionLabel getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java new file mode 100644 index 000000000000..7c06d4f7d3eb --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java @@ -0,0 +1,65 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/data_access.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface DataAccessIngestionLabelOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.DataAccessIngestionLabel) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The key.
+   * 
+ * + * string key = 1; + * + * @return The key. + */ + java.lang.String getKey(); + + /** + * + * + *
+   * The key.
+   * 
+ * + * string key = 1; + * + * @return The bytes for key. + */ + com.google.protobuf.ByteString getKeyBytes(); + + /** + * + * + *
+   * The value.
+   * 
+ * + * string value = 2; + * + * @return The value. + */ + java.lang.String getValue(); + + /** + * + * + *
+   * The value.
+   * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessLabels.java b/java-backstory/src/main/java/com/google/backstory/DataAccessLabels.java new file mode 100644 index 000000000000..d957b451a14f --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataAccessLabels.java @@ -0,0 +1,2213 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/data_access.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * Label used in data access.
+ * 
+ * + * Protobuf type {@code google.backstory.DataAccessLabels} + */ +@com.google.protobuf.Generated +public final class DataAccessLabels extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.DataAccessLabels) + DataAccessLabelsOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DataAccessLabels"); + } + + // Use DataAccessLabels.newBuilder() to construct. + private DataAccessLabels(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DataAccessLabels() { + logTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + ingestionLabels_ = com.google.protobuf.LazyStringArrayList.emptyList(); + namespaces_ = com.google.protobuf.LazyStringArrayList.emptyList(); + customLabels_ = com.google.protobuf.LazyStringArrayList.emptyList(); + ingestionKvLabels_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessLabels_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessLabels_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DataAccessLabels.class, + com.google.backstory.DataAccessLabels.Builder.class); + } + + public static final int LOG_TYPES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList logTypes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @return A list containing the logTypes. + */ + public com.google.protobuf.ProtocolStringList getLogTypesList() { + return logTypes_; + } + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @return The count of logTypes. + */ + public int getLogTypesCount() { + return logTypes_.size(); + } + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @param index The index of the element to return. + * @return The logTypes at the given index. + */ + public java.lang.String getLogTypes(int index) { + return logTypes_.get(index); + } + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @param index The index of the value to return. + * @return The bytes of the logTypes at the given index. + */ + public com.google.protobuf.ByteString getLogTypesBytes(int index) { + return logTypes_.getByteString(index); + } + + public static final int INGESTION_LABELS_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList ingestionLabels_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return A list containing the ingestionLabels. + */ + @java.lang.Deprecated + public com.google.protobuf.ProtocolStringList getIngestionLabelsList() { + return ingestionLabels_; + } + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return The count of ingestionLabels. + */ + @java.lang.Deprecated + public int getIngestionLabelsCount() { + return ingestionLabels_.size(); + } + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index of the element to return. + * @return The ingestionLabels at the given index. + */ + @java.lang.Deprecated + public java.lang.String getIngestionLabels(int index) { + return ingestionLabels_.get(index); + } + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index of the value to return. + * @return The bytes of the ingestionLabels at the given index. + */ + @java.lang.Deprecated + public com.google.protobuf.ByteString getIngestionLabelsBytes(int index) { + return ingestionLabels_.getByteString(index); + } + + public static final int NAMESPACES_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList namespaces_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @return A list containing the namespaces. + */ + public com.google.protobuf.ProtocolStringList getNamespacesList() { + return namespaces_; + } + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @return The count of namespaces. + */ + public int getNamespacesCount() { + return namespaces_.size(); + } + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @param index The index of the element to return. + * @return The namespaces at the given index. + */ + public java.lang.String getNamespaces(int index) { + return namespaces_.get(index); + } + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @param index The index of the value to return. + * @return The bytes of the namespaces at the given index. + */ + public com.google.protobuf.ByteString getNamespacesBytes(int index) { + return namespaces_.getByteString(index); + } + + public static final int CUSTOM_LABELS_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList customLabels_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @return A list containing the customLabels. + */ + public com.google.protobuf.ProtocolStringList getCustomLabelsList() { + return customLabels_; + } + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @return The count of customLabels. + */ + public int getCustomLabelsCount() { + return customLabels_.size(); + } + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index of the element to return. + * @return The customLabels at the given index. + */ + public java.lang.String getCustomLabels(int index) { + return customLabels_.get(index); + } + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index of the value to return. + * @return The bytes of the customLabels at the given index. + */ + public com.google.protobuf.ByteString getCustomLabelsBytes(int index) { + return customLabels_.getByteString(index); + } + + public static final int INGESTION_KV_LABELS_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private java.util.List ingestionKvLabels_; + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + @java.lang.Override + public java.util.List getIngestionKvLabelsList() { + return ingestionKvLabels_; + } + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + @java.lang.Override + public java.util.List + getIngestionKvLabelsOrBuilderList() { + return ingestionKvLabels_; + } + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + @java.lang.Override + public int getIngestionKvLabelsCount() { + return ingestionKvLabels_.size(); + } + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + @java.lang.Override + public com.google.backstory.DataAccessIngestionLabel getIngestionKvLabels(int index) { + return ingestionKvLabels_.get(index); + } + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + @java.lang.Override + public com.google.backstory.DataAccessIngestionLabelOrBuilder getIngestionKvLabelsOrBuilder( + int index) { + return ingestionKvLabels_.get(index); + } + + public static final int ALLOW_SCOPED_ACCESS_FIELD_NUMBER = 6; + private boolean allowScopedAccess_ = false; + + /** + * + * + *
+   * Are the labels ready for scoped access
+   * 
+ * + * bool allow_scoped_access = 6; + * + * @return The allowScopedAccess. + */ + @java.lang.Override + public boolean getAllowScopedAccess() { + return allowScopedAccess_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < logTypes_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, logTypes_.getRaw(i)); + } + for (int i = 0; i < ingestionLabels_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, ingestionLabels_.getRaw(i)); + } + for (int i = 0; i < namespaces_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, namespaces_.getRaw(i)); + } + for (int i = 0; i < customLabels_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, customLabels_.getRaw(i)); + } + for (int i = 0; i < ingestionKvLabels_.size(); i++) { + output.writeMessage(5, ingestionKvLabels_.get(i)); + } + if (allowScopedAccess_ != false) { + output.writeBool(6, allowScopedAccess_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < logTypes_.size(); i++) { + dataSize += computeStringSizeNoTag(logTypes_.getRaw(i)); + } + size += dataSize; + size += 1 * getLogTypesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < ingestionLabels_.size(); i++) { + dataSize += computeStringSizeNoTag(ingestionLabels_.getRaw(i)); + } + size += dataSize; + size += 1 * getIngestionLabelsList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < namespaces_.size(); i++) { + dataSize += computeStringSizeNoTag(namespaces_.getRaw(i)); + } + size += dataSize; + size += 1 * getNamespacesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < customLabels_.size(); i++) { + dataSize += computeStringSizeNoTag(customLabels_.getRaw(i)); + } + size += dataSize; + size += 1 * getCustomLabelsList().size(); + } + for (int i = 0; i < ingestionKvLabels_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(5, ingestionKvLabels_.get(i)); + } + if (allowScopedAccess_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, allowScopedAccess_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.DataAccessLabels)) { + return super.equals(obj); + } + com.google.backstory.DataAccessLabels other = (com.google.backstory.DataAccessLabels) obj; + + if (!getLogTypesList().equals(other.getLogTypesList())) return false; + if (!getIngestionLabelsList().equals(other.getIngestionLabelsList())) return false; + if (!getNamespacesList().equals(other.getNamespacesList())) return false; + if (!getCustomLabelsList().equals(other.getCustomLabelsList())) return false; + if (!getIngestionKvLabelsList().equals(other.getIngestionKvLabelsList())) return false; + if (getAllowScopedAccess() != other.getAllowScopedAccess()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getLogTypesCount() > 0) { + hash = (37 * hash) + LOG_TYPES_FIELD_NUMBER; + hash = (53 * hash) + getLogTypesList().hashCode(); + } + if (getIngestionLabelsCount() > 0) { + hash = (37 * hash) + INGESTION_LABELS_FIELD_NUMBER; + hash = (53 * hash) + getIngestionLabelsList().hashCode(); + } + if (getNamespacesCount() > 0) { + hash = (37 * hash) + NAMESPACES_FIELD_NUMBER; + hash = (53 * hash) + getNamespacesList().hashCode(); + } + if (getCustomLabelsCount() > 0) { + hash = (37 * hash) + CUSTOM_LABELS_FIELD_NUMBER; + hash = (53 * hash) + getCustomLabelsList().hashCode(); + } + if (getIngestionKvLabelsCount() > 0) { + hash = (37 * hash) + INGESTION_KV_LABELS_FIELD_NUMBER; + hash = (53 * hash) + getIngestionKvLabelsList().hashCode(); + } + hash = (37 * hash) + ALLOW_SCOPED_ACCESS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowScopedAccess()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.DataAccessLabels parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataAccessLabels parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataAccessLabels parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataAccessLabels parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataAccessLabels parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataAccessLabels parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataAccessLabels parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DataAccessLabels parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DataAccessLabels parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.DataAccessLabels parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DataAccessLabels parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DataAccessLabels parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.DataAccessLabels prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Label used in data access.
+   * 
+ * + * Protobuf type {@code google.backstory.DataAccessLabels} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.DataAccessLabels) + com.google.backstory.DataAccessLabelsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessLabels_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessLabels_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DataAccessLabels.class, + com.google.backstory.DataAccessLabels.Builder.class); + } + + // Construct using com.google.backstory.DataAccessLabels.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + logTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + ingestionLabels_ = com.google.protobuf.LazyStringArrayList.emptyList(); + namespaces_ = com.google.protobuf.LazyStringArrayList.emptyList(); + customLabels_ = com.google.protobuf.LazyStringArrayList.emptyList(); + if (ingestionKvLabelsBuilder_ == null) { + ingestionKvLabels_ = java.util.Collections.emptyList(); + } else { + ingestionKvLabels_ = null; + ingestionKvLabelsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000010); + allowScopedAccess_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.DataAccess + .internal_static_google_backstory_DataAccessLabels_descriptor; + } + + @java.lang.Override + public com.google.backstory.DataAccessLabels getDefaultInstanceForType() { + return com.google.backstory.DataAccessLabels.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.DataAccessLabels build() { + com.google.backstory.DataAccessLabels result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.DataAccessLabels buildPartial() { + com.google.backstory.DataAccessLabels result = + new com.google.backstory.DataAccessLabels(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.backstory.DataAccessLabels result) { + if (ingestionKvLabelsBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0)) { + ingestionKvLabels_ = java.util.Collections.unmodifiableList(ingestionKvLabels_); + bitField0_ = (bitField0_ & ~0x00000010); + } + result.ingestionKvLabels_ = ingestionKvLabels_; + } else { + result.ingestionKvLabels_ = ingestionKvLabelsBuilder_.build(); + } + } + + private void buildPartial0(com.google.backstory.DataAccessLabels result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + logTypes_.makeImmutable(); + result.logTypes_ = logTypes_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + ingestionLabels_.makeImmutable(); + result.ingestionLabels_ = ingestionLabels_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + namespaces_.makeImmutable(); + result.namespaces_ = namespaces_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + customLabels_.makeImmutable(); + result.customLabels_ = customLabels_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.allowScopedAccess_ = allowScopedAccess_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.DataAccessLabels) { + return mergeFrom((com.google.backstory.DataAccessLabels) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.DataAccessLabels other) { + if (other == com.google.backstory.DataAccessLabels.getDefaultInstance()) return this; + if (!other.logTypes_.isEmpty()) { + if (logTypes_.isEmpty()) { + logTypes_ = other.logTypes_; + bitField0_ |= 0x00000001; + } else { + ensureLogTypesIsMutable(); + logTypes_.addAll(other.logTypes_); + } + onChanged(); + } + if (!other.ingestionLabels_.isEmpty()) { + if (ingestionLabels_.isEmpty()) { + ingestionLabels_ = other.ingestionLabels_; + bitField0_ |= 0x00000002; + } else { + ensureIngestionLabelsIsMutable(); + ingestionLabels_.addAll(other.ingestionLabels_); + } + onChanged(); + } + if (!other.namespaces_.isEmpty()) { + if (namespaces_.isEmpty()) { + namespaces_ = other.namespaces_; + bitField0_ |= 0x00000004; + } else { + ensureNamespacesIsMutable(); + namespaces_.addAll(other.namespaces_); + } + onChanged(); + } + if (!other.customLabels_.isEmpty()) { + if (customLabels_.isEmpty()) { + customLabels_ = other.customLabels_; + bitField0_ |= 0x00000008; + } else { + ensureCustomLabelsIsMutable(); + customLabels_.addAll(other.customLabels_); + } + onChanged(); + } + if (ingestionKvLabelsBuilder_ == null) { + if (!other.ingestionKvLabels_.isEmpty()) { + if (ingestionKvLabels_.isEmpty()) { + ingestionKvLabels_ = other.ingestionKvLabels_; + bitField0_ = (bitField0_ & ~0x00000010); + } else { + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.addAll(other.ingestionKvLabels_); + } + onChanged(); + } + } else { + if (!other.ingestionKvLabels_.isEmpty()) { + if (ingestionKvLabelsBuilder_.isEmpty()) { + ingestionKvLabelsBuilder_.dispose(); + ingestionKvLabelsBuilder_ = null; + ingestionKvLabels_ = other.ingestionKvLabels_; + bitField0_ = (bitField0_ & ~0x00000010); + ingestionKvLabelsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetIngestionKvLabelsFieldBuilder() + : null; + } else { + ingestionKvLabelsBuilder_.addAllMessages(other.ingestionKvLabels_); + } + } + } + if (other.getAllowScopedAccess() != false) { + setAllowScopedAccess(other.getAllowScopedAccess()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureLogTypesIsMutable(); + logTypes_.add(s); + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIngestionLabelsIsMutable(); + ingestionLabels_.add(s); + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureNamespacesIsMutable(); + namespaces_.add(s); + break; + } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureCustomLabelsIsMutable(); + customLabels_.add(s); + break; + } // case 34 + case 42: + { + com.google.backstory.DataAccessIngestionLabel m = + input.readMessage( + com.google.backstory.DataAccessIngestionLabel.parser(), extensionRegistry); + if (ingestionKvLabelsBuilder_ == null) { + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.add(m); + } else { + ingestionKvLabelsBuilder_.addMessage(m); + } + break; + } // case 42 + case 48: + { + allowScopedAccess_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 48 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringArrayList logTypes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureLogTypesIsMutable() { + if (!logTypes_.isModifiable()) { + logTypes_ = new com.google.protobuf.LazyStringArrayList(logTypes_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @return A list containing the logTypes. + */ + public com.google.protobuf.ProtocolStringList getLogTypesList() { + logTypes_.makeImmutable(); + return logTypes_; + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @return The count of logTypes. + */ + public int getLogTypesCount() { + return logTypes_.size(); + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @param index The index of the element to return. + * @return The logTypes at the given index. + */ + public java.lang.String getLogTypes(int index) { + return logTypes_.get(index); + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @param index The index of the value to return. + * @return The bytes of the logTypes at the given index. + */ + public com.google.protobuf.ByteString getLogTypesBytes(int index) { + return logTypes_.getByteString(index); + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @param index The index to set the value at. + * @param value The logTypes to set. + * @return This builder for chaining. + */ + public Builder setLogTypes(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureLogTypesIsMutable(); + logTypes_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @param value The logTypes to add. + * @return This builder for chaining. + */ + public Builder addLogTypes(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureLogTypesIsMutable(); + logTypes_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @param values The logTypes to add. + * @return This builder for chaining. + */ + public Builder addAllLogTypes(java.lang.Iterable values) { + ensureLogTypesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, logTypes_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @return This builder for chaining. + */ + public Builder clearLogTypes() { + logTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the LogType labels.
+     * 
+ * + * repeated string log_types = 1; + * + * @param value The bytes of the logTypes to add. + * @return This builder for chaining. + */ + public Builder addLogTypesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureLogTypesIsMutable(); + logTypes_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList ingestionLabels_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIngestionLabelsIsMutable() { + if (!ingestionLabels_.isModifiable()) { + ingestionLabels_ = new com.google.protobuf.LazyStringArrayList(ingestionLabels_); + } + bitField0_ |= 0x00000002; + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return A list containing the ingestionLabels. + */ + @java.lang.Deprecated + public com.google.protobuf.ProtocolStringList getIngestionLabelsList() { + ingestionLabels_.makeImmutable(); + return ingestionLabels_; + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return The count of ingestionLabels. + */ + @java.lang.Deprecated + public int getIngestionLabelsCount() { + return ingestionLabels_.size(); + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index of the element to return. + * @return The ingestionLabels at the given index. + */ + @java.lang.Deprecated + public java.lang.String getIngestionLabels(int index) { + return ingestionLabels_.get(index); + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index of the value to return. + * @return The bytes of the ingestionLabels at the given index. + */ + @java.lang.Deprecated + public com.google.protobuf.ByteString getIngestionLabelsBytes(int index) { + return ingestionLabels_.getByteString(index); + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index to set the value at. + * @param value The ingestionLabels to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setIngestionLabels(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIngestionLabelsIsMutable(); + ingestionLabels_.set(index, value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param value The ingestionLabels to add. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder addIngestionLabels(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIngestionLabelsIsMutable(); + ingestionLabels_.add(value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param values The ingestionLabels to add. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder addAllIngestionLabels(java.lang.Iterable values) { + ensureIngestionLabelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, ingestionLabels_); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder clearIngestionLabels() { + ingestionLabels_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the ingestion labels.
+     * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param value The bytes of the ingestionLabels to add. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder addIngestionLabelsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIngestionLabelsIsMutable(); + ingestionLabels_.add(value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList namespaces_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureNamespacesIsMutable() { + if (!namespaces_.isModifiable()) { + namespaces_ = new com.google.protobuf.LazyStringArrayList(namespaces_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @return A list containing the namespaces. + */ + public com.google.protobuf.ProtocolStringList getNamespacesList() { + namespaces_.makeImmutable(); + return namespaces_; + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @return The count of namespaces. + */ + public int getNamespacesCount() { + return namespaces_.size(); + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @param index The index of the element to return. + * @return The namespaces at the given index. + */ + public java.lang.String getNamespaces(int index) { + return namespaces_.get(index); + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @param index The index of the value to return. + * @return The bytes of the namespaces at the given index. + */ + public com.google.protobuf.ByteString getNamespacesBytes(int index) { + return namespaces_.getByteString(index); + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @param index The index to set the value at. + * @param value The namespaces to set. + * @return This builder for chaining. + */ + public Builder setNamespaces(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureNamespacesIsMutable(); + namespaces_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @param value The namespaces to add. + * @return This builder for chaining. + */ + public Builder addNamespaces(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureNamespacesIsMutable(); + namespaces_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @param values The namespaces to add. + * @return This builder for chaining. + */ + public Builder addAllNamespaces(java.lang.Iterable values) { + ensureNamespacesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, namespaces_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @return This builder for chaining. + */ + public Builder clearNamespaces() { + namespaces_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the namespaces.
+     * 
+ * + * repeated string namespaces = 3; + * + * @param value The bytes of the namespaces to add. + * @return This builder for chaining. + */ + public Builder addNamespacesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureNamespacesIsMutable(); + namespaces_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList customLabels_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureCustomLabelsIsMutable() { + if (!customLabels_.isModifiable()) { + customLabels_ = new com.google.protobuf.LazyStringArrayList(customLabels_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @return A list containing the customLabels. + */ + public com.google.protobuf.ProtocolStringList getCustomLabelsList() { + customLabels_.makeImmutable(); + return customLabels_; + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @return The count of customLabels. + */ + public int getCustomLabelsCount() { + return customLabels_.size(); + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index of the element to return. + * @return The customLabels at the given index. + */ + public java.lang.String getCustomLabels(int index) { + return customLabels_.get(index); + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index of the value to return. + * @return The bytes of the customLabels at the given index. + */ + public com.google.protobuf.ByteString getCustomLabelsBytes(int index) { + return customLabels_.getByteString(index); + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index to set the value at. + * @param value The customLabels to set. + * @return This builder for chaining. + */ + public Builder setCustomLabels(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomLabelsIsMutable(); + customLabels_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @param value The customLabels to add. + * @return This builder for chaining. + */ + public Builder addCustomLabels(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomLabelsIsMutable(); + customLabels_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @param values The customLabels to add. + * @return This builder for chaining. + */ + public Builder addAllCustomLabels(java.lang.Iterable values) { + ensureCustomLabelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, customLabels_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @return This builder for chaining. + */ + public Builder clearCustomLabels() { + customLabels_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * All the complex labels (UDM search syntax based).
+     * 
+ * + * repeated string custom_labels = 4; + * + * @param value The bytes of the customLabels to add. + * @return This builder for chaining. + */ + public Builder addCustomLabelsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureCustomLabelsIsMutable(); + customLabels_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.util.List ingestionKvLabels_ = + java.util.Collections.emptyList(); + + private void ensureIngestionKvLabelsIsMutable() { + if (!((bitField0_ & 0x00000010) != 0)) { + ingestionKvLabels_ = + new java.util.ArrayList( + ingestionKvLabels_); + bitField0_ |= 0x00000010; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.DataAccessIngestionLabel, + com.google.backstory.DataAccessIngestionLabel.Builder, + com.google.backstory.DataAccessIngestionLabelOrBuilder> + ingestionKvLabelsBuilder_; + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public java.util.List + getIngestionKvLabelsList() { + if (ingestionKvLabelsBuilder_ == null) { + return java.util.Collections.unmodifiableList(ingestionKvLabels_); + } else { + return ingestionKvLabelsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public int getIngestionKvLabelsCount() { + if (ingestionKvLabelsBuilder_ == null) { + return ingestionKvLabels_.size(); + } else { + return ingestionKvLabelsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public com.google.backstory.DataAccessIngestionLabel getIngestionKvLabels(int index) { + if (ingestionKvLabelsBuilder_ == null) { + return ingestionKvLabels_.get(index); + } else { + return ingestionKvLabelsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder setIngestionKvLabels( + int index, com.google.backstory.DataAccessIngestionLabel value) { + if (ingestionKvLabelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.set(index, value); + onChanged(); + } else { + ingestionKvLabelsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder setIngestionKvLabels( + int index, com.google.backstory.DataAccessIngestionLabel.Builder builderForValue) { + if (ingestionKvLabelsBuilder_ == null) { + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.set(index, builderForValue.build()); + onChanged(); + } else { + ingestionKvLabelsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder addIngestionKvLabels(com.google.backstory.DataAccessIngestionLabel value) { + if (ingestionKvLabelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.add(value); + onChanged(); + } else { + ingestionKvLabelsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder addIngestionKvLabels( + int index, com.google.backstory.DataAccessIngestionLabel value) { + if (ingestionKvLabelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.add(index, value); + onChanged(); + } else { + ingestionKvLabelsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder addIngestionKvLabels( + com.google.backstory.DataAccessIngestionLabel.Builder builderForValue) { + if (ingestionKvLabelsBuilder_ == null) { + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.add(builderForValue.build()); + onChanged(); + } else { + ingestionKvLabelsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder addIngestionKvLabels( + int index, com.google.backstory.DataAccessIngestionLabel.Builder builderForValue) { + if (ingestionKvLabelsBuilder_ == null) { + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.add(index, builderForValue.build()); + onChanged(); + } else { + ingestionKvLabelsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder addAllIngestionKvLabels( + java.lang.Iterable values) { + if (ingestionKvLabelsBuilder_ == null) { + ensureIngestionKvLabelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, ingestionKvLabels_); + onChanged(); + } else { + ingestionKvLabelsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder clearIngestionKvLabels() { + if (ingestionKvLabelsBuilder_ == null) { + ingestionKvLabels_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + } else { + ingestionKvLabelsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public Builder removeIngestionKvLabels(int index) { + if (ingestionKvLabelsBuilder_ == null) { + ensureIngestionKvLabelsIsMutable(); + ingestionKvLabels_.remove(index); + onChanged(); + } else { + ingestionKvLabelsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public com.google.backstory.DataAccessIngestionLabel.Builder getIngestionKvLabelsBuilder( + int index) { + return internalGetIngestionKvLabelsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public com.google.backstory.DataAccessIngestionLabelOrBuilder getIngestionKvLabelsOrBuilder( + int index) { + if (ingestionKvLabelsBuilder_ == null) { + return ingestionKvLabels_.get(index); + } else { + return ingestionKvLabelsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public java.util.List + getIngestionKvLabelsOrBuilderList() { + if (ingestionKvLabelsBuilder_ != null) { + return ingestionKvLabelsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(ingestionKvLabels_); + } + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public com.google.backstory.DataAccessIngestionLabel.Builder addIngestionKvLabelsBuilder() { + return internalGetIngestionKvLabelsFieldBuilder() + .addBuilder(com.google.backstory.DataAccessIngestionLabel.getDefaultInstance()); + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public com.google.backstory.DataAccessIngestionLabel.Builder addIngestionKvLabelsBuilder( + int index) { + return internalGetIngestionKvLabelsFieldBuilder() + .addBuilder(index, com.google.backstory.DataAccessIngestionLabel.getDefaultInstance()); + } + + /** + * + * + *
+     * All the ingestion labels (key/value pairs).
+     * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + public java.util.List + getIngestionKvLabelsBuilderList() { + return internalGetIngestionKvLabelsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.DataAccessIngestionLabel, + com.google.backstory.DataAccessIngestionLabel.Builder, + com.google.backstory.DataAccessIngestionLabelOrBuilder> + internalGetIngestionKvLabelsFieldBuilder() { + if (ingestionKvLabelsBuilder_ == null) { + ingestionKvLabelsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.backstory.DataAccessIngestionLabel, + com.google.backstory.DataAccessIngestionLabel.Builder, + com.google.backstory.DataAccessIngestionLabelOrBuilder>( + ingestionKvLabels_, + ((bitField0_ & 0x00000010) != 0), + getParentForChildren(), + isClean()); + ingestionKvLabels_ = null; + } + return ingestionKvLabelsBuilder_; + } + + private boolean allowScopedAccess_; + + /** + * + * + *
+     * Are the labels ready for scoped access
+     * 
+ * + * bool allow_scoped_access = 6; + * + * @return The allowScopedAccess. + */ + @java.lang.Override + public boolean getAllowScopedAccess() { + return allowScopedAccess_; + } + + /** + * + * + *
+     * Are the labels ready for scoped access
+     * 
+ * + * bool allow_scoped_access = 6; + * + * @param value The allowScopedAccess to set. + * @return This builder for chaining. + */ + public Builder setAllowScopedAccess(boolean value) { + + allowScopedAccess_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Are the labels ready for scoped access
+     * 
+ * + * bool allow_scoped_access = 6; + * + * @return This builder for chaining. + */ + public Builder clearAllowScopedAccess() { + bitField0_ = (bitField0_ & ~0x00000020); + allowScopedAccess_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.DataAccessLabels) + } + + // @@protoc_insertion_point(class_scope:google.backstory.DataAccessLabels) + private static final com.google.backstory.DataAccessLabels DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.DataAccessLabels(); + } + + public static com.google.backstory.DataAccessLabels getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DataAccessLabels parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.DataAccessLabels getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java new file mode 100644 index 000000000000..1e4ac6794505 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java @@ -0,0 +1,310 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/data_access.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface DataAccessLabelsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.DataAccessLabels) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @return A list containing the logTypes. + */ + java.util.List getLogTypesList(); + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @return The count of logTypes. + */ + int getLogTypesCount(); + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @param index The index of the element to return. + * @return The logTypes at the given index. + */ + java.lang.String getLogTypes(int index); + + /** + * + * + *
+   * All the LogType labels.
+   * 
+ * + * repeated string log_types = 1; + * + * @param index The index of the value to return. + * @return The bytes of the logTypes at the given index. + */ + com.google.protobuf.ByteString getLogTypesBytes(int index); + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return A list containing the ingestionLabels. + */ + @java.lang.Deprecated + java.util.List getIngestionLabelsList(); + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @return The count of ingestionLabels. + */ + @java.lang.Deprecated + int getIngestionLabelsCount(); + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index of the element to return. + * @return The ingestionLabels at the given index. + */ + @java.lang.Deprecated + java.lang.String getIngestionLabels(int index); + + /** + * + * + *
+   * All the ingestion labels.
+   * 
+ * + * repeated string ingestion_labels = 2 [deprecated = true]; + * + * @deprecated google.backstory.DataAccessLabels.ingestion_labels is deprecated. See + * backstory/data_access.proto;l=40 + * @param index The index of the value to return. + * @return The bytes of the ingestionLabels at the given index. + */ + @java.lang.Deprecated + com.google.protobuf.ByteString getIngestionLabelsBytes(int index); + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @return A list containing the namespaces. + */ + java.util.List getNamespacesList(); + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @return The count of namespaces. + */ + int getNamespacesCount(); + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @param index The index of the element to return. + * @return The namespaces at the given index. + */ + java.lang.String getNamespaces(int index); + + /** + * + * + *
+   * All the namespaces.
+   * 
+ * + * repeated string namespaces = 3; + * + * @param index The index of the value to return. + * @return The bytes of the namespaces at the given index. + */ + com.google.protobuf.ByteString getNamespacesBytes(int index); + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @return A list containing the customLabels. + */ + java.util.List getCustomLabelsList(); + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @return The count of customLabels. + */ + int getCustomLabelsCount(); + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index of the element to return. + * @return The customLabels at the given index. + */ + java.lang.String getCustomLabels(int index); + + /** + * + * + *
+   * All the complex labels (UDM search syntax based).
+   * 
+ * + * repeated string custom_labels = 4; + * + * @param index The index of the value to return. + * @return The bytes of the customLabels at the given index. + */ + com.google.protobuf.ByteString getCustomLabelsBytes(int index); + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + java.util.List getIngestionKvLabelsList(); + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + com.google.backstory.DataAccessIngestionLabel getIngestionKvLabels(int index); + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + int getIngestionKvLabelsCount(); + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + java.util.List + getIngestionKvLabelsOrBuilderList(); + + /** + * + * + *
+   * All the ingestion labels (key/value pairs).
+   * 
+ * + * repeated .google.backstory.DataAccessIngestionLabel ingestion_kv_labels = 5; + */ + com.google.backstory.DataAccessIngestionLabelOrBuilder getIngestionKvLabelsOrBuilder(int index); + + /** + * + * + *
+   * Are the labels ready for scoped access
+   * 
+ * + * bool allow_scoped_access = 6; + * + * @return The allowScopedAccess. + */ + boolean getAllowScopedAccess(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java b/java-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java new file mode 100644 index 000000000000..632809649e35 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java @@ -0,0 +1,1063 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/collection.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * DataTableRowInfo captures information about a data table row including the
+ * name of the data table.
+ * 
+ * + * Protobuf type {@code google.backstory.DataTableRowInfo} + */ +@com.google.protobuf.Generated +public final class DataTableRowInfo extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.DataTableRowInfo) + DataTableRowInfoOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "DataTableRowInfo"); + } + + // Use DataTableRowInfo.newBuilder() to construct. + private DataTableRowInfo(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DataTableRowInfo() { + dataTable_ = ""; + rowId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_DataTableRowInfo_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_DataTableRowInfo_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DataTableRowInfo.class, + com.google.backstory.DataTableRowInfo.Builder.class); + } + + private int bitField0_; + public static final int DATA_TABLE_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object dataTable_ = ""; + + /** + * + * + *
+   * The name of data table.
+   * 
+ * + * string data_table = 1; + * + * @return The dataTable. + */ + @java.lang.Override + public java.lang.String getDataTable() { + java.lang.Object ref = dataTable_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dataTable_ = s; + return s; + } + } + + /** + * + * + *
+   * The name of data table.
+   * 
+ * + * string data_table = 1; + * + * @return The bytes for dataTable. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDataTableBytes() { + java.lang.Object ref = dataTable_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dataTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ROW_FIELD_NUMBER = 2; + private com.google.protobuf.Struct row_; + + /** + * + * + *
+   * Stores the key value pair for a data table row where the key is the name
+   * of the column for the given value.
+   * 
+ * + * .google.protobuf.Struct row = 2; + * + * @return Whether the row field is set. + */ + @java.lang.Override + public boolean hasRow() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Stores the key value pair for a data table row where the key is the name
+   * of the column for the given value.
+   * 
+ * + * .google.protobuf.Struct row = 2; + * + * @return The row. + */ + @java.lang.Override + public com.google.protobuf.Struct getRow() { + return row_ == null ? com.google.protobuf.Struct.getDefaultInstance() : row_; + } + + /** + * + * + *
+   * Stores the key value pair for a data table row where the key is the name
+   * of the column for the given value.
+   * 
+ * + * .google.protobuf.Struct row = 2; + */ + @java.lang.Override + public com.google.protobuf.StructOrBuilder getRowOrBuilder() { + return row_ == null ? com.google.protobuf.Struct.getDefaultInstance() : row_; + } + + public static final int ROW_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object rowId_ = ""; + + /** + * + * + *
+   * The row id of the data table row.
+   * 
+ * + * string row_id = 3; + * + * @return The rowId. + */ + @java.lang.Override + public java.lang.String getRowId() { + java.lang.Object ref = rowId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + rowId_ = s; + return s; + } + } + + /** + * + * + *
+   * The row id of the data table row.
+   * 
+ * + * string row_id = 3; + * + * @return The bytes for rowId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRowIdBytes() { + java.lang.Object ref = rowId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + rowId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(dataTable_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, dataTable_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getRow()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(rowId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, rowId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(dataTable_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, dataTable_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getRow()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(rowId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, rowId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.DataTableRowInfo)) { + return super.equals(obj); + } + com.google.backstory.DataTableRowInfo other = (com.google.backstory.DataTableRowInfo) obj; + + if (!getDataTable().equals(other.getDataTable())) return false; + if (hasRow() != other.hasRow()) return false; + if (hasRow()) { + if (!getRow().equals(other.getRow())) return false; + } + if (!getRowId().equals(other.getRowId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DATA_TABLE_FIELD_NUMBER; + hash = (53 * hash) + getDataTable().hashCode(); + if (hasRow()) { + hash = (37 * hash) + ROW_FIELD_NUMBER; + hash = (53 * hash) + getRow().hashCode(); + } + hash = (37 * hash) + ROW_ID_FIELD_NUMBER; + hash = (53 * hash) + getRowId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.DataTableRowInfo parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataTableRowInfo parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataTableRowInfo parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataTableRowInfo parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataTableRowInfo parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.DataTableRowInfo parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.DataTableRowInfo parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DataTableRowInfo parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DataTableRowInfo parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.DataTableRowInfo parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.DataTableRowInfo parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.DataTableRowInfo parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.DataTableRowInfo prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * DataTableRowInfo captures information about a data table row including the
+   * name of the data table.
+   * 
+ * + * Protobuf type {@code google.backstory.DataTableRowInfo} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.DataTableRowInfo) + com.google.backstory.DataTableRowInfoOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_DataTableRowInfo_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_DataTableRowInfo_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.DataTableRowInfo.class, + com.google.backstory.DataTableRowInfo.Builder.class); + } + + // Construct using com.google.backstory.DataTableRowInfo.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetRowFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + dataTable_ = ""; + row_ = null; + if (rowBuilder_ != null) { + rowBuilder_.dispose(); + rowBuilder_ = null; + } + rowId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.CollectionOuterClass + .internal_static_google_backstory_DataTableRowInfo_descriptor; + } + + @java.lang.Override + public com.google.backstory.DataTableRowInfo getDefaultInstanceForType() { + return com.google.backstory.DataTableRowInfo.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.DataTableRowInfo build() { + com.google.backstory.DataTableRowInfo result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.DataTableRowInfo buildPartial() { + com.google.backstory.DataTableRowInfo result = + new com.google.backstory.DataTableRowInfo(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.DataTableRowInfo result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.dataTable_ = dataTable_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.row_ = rowBuilder_ == null ? row_ : rowBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.rowId_ = rowId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.DataTableRowInfo) { + return mergeFrom((com.google.backstory.DataTableRowInfo) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.DataTableRowInfo other) { + if (other == com.google.backstory.DataTableRowInfo.getDefaultInstance()) return this; + if (!other.getDataTable().isEmpty()) { + dataTable_ = other.dataTable_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasRow()) { + mergeRow(other.getRow()); + } + if (!other.getRowId().isEmpty()) { + rowId_ = other.rowId_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + dataTable_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(internalGetRowFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + rowId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object dataTable_ = ""; + + /** + * + * + *
+     * The name of data table.
+     * 
+ * + * string data_table = 1; + * + * @return The dataTable. + */ + public java.lang.String getDataTable() { + java.lang.Object ref = dataTable_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dataTable_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The name of data table.
+     * 
+ * + * string data_table = 1; + * + * @return The bytes for dataTable. + */ + public com.google.protobuf.ByteString getDataTableBytes() { + java.lang.Object ref = dataTable_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dataTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The name of data table.
+     * 
+ * + * string data_table = 1; + * + * @param value The dataTable to set. + * @return This builder for chaining. + */ + public Builder setDataTable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + dataTable_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The name of data table.
+     * 
+ * + * string data_table = 1; + * + * @return This builder for chaining. + */ + public Builder clearDataTable() { + dataTable_ = getDefaultInstance().getDataTable(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * The name of data table.
+     * 
+ * + * string data_table = 1; + * + * @param value The bytes for dataTable to set. + * @return This builder for chaining. + */ + public Builder setDataTableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + dataTable_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.protobuf.Struct row_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder> + rowBuilder_; + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + * + * @return Whether the row field is set. + */ + public boolean hasRow() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + * + * @return The row. + */ + public com.google.protobuf.Struct getRow() { + if (rowBuilder_ == null) { + return row_ == null ? com.google.protobuf.Struct.getDefaultInstance() : row_; + } else { + return rowBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + public Builder setRow(com.google.protobuf.Struct value) { + if (rowBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + row_ = value; + } else { + rowBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + public Builder setRow(com.google.protobuf.Struct.Builder builderForValue) { + if (rowBuilder_ == null) { + row_ = builderForValue.build(); + } else { + rowBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + public Builder mergeRow(com.google.protobuf.Struct value) { + if (rowBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && row_ != null + && row_ != com.google.protobuf.Struct.getDefaultInstance()) { + getRowBuilder().mergeFrom(value); + } else { + row_ = value; + } + } else { + rowBuilder_.mergeFrom(value); + } + if (row_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + public Builder clearRow() { + bitField0_ = (bitField0_ & ~0x00000002); + row_ = null; + if (rowBuilder_ != null) { + rowBuilder_.dispose(); + rowBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + public com.google.protobuf.Struct.Builder getRowBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetRowFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + public com.google.protobuf.StructOrBuilder getRowOrBuilder() { + if (rowBuilder_ != null) { + return rowBuilder_.getMessageOrBuilder(); + } else { + return row_ == null ? com.google.protobuf.Struct.getDefaultInstance() : row_; + } + } + + /** + * + * + *
+     * Stores the key value pair for a data table row where the key is the name
+     * of the column for the given value.
+     * 
+ * + * .google.protobuf.Struct row = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder> + internalGetRowFieldBuilder() { + if (rowBuilder_ == null) { + rowBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder>(getRow(), getParentForChildren(), isClean()); + row_ = null; + } + return rowBuilder_; + } + + private java.lang.Object rowId_ = ""; + + /** + * + * + *
+     * The row id of the data table row.
+     * 
+ * + * string row_id = 3; + * + * @return The rowId. + */ + public java.lang.String getRowId() { + java.lang.Object ref = rowId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + rowId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * The row id of the data table row.
+     * 
+ * + * string row_id = 3; + * + * @return The bytes for rowId. + */ + public com.google.protobuf.ByteString getRowIdBytes() { + java.lang.Object ref = rowId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + rowId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * The row id of the data table row.
+     * 
+ * + * string row_id = 3; + * + * @param value The rowId to set. + * @return This builder for chaining. + */ + public Builder setRowId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + rowId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The row id of the data table row.
+     * 
+ * + * string row_id = 3; + * + * @return This builder for chaining. + */ + public Builder clearRowId() { + rowId_ = getDefaultInstance().getRowId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * The row id of the data table row.
+     * 
+ * + * string row_id = 3; + * + * @param value The bytes for rowId to set. + * @return This builder for chaining. + */ + public Builder setRowIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + rowId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.DataTableRowInfo) + } + + // @@protoc_insertion_point(class_scope:google.backstory.DataTableRowInfo) + private static final com.google.backstory.DataTableRowInfo DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.DataTableRowInfo(); + } + + public static com.google.backstory.DataTableRowInfo getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DataTableRowInfo parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.backstory.DataTableRowInfo getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java b/java-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java new file mode 100644 index 000000000000..a3142f446140 --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java @@ -0,0 +1,105 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/collection.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +@com.google.protobuf.Generated +public interface DataTableRowInfoOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.DataTableRowInfo) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The name of data table.
+   * 
+ * + * string data_table = 1; + * + * @return The dataTable. + */ + java.lang.String getDataTable(); + + /** + * + * + *
+   * The name of data table.
+   * 
+ * + * string data_table = 1; + * + * @return The bytes for dataTable. + */ + com.google.protobuf.ByteString getDataTableBytes(); + + /** + * + * + *
+   * Stores the key value pair for a data table row where the key is the name
+   * of the column for the given value.
+   * 
+ * + * .google.protobuf.Struct row = 2; + * + * @return Whether the row field is set. + */ + boolean hasRow(); + + /** + * + * + *
+   * Stores the key value pair for a data table row where the key is the name
+   * of the column for the given value.
+   * 
+ * + * .google.protobuf.Struct row = 2; + * + * @return The row. + */ + com.google.protobuf.Struct getRow(); + + /** + * + * + *
+   * Stores the key value pair for a data table row where the key is the name
+   * of the column for the given value.
+   * 
+ * + * .google.protobuf.Struct row = 2; + */ + com.google.protobuf.StructOrBuilder getRowOrBuilder(); + + /** + * + * + *
+   * The row id of the data table row.
+   * 
+ * + * string row_id = 3; + * + * @return The rowId. + */ + java.lang.String getRowId(); + + /** + * + * + *
+   * The row id of the data table row.
+   * 
+ * + * string row_id = 3; + * + * @return The bytes for rowId. + */ + com.google.protobuf.ByteString getRowIdBytes(); +} diff --git a/java-backstory/src/main/java/com/google/backstory/Dhcp.java b/java-backstory/src/main/java/com/google/backstory/Dhcp.java new file mode 100644 index 000000000000..0becbd88ca4c --- /dev/null +++ b/java-backstory/src/main/java/com/google/backstory/Dhcp.java @@ -0,0 +1,5013 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: backstory/udm.proto +// Protobuf Java Version: 4.33.2 + +package com.google.backstory; + +/** + * + * + *
+ * DHCP information.
+ * 
+ * + * Protobuf type {@code google.backstory.Dhcp} + */ +@com.google.protobuf.Generated +public final class Dhcp extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Dhcp) + DhcpOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Dhcp"); + } + + // Use Dhcp.newBuilder() to construct. + private Dhcp(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Dhcp() { + opcode_ = 0; + ciaddr_ = ""; + yiaddr_ = ""; + siaddr_ = ""; + giaddr_ = ""; + chaddr_ = ""; + sname_ = ""; + file_ = ""; + options_ = java.util.Collections.emptyList(); + type_ = 0; + clientHostname_ = ""; + clientIdentifier_ = com.google.protobuf.ByteString.EMPTY; + requestedAddress_ = ""; + clientIdentifierString_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Dhcp_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm.internal_static_google_backstory_Dhcp_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Dhcp.class, com.google.backstory.Dhcp.Builder.class); + } + + /** + * + * + *
+   * BOOTP op code. See RFC951, section 3.
+   * 
+ * + * Protobuf enum {@code google.backstory.Dhcp.OpCode} + */ + public enum OpCode implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default opcode.
+     * 
+ * + * UNKNOWN_OPCODE = 0; + */ + UNKNOWN_OPCODE(0), + /** + * + * + *
+     * Request.
+     * 
+ * + * BOOTREQUEST = 1; + */ + BOOTREQUEST(1), + /** + * + * + *
+     * Reply.
+     * 
+ * + * BOOTREPLY = 2; + */ + BOOTREPLY(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "OpCode"); + } + + /** + * + * + *
+     * Default opcode.
+     * 
+ * + * UNKNOWN_OPCODE = 0; + */ + public static final int UNKNOWN_OPCODE_VALUE = 0; + + /** + * + * + *
+     * Request.
+     * 
+ * + * BOOTREQUEST = 1; + */ + public static final int BOOTREQUEST_VALUE = 1; + + /** + * + * + *
+     * Reply.
+     * 
+ * + * BOOTREPLY = 2; + */ + public static final int BOOTREPLY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OpCode valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static OpCode forNumber(int value) { + switch (value) { + case 0: + return UNKNOWN_OPCODE; + case 1: + return BOOTREQUEST; + case 2: + return BOOTREPLY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public OpCode findValueByNumber(int number) { + return OpCode.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Dhcp.getDescriptor().getEnumTypes().get(0); + } + + private static final OpCode[] VALUES = values(); + + public static OpCode valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private OpCode(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Dhcp.OpCode) + } + + /** + * + * + *
+   * DHCP message type. See RFC2131, section 3.1.
+   * 
+ * + * Protobuf enum {@code google.backstory.Dhcp.MessageType} + */ + public enum MessageType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default message type.
+     * 
+ * + * UNKNOWN_MESSAGE_TYPE = 0; + */ + UNKNOWN_MESSAGE_TYPE(0), + /** + * + * + *
+     * DHCPDISCOVER.
+     * 
+ * + * DISCOVER = 1; + */ + DISCOVER(1), + /** + * + * + *
+     * DHCPOFFER.
+     * 
+ * + * OFFER = 2; + */ + OFFER(2), + /** + * + * + *
+     * DHCPREQUEST.
+     * 
+ * + * REQUEST = 3; + */ + REQUEST(3), + /** + * + * + *
+     * DHCPDECLINE.
+     * 
+ * + * DECLINE = 4; + */ + DECLINE(4), + /** + * + * + *
+     * DHCPACK.
+     * 
+ * + * ACK = 5; + */ + ACK(5), + /** + * + * + *
+     * DHCPNAK.
+     * 
+ * + * NAK = 6; + */ + NAK(6), + /** + * + * + *
+     * DHCPRELEASE.
+     * 
+ * + * RELEASE = 7; + */ + RELEASE(7), + /** + * + * + *
+     * DHCPINFORM.
+     * 
+ * + * INFORM = 8; + */ + INFORM(8), + /** + * + * + *
+     * Microsoft Windows DHCP "lease deleted".
+     * 
+ * + * WIN_DELETED = 100; + */ + WIN_DELETED(100), + /** + * + * + *
+     * Microsoft Windows DHCP "lease expired".
+     * 
+ * + * WIN_EXPIRED = 101; + */ + WIN_EXPIRED(101), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "MessageType"); + } + + /** + * + * + *
+     * Default message type.
+     * 
+ * + * UNKNOWN_MESSAGE_TYPE = 0; + */ + public static final int UNKNOWN_MESSAGE_TYPE_VALUE = 0; + + /** + * + * + *
+     * DHCPDISCOVER.
+     * 
+ * + * DISCOVER = 1; + */ + public static final int DISCOVER_VALUE = 1; + + /** + * + * + *
+     * DHCPOFFER.
+     * 
+ * + * OFFER = 2; + */ + public static final int OFFER_VALUE = 2; + + /** + * + * + *
+     * DHCPREQUEST.
+     * 
+ * + * REQUEST = 3; + */ + public static final int REQUEST_VALUE = 3; + + /** + * + * + *
+     * DHCPDECLINE.
+     * 
+ * + * DECLINE = 4; + */ + public static final int DECLINE_VALUE = 4; + + /** + * + * + *
+     * DHCPACK.
+     * 
+ * + * ACK = 5; + */ + public static final int ACK_VALUE = 5; + + /** + * + * + *
+     * DHCPNAK.
+     * 
+ * + * NAK = 6; + */ + public static final int NAK_VALUE = 6; + + /** + * + * + *
+     * DHCPRELEASE.
+     * 
+ * + * RELEASE = 7; + */ + public static final int RELEASE_VALUE = 7; + + /** + * + * + *
+     * DHCPINFORM.
+     * 
+ * + * INFORM = 8; + */ + public static final int INFORM_VALUE = 8; + + /** + * + * + *
+     * Microsoft Windows DHCP "lease deleted".
+     * 
+ * + * WIN_DELETED = 100; + */ + public static final int WIN_DELETED_VALUE = 100; + + /** + * + * + *
+     * Microsoft Windows DHCP "lease expired".
+     * 
+ * + * WIN_EXPIRED = 101; + */ + public static final int WIN_EXPIRED_VALUE = 101; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static MessageType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static MessageType forNumber(int value) { + switch (value) { + case 0: + return UNKNOWN_MESSAGE_TYPE; + case 1: + return DISCOVER; + case 2: + return OFFER; + case 3: + return REQUEST; + case 4: + return DECLINE; + case 5: + return ACK; + case 6: + return NAK; + case 7: + return RELEASE; + case 8: + return INFORM; + case 100: + return WIN_DELETED; + case 101: + return WIN_EXPIRED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public MessageType findValueByNumber(int number) { + return MessageType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.backstory.Dhcp.getDescriptor().getEnumTypes().get(1); + } + + private static final MessageType[] VALUES = values(); + + public static MessageType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private MessageType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.backstory.Dhcp.MessageType) + } + + public interface OptionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.backstory.Dhcp.Option) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Code. See RFC1533.
+     * 
+ * + * uint32 code = 1; + * + * @return The code. + */ + int getCode(); + + /** + * + * + *
+     * Data.
+     * 
+ * + * bytes data = 2; + * + * @return The data. + */ + com.google.protobuf.ByteString getData(); + } + + /** + * + * + *
+   * DHCP options.
+   * 
+ * + * Protobuf type {@code google.backstory.Dhcp.Option} + */ + public static final class Option extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.backstory.Dhcp.Option) + OptionOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 2, + /* suffix= */ "", + "Option"); + } + + // Use Option.newBuilder() to construct. + private Option(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Option() { + data_ = com.google.protobuf.ByteString.EMPTY; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Dhcp_Option_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Dhcp_Option_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Dhcp.Option.class, + com.google.backstory.Dhcp.Option.Builder.class); + } + + public static final int CODE_FIELD_NUMBER = 1; + private int code_ = 0; + + /** + * + * + *
+     * Code. See RFC1533.
+     * 
+ * + * uint32 code = 1; + * + * @return The code. + */ + @java.lang.Override + public int getCode() { + return code_; + } + + public static final int DATA_FIELD_NUMBER = 2; + private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
+     * Data.
+     * 
+ * + * bytes data = 2; + * + * @return The data. + */ + @java.lang.Override + public com.google.protobuf.ByteString getData() { + return data_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (code_ != 0) { + output.writeUInt32(1, code_); + } + if (!data_.isEmpty()) { + output.writeBytes(2, data_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (code_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeUInt32Size(1, code_); + } + if (!data_.isEmpty()) { + size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, data_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.backstory.Dhcp.Option)) { + return super.equals(obj); + } + com.google.backstory.Dhcp.Option other = (com.google.backstory.Dhcp.Option) obj; + + if (getCode() != other.getCode()) return false; + if (!getData().equals(other.getData())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + CODE_FIELD_NUMBER; + hash = (53 * hash) + getCode(); + hash = (37 * hash) + DATA_FIELD_NUMBER; + hash = (53 * hash) + getData().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.backstory.Dhcp.Option parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Dhcp.Option parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Dhcp.Option parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Dhcp.Option parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Dhcp.Option parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.backstory.Dhcp.Option parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.backstory.Dhcp.Option parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Dhcp.Option parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Dhcp.Option parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.backstory.Dhcp.Option parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.backstory.Dhcp.Option parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.backstory.Dhcp.Option parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.backstory.Dhcp.Option prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * DHCP options.
+     * 
+ * + * Protobuf type {@code google.backstory.Dhcp.Option} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.backstory.Dhcp.Option) + com.google.backstory.Dhcp.OptionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.backstory.Udm.internal_static_google_backstory_Dhcp_Option_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.backstory.Udm + .internal_static_google_backstory_Dhcp_Option_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.backstory.Dhcp.Option.class, + com.google.backstory.Dhcp.Option.Builder.class); + } + + // Construct using com.google.backstory.Dhcp.Option.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + code_ = 0; + data_ = com.google.protobuf.ByteString.EMPTY; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.backstory.Udm.internal_static_google_backstory_Dhcp_Option_descriptor; + } + + @java.lang.Override + public com.google.backstory.Dhcp.Option getDefaultInstanceForType() { + return com.google.backstory.Dhcp.Option.getDefaultInstance(); + } + + @java.lang.Override + public com.google.backstory.Dhcp.Option build() { + com.google.backstory.Dhcp.Option result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.backstory.Dhcp.Option buildPartial() { + com.google.backstory.Dhcp.Option result = new com.google.backstory.Dhcp.Option(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.backstory.Dhcp.Option result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.code_ = code_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.data_ = data_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.backstory.Dhcp.Option) { + return mergeFrom((com.google.backstory.Dhcp.Option) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.backstory.Dhcp.Option other) { + if (other == com.google.backstory.Dhcp.Option.getDefaultInstance()) return this; + if (other.getCode() != 0) { + setCode(other.getCode()); + } + if (!other.getData().isEmpty()) { + setData(other.getData()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + code_ = input.readUInt32(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + data_ = input.readBytes(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int code_; + + /** + * + * + *
+       * Code. See RFC1533.
+       * 
+ * + * uint32 code = 1; + * + * @return The code. + */ + @java.lang.Override + public int getCode() { + return code_; + } + + /** + * + * + *
+       * Code. See RFC1533.
+       * 
+ * + * uint32 code = 1; + * + * @param value The code to set. + * @return This builder for chaining. + */ + public Builder setCode(int value) { + + code_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * Code. See RFC1533.
+       * 
+ * + * uint32 code = 1; + * + * @return This builder for chaining. + */ + public Builder clearCode() { + bitField0_ = (bitField0_ & ~0x00000001); + code_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
+       * Data.
+       * 
+ * + * bytes data = 2; + * + * @return The data. + */ + @java.lang.Override + public com.google.protobuf.ByteString getData() { + return data_; + } + + /** + * + * + *
+       * Data.
+       * 
+ * + * bytes data = 2; + * + * @param value The data to set. + * @return This builder for chaining. + */ + public Builder setData(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + data_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Data.
+       * 
+ * + * bytes data = 2; + * + * @return This builder for chaining. + */ + public Builder clearData() { + bitField0_ = (bitField0_ & ~0x00000002); + data_ = getDefaultInstance().getData(); + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.backstory.Dhcp.Option) + } + + // @@protoc_insertion_point(class_scope:google.backstory.Dhcp.Option) + private static final com.google.backstory.Dhcp.Option DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.backstory.Dhcp.Option(); + } + + public static com.google.backstory.Dhcp.Option getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser
+ + com.google.api.grpc + proto-google-cloud-backstory + 0.0.1-SNAPSHOT + diff --git a/java-backstory/google-cloud-backstory/pom.xml b/java-backstory/google-cloud-backstory/pom.xml index dd2bc5ca6631..4f944f8d2ac2 100644 --- a/java-backstory/google-cloud-backstory/pom.xml +++ b/java-backstory/google-cloud-backstory/pom.xml @@ -40,6 +40,10 @@ com.google.api.grpc proto-google-common-protos + + com.google.api.grpc + proto-google-cloud-backstory + com.google.guava diff --git a/java-backstory/pom.xml b/java-backstory/pom.xml index 20a6ccfdf8ad..2bd5628f96f2 100644 --- a/java-backstory/pom.xml +++ b/java-backstory/pom.xml @@ -31,12 +31,18 @@ google-cloud-backstory 0.0.1-SNAPSHOT + + com.google.api.grpc + proto-google-cloud-backstory + 0.0.1-SNAPSHOT + google-cloud-backstory + proto-google-cloud-backstory google-cloud-backstory-bom diff --git a/java-backstory/proto-google-cloud-backstory/pom.xml b/java-backstory/proto-google-cloud-backstory/pom.xml new file mode 100644 index 000000000000..db2a9f266f6f --- /dev/null +++ b/java-backstory/proto-google-cloud-backstory/pom.xml @@ -0,0 +1,36 @@ + + + 4.0.0 + com.google.api.grpc + proto-google-cloud-backstory + 0.0.1-SNAPSHOT + proto-google-cloud-backstory + Proto library for google-cloud-backstory + + com.google.cloud + google-cloud-backstory-parent + 0.0.1-SNAPSHOT + + + + com.google.protobuf + protobuf-java + + + com.google.api.grpc + proto-google-common-protos + + + com.google.api.grpc + proto-google-iam-v1 + + + com.google.api + api-common + + + com.google.guava + guava + + + diff --git a/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AnalyticsMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AnalyticsMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AppCompatMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AppCompatMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Artifact.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Artifact.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Artifact.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Artifact.java diff --git a/java-backstory/src/main/java/com/google/backstory/ArtifactClient.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ArtifactClient.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ArtifactClient.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ArtifactClient.java diff --git a/java-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ArtifactClientOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ArtifactOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Asset.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Asset.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Asset.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Asset.java diff --git a/java-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AssetOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/AtiPrioritization.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AtiPrioritization.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AtiPrioritization.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AtiPrioritization.java diff --git a/java-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AtiPrioritizationOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/AttackDetails.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AttackDetails.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AttackDetails.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AttackDetails.java diff --git a/java-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AttackDetailsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Attribute.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Attribute.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Attribute.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Attribute.java diff --git a/java-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AttributeOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Authentication.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Authentication.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Authentication.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Authentication.java diff --git a/java-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/AuthenticationOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/BoolSequence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BoolSequence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/BoolSequence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BoolSequence.java diff --git a/java-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BoolSequenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Browser.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Browser.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Browser.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Browser.java diff --git a/java-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BrowserOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/BytesSequence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BytesSequence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/BytesSequence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BytesSequence.java diff --git a/java-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/BytesSequenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Certificate.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Certificate.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Certificate.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Certificate.java diff --git a/java-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CertificateOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Cloud.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Cloud.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Cloud.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Cloud.java diff --git a/java-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CloudOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Collection.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Collection.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Collection.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Collection.java diff --git a/java-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CollectionOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/CollectionOuterClass.java diff --git a/java-backstory/src/main/java/com/google/backstory/DNSRecord.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DNSRecord.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DNSRecord.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DNSRecord.java diff --git a/java-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DNSRecordOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccess.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccess.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataAccess.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccess.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabel.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessIngestionLabelOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessLabels.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessLabels.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataAccessLabels.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessLabels.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataAccessLabelsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataTableRowInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DataTableRowInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Dhcp.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Dhcp.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Dhcp.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Dhcp.java diff --git a/java-backstory/src/main/java/com/google/backstory/DhcpOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DhcpOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DhcpOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DhcpOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Dns.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Dns.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Dns.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Dns.java diff --git a/java-backstory/src/main/java/com/google/backstory/DnsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DnsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DnsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DnsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Domain.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Domain.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Domain.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Domain.java diff --git a/java-backstory/src/main/java/com/google/backstory/DomainOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DomainOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DomainOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DomainOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/DoubleSequence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DoubleSequence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DoubleSequence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DoubleSequence.java diff --git a/java-backstory/src/main/java/com/google/backstory/DoubleSequenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DoubleSequenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/DoubleSequenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/DoubleSequenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Element.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Element.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Element.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Element.java diff --git a/java-backstory/src/main/java/com/google/backstory/ElementOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ElementOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ElementOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ElementOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Email.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Email.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Email.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Email.java diff --git a/java-backstory/src/main/java/com/google/backstory/EmailOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EmailOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EmailOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EmailOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Entity.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Entity.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Entity.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Entity.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityGraphEnrichment.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityGraphEnrichment.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityGraphEnrichment.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityGraphEnrichment.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityGraphEnrichmentOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityGraphEnrichmentOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityGraphEnrichmentOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityGraphEnrichmentOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityProto.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityProto.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityProto.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityProto.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityRisk.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityRisk.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityRisk.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityRisk.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityRiskOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityRiskOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityRiskOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityRiskOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/EntityRiskProto.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityRiskProto.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/EntityRiskProto.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/EntityRiskProto.java diff --git a/java-backstory/src/main/java/com/google/backstory/ExifInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ExifInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ExifInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ExifInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/ExifInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ExifInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ExifInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ExifInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Extensions.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Extensions.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Extensions.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Extensions.java diff --git a/java-backstory/src/main/java/com/google/backstory/ExtensionsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ExtensionsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ExtensionsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ExtensionsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Favicon.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Favicon.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Favicon.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Favicon.java diff --git a/java-backstory/src/main/java/com/google/backstory/FaviconOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FaviconOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FaviconOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FaviconOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/File.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/File.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/File.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/File.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataCodesign.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataCodesign.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataCodesign.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataCodesign.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataCodesignOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataCodesignOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataCodesignOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataCodesignOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataImports.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataImports.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataImports.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataImports.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataImportsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataImportsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataImportsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataImportsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataPE.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPE.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataPE.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPE.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataPEOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPEOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataPEOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPEOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataPeResourceInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataSection.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSection.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataSection.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSection.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataSectionOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSectionOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataSectionOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSectionOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileMetadataSignatureInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FileOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FileOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FileOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/FindingVariable.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FindingVariable.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FindingVariable.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FindingVariable.java diff --git a/java-backstory/src/main/java/com/google/backstory/FindingVariableOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FindingVariableOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FindingVariableOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FindingVariableOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Ftp.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Ftp.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Ftp.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Ftp.java diff --git a/java-backstory/src/main/java/com/google/backstory/FtpOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FtpOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/FtpOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/FtpOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Group.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Group.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Group.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Group.java diff --git a/java-backstory/src/main/java/com/google/backstory/GroupOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/GroupOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/GroupOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/GroupOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/GroupedFields.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/GroupedFields.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/GroupedFields.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/GroupedFields.java diff --git a/java-backstory/src/main/java/com/google/backstory/GroupedFieldsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/GroupedFieldsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/GroupedFieldsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/GroupedFieldsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Hardware.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Hardware.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Hardware.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Hardware.java diff --git a/java-backstory/src/main/java/com/google/backstory/HardwareOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/HardwareOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/HardwareOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/HardwareOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Http.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Http.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Http.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Http.java diff --git a/java-backstory/src/main/java/com/google/backstory/HttpOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/HttpOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/HttpOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/HttpOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Id.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Id.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Id.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Id.java diff --git a/java-backstory/src/main/java/com/google/backstory/IdOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/IdOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/IdOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/IdOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/IdOuterClass.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/IdOuterClass.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/IdOuterClass.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/IdOuterClass.java diff --git a/java-backstory/src/main/java/com/google/backstory/Int64Sequence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Int64Sequence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Int64Sequence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Int64Sequence.java diff --git a/java-backstory/src/main/java/com/google/backstory/Int64SequenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Int64SequenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Int64SequenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Int64SequenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Investigation.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Investigation.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Investigation.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Investigation.java diff --git a/java-backstory/src/main/java/com/google/backstory/InvestigationOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/InvestigationOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/InvestigationOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/InvestigationOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Label.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Label.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Label.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Label.java diff --git a/java-backstory/src/main/java/com/google/backstory/LabelOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LabelOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/LabelOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LabelOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/LatencyMetrics.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LatencyMetrics.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/LatencyMetrics.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LatencyMetrics.java diff --git a/java-backstory/src/main/java/com/google/backstory/LatencyMetricsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LatencyMetricsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/LatencyMetricsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LatencyMetricsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/LinuxUtmp.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LinuxUtmp.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/LinuxUtmp.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LinuxUtmp.java diff --git a/java-backstory/src/main/java/com/google/backstory/LinuxUtmpOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LinuxUtmpOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/LinuxUtmpOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LinuxUtmpOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Location.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Location.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Location.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Location.java diff --git a/java-backstory/src/main/java/com/google/backstory/LocationOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LocationOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/LocationOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/LocationOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Metadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Metadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Metadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Metadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/MetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/MetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/MetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/MetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Metric.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Metric.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Metric.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Metric.java diff --git a/java-backstory/src/main/java/com/google/backstory/MetricOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/MetricOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/MetricOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/MetricOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Network.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Network.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Network.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Network.java diff --git a/java-backstory/src/main/java/com/google/backstory/NetworkOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NetworkOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/NetworkOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NetworkOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Noun.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Noun.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Noun.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Noun.java diff --git a/java-backstory/src/main/java/com/google/backstory/NounOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NounOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/NounOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NounOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/NtfsFileMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NtfsFileMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/NtfsFileMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NtfsFileMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/NtfsFileMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NtfsFileMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/NtfsFileMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/NtfsFileMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/OutlookMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/OutlookMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/OutlookMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/OutlookMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/OutlookMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/OutlookMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/OutlookMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/OutlookMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/PDFInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PDFInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PDFInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PDFInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/PDFInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PDFInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PDFInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PDFInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/PeFileMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PeFileMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PeFileMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PeFileMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/PeFileMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PeFileMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PeFileMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PeFileMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Permission.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Permission.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Permission.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Permission.java diff --git a/java-backstory/src/main/java/com/google/backstory/PermissionOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PermissionOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PermissionOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PermissionOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/PlatformSoftware.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PlatformSoftware.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PlatformSoftware.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PlatformSoftware.java diff --git a/java-backstory/src/main/java/com/google/backstory/PlatformSoftwareOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PlatformSoftwareOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PlatformSoftwareOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PlatformSoftwareOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/PopularityRank.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PopularityRank.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PopularityRank.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PopularityRank.java diff --git a/java-backstory/src/main/java/com/google/backstory/PopularityRankOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PopularityRankOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PopularityRankOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PopularityRankOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/PrefetchFileMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PrefetchFileMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PrefetchFileMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PrefetchFileMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/PrefetchFileMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PrefetchFileMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PrefetchFileMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PrefetchFileMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Prevalence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Prevalence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Prevalence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Prevalence.java diff --git a/java-backstory/src/main/java/com/google/backstory/PrevalenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PrevalenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/PrevalenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/PrevalenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Priority.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Priority.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Priority.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Priority.java diff --git a/java-backstory/src/main/java/com/google/backstory/Process.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Process.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Process.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Process.java diff --git a/java-backstory/src/main/java/com/google/backstory/ProcessOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ProcessOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ProcessOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ProcessOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ProxyInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ProxyInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ProxyInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ProxyInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/ProxyInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ProxyInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ProxyInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ProxyInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Reason.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Reason.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Reason.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Reason.java diff --git a/java-backstory/src/main/java/com/google/backstory/Reference.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Reference.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Reference.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Reference.java diff --git a/java-backstory/src/main/java/com/google/backstory/ReferenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ReferenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ReferenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ReferenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Registry.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Registry.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Registry.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Registry.java diff --git a/java-backstory/src/main/java/com/google/backstory/RegistryOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RegistryOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/RegistryOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RegistryOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Relation.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Relation.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Relation.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Relation.java diff --git a/java-backstory/src/main/java/com/google/backstory/RelationOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RelationOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/RelationOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RelationOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Reputation.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Reputation.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Reputation.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Reputation.java diff --git a/java-backstory/src/main/java/com/google/backstory/Resource.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Resource.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Resource.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Resource.java diff --git a/java-backstory/src/main/java/com/google/backstory/ResourceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResourceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ResourceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResourceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ResourceUsage.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResourceUsage.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ResourceUsage.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResourceUsage.java diff --git a/java-backstory/src/main/java/com/google/backstory/ResourceUsageOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResourceUsageOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ResourceUsageOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResourceUsageOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ResponsePlatformInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResponsePlatformInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ResponsePlatformInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResponsePlatformInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/ResponsePlatformInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResponsePlatformInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ResponsePlatformInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ResponsePlatformInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/RiskDelta.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RiskDelta.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/RiskDelta.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RiskDelta.java diff --git a/java-backstory/src/main/java/com/google/backstory/RiskDeltaOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RiskDeltaOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/RiskDeltaOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RiskDeltaOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Role.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Role.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Role.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Role.java diff --git a/java-backstory/src/main/java/com/google/backstory/RoleOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RoleOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/RoleOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/RoleOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/SSLCertificate.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SSLCertificate.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SSLCertificate.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SSLCertificate.java diff --git a/java-backstory/src/main/java/com/google/backstory/SSLCertificateOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SSLCertificateOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SSLCertificateOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SSLCertificateOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ScheduledAnacronTask.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledAnacronTask.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ScheduledAnacronTask.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledAnacronTask.java diff --git a/java-backstory/src/main/java/com/google/backstory/ScheduledAnacronTaskOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledAnacronTaskOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ScheduledAnacronTaskOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledAnacronTaskOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ScheduledCronTask.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledCronTask.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ScheduledCronTask.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledCronTask.java diff --git a/java-backstory/src/main/java/com/google/backstory/ScheduledCronTaskOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledCronTaskOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ScheduledCronTaskOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledCronTaskOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ScheduledTask.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledTask.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ScheduledTask.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledTask.java diff --git a/java-backstory/src/main/java/com/google/backstory/ScheduledTaskOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledTaskOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ScheduledTaskOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ScheduledTaskOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/SecurityResult.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SecurityResult.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SecurityResult.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SecurityResult.java diff --git a/java-backstory/src/main/java/com/google/backstory/SecurityResultOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SecurityResultOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SecurityResultOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SecurityResultOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Service.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Service.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Service.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Service.java diff --git a/java-backstory/src/main/java/com/google/backstory/ServiceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ServiceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ServiceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ServiceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/SignatureInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignatureInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SignatureInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignatureInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/SignatureInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignatureInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SignatureInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignatureInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/SignerInfo.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignerInfo.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SignerInfo.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignerInfo.java diff --git a/java-backstory/src/main/java/com/google/backstory/SignerInfoOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignerInfoOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SignerInfoOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SignerInfoOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Smtp.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Smtp.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Smtp.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Smtp.java diff --git a/java-backstory/src/main/java/com/google/backstory/SmtpOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SmtpOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SmtpOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SmtpOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/SoarAlertMetadata.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SoarAlertMetadata.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SoarAlertMetadata.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SoarAlertMetadata.java diff --git a/java-backstory/src/main/java/com/google/backstory/SoarAlertMetadataOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SoarAlertMetadataOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SoarAlertMetadataOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SoarAlertMetadataOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Software.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Software.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Software.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Software.java diff --git a/java-backstory/src/main/java/com/google/backstory/SoftwareOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SoftwareOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SoftwareOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SoftwareOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Srum.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Srum.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Srum.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Srum.java diff --git a/java-backstory/src/main/java/com/google/backstory/SrumOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SrumOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SrumOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SrumOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Status.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Status.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Status.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Status.java diff --git a/java-backstory/src/main/java/com/google/backstory/StringSequence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringSequence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/StringSequence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringSequence.java diff --git a/java-backstory/src/main/java/com/google/backstory/StringSequenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringSequenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/StringSequenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringSequenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/StringToInt64MapEntry.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringToInt64MapEntry.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/StringToInt64MapEntry.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringToInt64MapEntry.java diff --git a/java-backstory/src/main/java/com/google/backstory/StringToInt64MapEntryOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringToInt64MapEntryOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/StringToInt64MapEntryOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/StringToInt64MapEntryOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/SystemEventDetails.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SystemEventDetails.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SystemEventDetails.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SystemEventDetails.java diff --git a/java-backstory/src/main/java/com/google/backstory/SystemEventDetailsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SystemEventDetailsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/SystemEventDetailsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/SystemEventDetailsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Tags.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tags.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Tags.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tags.java diff --git a/java-backstory/src/main/java/com/google/backstory/TagsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TagsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/TagsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TagsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/ThreatVerdict.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ThreatVerdict.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/ThreatVerdict.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/ThreatVerdict.java diff --git a/java-backstory/src/main/java/com/google/backstory/TimeOff.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TimeOff.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/TimeOff.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TimeOff.java diff --git a/java-backstory/src/main/java/com/google/backstory/TimeOffOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TimeOffOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/TimeOffOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TimeOffOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Tls.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tls.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Tls.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tls.java diff --git a/java-backstory/src/main/java/com/google/backstory/TlsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TlsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/TlsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TlsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Tracker.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tracker.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Tracker.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tracker.java diff --git a/java-backstory/src/main/java/com/google/backstory/TrackerOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TrackerOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/TrackerOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TrackerOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Tunnels.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tunnels.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Tunnels.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Tunnels.java diff --git a/java-backstory/src/main/java/com/google/backstory/TunnelsOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TunnelsOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/TunnelsOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/TunnelsOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/UDM.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDM.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UDM.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDM.java diff --git a/java-backstory/src/main/java/com/google/backstory/UDMOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDMOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UDMOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDMOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Udm.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Udm.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Udm.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Udm.java diff --git a/java-backstory/src/main/java/com/google/backstory/Uint64Sequence.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Uint64Sequence.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Uint64Sequence.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Uint64Sequence.java diff --git a/java-backstory/src/main/java/com/google/backstory/Uint64SequenceOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Uint64SequenceOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Uint64SequenceOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Uint64SequenceOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Url.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Url.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Url.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Url.java diff --git a/java-backstory/src/main/java/com/google/backstory/UrlOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UrlOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UrlOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UrlOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/User.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/User.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/User.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/User.java diff --git a/java-backstory/src/main/java/com/google/backstory/UserAssist.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UserAssist.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UserAssist.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UserAssist.java diff --git a/java-backstory/src/main/java/com/google/backstory/UserAssistOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UserAssistOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UserAssistOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UserAssistOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/UserOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UserOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UserOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UserOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/UsnJournal.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UsnJournal.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UsnJournal.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UsnJournal.java diff --git a/java-backstory/src/main/java/com/google/backstory/UsnJournalOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UsnJournalOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/UsnJournalOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UsnJournalOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Verdict.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Verdict.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Verdict.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Verdict.java diff --git a/java-backstory/src/main/java/com/google/backstory/Volume.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Volume.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Volume.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Volume.java diff --git a/java-backstory/src/main/java/com/google/backstory/VolumeOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/VolumeOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/VolumeOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/VolumeOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Vulnerabilities.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Vulnerabilities.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Vulnerabilities.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Vulnerabilities.java diff --git a/java-backstory/src/main/java/com/google/backstory/VulnerabilitiesOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/VulnerabilitiesOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/VulnerabilitiesOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/VulnerabilitiesOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/Vulnerability.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Vulnerability.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/Vulnerability.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/Vulnerability.java diff --git a/java-backstory/src/main/java/com/google/backstory/VulnerabilityOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/VulnerabilityOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/VulnerabilityOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/VulnerabilityOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/WindowsEventLog.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsEventLog.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/WindowsEventLog.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsEventLog.java diff --git a/java-backstory/src/main/java/com/google/backstory/WindowsEventLogOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsEventLogOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/WindowsEventLogOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsEventLogOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/WindowsScheduledTask.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsScheduledTask.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/WindowsScheduledTask.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsScheduledTask.java diff --git a/java-backstory/src/main/java/com/google/backstory/WindowsScheduledTaskOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsScheduledTaskOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/WindowsScheduledTaskOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WindowsScheduledTaskOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/WmiPersistenceItem.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WmiPersistenceItem.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/WmiPersistenceItem.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WmiPersistenceItem.java diff --git a/java-backstory/src/main/java/com/google/backstory/WmiPersistenceItemOrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WmiPersistenceItemOrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/WmiPersistenceItemOrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/WmiPersistenceItemOrBuilder.java diff --git a/java-backstory/src/main/java/com/google/backstory/X509.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/X509.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/X509.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/X509.java diff --git a/java-backstory/src/main/java/com/google/backstory/X509OrBuilder.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/X509OrBuilder.java similarity index 100% rename from java-backstory/src/main/java/com/google/backstory/X509OrBuilder.java rename to java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/X509OrBuilder.java diff --git a/java-backstory/src/main/proto/backstory/collection.proto b/java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/collection.proto similarity index 100% rename from java-backstory/src/main/proto/backstory/collection.proto rename to java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/collection.proto diff --git a/java-backstory/src/main/proto/backstory/data_access.proto b/java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/data_access.proto similarity index 100% rename from java-backstory/src/main/proto/backstory/data_access.proto rename to java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/data_access.proto diff --git a/java-backstory/src/main/proto/backstory/entity.proto b/java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/entity.proto similarity index 100% rename from java-backstory/src/main/proto/backstory/entity.proto rename to java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/entity.proto diff --git a/java-backstory/src/main/proto/backstory/entity_risk.proto b/java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/entity_risk.proto similarity index 100% rename from java-backstory/src/main/proto/backstory/entity_risk.proto rename to java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/entity_risk.proto diff --git a/java-backstory/src/main/proto/backstory/id.proto b/java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/id.proto similarity index 100% rename from java-backstory/src/main/proto/backstory/id.proto rename to java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/id.proto diff --git a/java-backstory/src/main/proto/backstory/udm.proto b/java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/udm.proto similarity index 100% rename from java-backstory/src/main/proto/backstory/udm.proto rename to java-backstory/proto-google-cloud-backstory/src/main/proto/backstory/udm.proto From a5bf76e62d27f2635e7604b8271b1fe29873aade Mon Sep 17 00:00:00 2001 From: blakeli Date: Tue, 2 Jun 2026 18:50:37 -0400 Subject: [PATCH 6/6] chore(backstory): fix missing license header in UDM.java due to case-insensitive collision --- .../src/main/java/com/google/backstory/UDM.java | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDM.java b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDM.java index a37891d9aa4d..44d81d47f29d 100644 --- a/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDM.java +++ b/java-backstory/proto-google-cloud-backstory/src/main/java/com/google/backstory/UDM.java @@ -1,3 +1,18 @@ +/* + * Copyright 2026 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // NO CHECKED-IN PROTOBUF GENCODE // source: backstory/udm.proto