From 1f6525f7cf1331ac132e083af2dffa6e042e93a5 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Mon, 18 Apr 2022 17:42:33 +0200 Subject: [PATCH 01/21] chore(deps): update dependency com.google.analytics:google-analytics-data to v0.11.10 (#481) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.analytics:google-analytics-data](https://togithub.com/googleapis/java-analytics-data) | `0.11.9` -> `0.11.10` | [![age](https://badges.renovateapi.com/packages/maven/com.google.analytics:google-analytics-data/0.11.10/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.analytics:google-analytics-data/0.11.10/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.analytics:google-analytics-data/0.11.10/compatibility-slim/0.11.9)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.analytics:google-analytics-data/0.11.10/confidence-slim/0.11.9)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-analytics-data ### [`v0.11.10`](https://togithub.com/googleapis/java-analytics-data/blob/HEAD/CHANGELOG.md#​01110-httpsgithubcomgoogleapisjava-analytics-datacomparev0119v01110-2022-04-15) [Compare Source](https://togithub.com/googleapis/java-analytics-data/compare/v0.11.9...v0.11.10)
--- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- README.md | 6 +++--- samples/install-without-bom/pom.xml | 2 +- samples/snippets/pom.xml | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 12bfdbe7..93d148ce 100644 --- a/README.md +++ b/README.md @@ -22,20 +22,20 @@ If you are using Maven, add this to your pom.xml file: com.google.analytics google-analytics-data - 0.11.9 + 0.11.10 ``` If you are using Gradle without BOM, add this to your dependencies ```Groovy -implementation 'com.google.analytics:google-analytics-data:0.11.9' +implementation 'com.google.analytics:google-analytics-data:0.11.10' ``` If you are using SBT, add this to your dependencies ```Scala -libraryDependencies += "com.google.analytics" % "google-analytics-data" % "0.11.9" +libraryDependencies += "com.google.analytics" % "google-analytics-data" % "0.11.10" ``` ## Authentication diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml index 3ce6f136..071d4296 100644 --- a/samples/install-without-bom/pom.xml +++ b/samples/install-without-bom/pom.xml @@ -29,7 +29,7 @@ com.google.analytics google-analytics-data - 0.11.9 + 0.11.10 diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index 0fc3f35f..2bfb7c8c 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -40,7 +40,7 @@ com.google.analytics google-analytics-data - 0.11.9 + 0.11.10 com.google.auth From ca8e107485b8820488f955d6c646c1ccfaa449cd Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 21 Apr 2022 16:50:19 +0200 Subject: [PATCH 02/21] build(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.4.0 (#483) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [org.apache.maven.plugins:maven-javadoc-plugin](https://maven.apache.org/plugins/) | `3.3.2` -> `3.4.0` | [![age](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-javadoc-plugin/3.4.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-javadoc-plugin/3.4.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-javadoc-plugin/3.4.0/compatibility-slim/3.3.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-javadoc-plugin/3.4.0/confidence-slim/3.3.2)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index f2a5bf21..ec851775 100644 --- a/pom.xml +++ b/pom.xml @@ -140,7 +140,7 @@ org.apache.maven.plugins maven-javadoc-plugin - 3.3.2 + 3.4.0 html From 2336d75fbb04e3516817e6961cf8fa7336c313d1 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 21 Apr 2022 17:34:11 +0200 Subject: [PATCH 03/21] build(deps): update dependency com.google.cloud:google-cloud-shared-config to v1.3.3 (#482) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-shared-config](https://togithub.com/googleapis/java-shared-config) | `1.3.2` -> `1.3.3` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.3.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.3.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.3.3/compatibility-slim/1.3.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.3.3/confidence-slim/1.3.2)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-shared-config ### [`v1.3.3`](https://togithub.com/googleapis/java-shared-config/blob/HEAD/CHANGELOG.md#​133-httpsgithubcomgoogleapisjava-shared-configcomparev132v133-2022-04-19) [Compare Source](https://togithub.com/googleapis/java-shared-config/compare/v1.3.2...v1.3.3)
--- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- google-analytics-data-bom/pom.xml | 2 +- pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/google-analytics-data-bom/pom.xml b/google-analytics-data-bom/pom.xml index 2910c849..2c677eb7 100644 --- a/google-analytics-data-bom/pom.xml +++ b/google-analytics-data-bom/pom.xml @@ -8,7 +8,7 @@ com.google.cloud google-cloud-shared-config - 1.3.2 + 1.3.3 Google Analytics Data BOM diff --git a/pom.xml b/pom.xml index ec851775..41c40126 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 1.3.2 + 1.3.3 From 569de9491348f32c317654ed7611b709cf38c88f Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 21 Apr 2022 19:40:22 +0200 Subject: [PATCH 04/21] build(deps): update dependency org.sonatype.plugins:nexus-staging-maven-plugin to v1.6.13 (#484) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [org.sonatype.plugins:nexus-staging-maven-plugin](http://www.sonatype.com/) ([source](https://togithub.com/sonatype/nexus-maven-plugins)) | `1.6.11` -> `1.6.13` | [![age](https://badges.renovateapi.com/packages/maven/org.sonatype.plugins:nexus-staging-maven-plugin/1.6.13/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/org.sonatype.plugins:nexus-staging-maven-plugin/1.6.13/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/org.sonatype.plugins:nexus-staging-maven-plugin/1.6.13/compatibility-slim/1.6.11)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/org.sonatype.plugins:nexus-staging-maven-plugin/1.6.13/confidence-slim/1.6.11)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
sonatype/nexus-maven-plugins ### [`v1.6.13`](https://togithub.com/sonatype/nexus-maven-plugins/compare/release-1.6.12...release-1.6.13) [Compare Source](https://togithub.com/sonatype/nexus-maven-plugins/compare/release-1.6.12...release-1.6.13) ### [`v1.6.12`](https://togithub.com/sonatype/nexus-maven-plugins/compare/release-1.6.11...release-1.6.12) [Compare Source](https://togithub.com/sonatype/nexus-maven-plugins/compare/release-1.6.11...release-1.6.12)
--- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- samples/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/pom.xml b/samples/pom.xml index f44b21b5..8b9749bf 100644 --- a/samples/pom.xml +++ b/samples/pom.xml @@ -46,7 +46,7 @@ org.sonatype.plugins nexus-staging-maven-plugin - 1.6.11 + 1.6.13 true From f03c3ebfc0119e5654a71a0cc71102580922ad88 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Wed, 27 Apr 2022 17:44:27 +0200 Subject: [PATCH 05/21] chore(deps): update dependency com.google.cloud:libraries-bom to v25.2.0 (#487) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:libraries-bom](https://cloud.google.com/java/docs/bom) ([source](https://togithub.com/GoogleCloudPlatform/cloud-opensource-java)) | `25.1.0` -> `25.2.0` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/25.2.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/25.2.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/25.2.0/compatibility-slim/25.1.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/25.2.0/confidence-slim/25.1.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- samples/snapshot/pom.xml | 2 +- samples/snippets/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index a20a135e..c2122821 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -28,7 +28,7 @@ com.google.cloud libraries-bom - 25.1.0 + 25.2.0 pom import diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index 2bfb7c8c..f906f874 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -28,7 +28,7 @@ com.google.cloud libraries-bom - 25.1.0 + 25.2.0 pom import From e15659c791d3a904f8ef573e2a66181434732586 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 29 Apr 2022 22:18:21 +0200 Subject: [PATCH 06/21] build(deps): update dependency com.google.cloud:google-cloud-shared-config to v1.4.0 (#489) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-shared-config](https://togithub.com/googleapis/java-shared-config) | `1.3.3` -> `1.4.0` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.4.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.4.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.4.0/compatibility-slim/1.3.3)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.4.0/confidence-slim/1.3.3)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-shared-config ### [`v1.4.0`](https://togithub.com/googleapis/java-shared-config/blob/HEAD/CHANGELOG.md#​140-httpsgithubcomgoogleapisjava-shared-configcomparev133v140-2022-04-28) [Compare Source](https://togithub.com/googleapis/java-shared-config/compare/v1.3.3...v1.4.0) ##### Features - **java:** remove native image module ([#​471](https://togithub.com/googleapis/java-shared-config/issues/471)) ([7fcba01](https://togithub.com/googleapis/java-shared-config/commit/7fcba016b3138d7beaa4e962853f9bc80f59438c)) ##### [1.3.3](https://togithub.com/googleapis/java-shared-config/compare/v1.3.2...v1.3.3) (2022-04-19) ##### Bug Fixes - **java:** remove protobuf feature from native profile ([#​461](https://togithub.com/googleapis/java-shared-config/issues/461)) ([ffd07cb](https://togithub.com/googleapis/java-shared-config/commit/ffd07cb18ee7d45d4daee1d9ea6f6d321fdca874)) ##### Dependencies - update dependency com.google.cloud:native-image-support to v0.12.11 ([#​459](https://togithub.com/googleapis/java-shared-config/issues/459)) ([d20008d](https://togithub.com/googleapis/java-shared-config/commit/d20008df15209708fdf9d06828b567778190f4d0)) - update dependency com.google.cloud:native-image-support to v0.13.1 ([#​465](https://togithub.com/googleapis/java-shared-config/issues/465)) ([b202064](https://togithub.com/googleapis/java-shared-config/commit/b2020648816feb4740ad70acedfed470d7da5bcf)) ##### [1.3.2](https://togithub.com/googleapis/java-shared-config/compare/v1.3.1...v1.3.2) (2022-03-28) ##### Dependencies - revert google-java-format to 1.7 ([#​453](https://togithub.com/googleapis/java-shared-config/issues/453)) ([cbc777f](https://togithub.com/googleapis/java-shared-config/commit/cbc777f3e9ab75edb6fa2e0268a7446ae4111725)) ##### [1.3.1](https://togithub.com/googleapis/java-shared-config/compare/v1.3.0...v1.3.1) (2022-03-25) ##### Dependencies - update dependency com.google.cloud:native-image-support to v0.12.10 ([#​443](https://togithub.com/googleapis/java-shared-config/issues/443)) ([5b39d5e](https://togithub.com/googleapis/java-shared-config/commit/5b39d5ee15121f052226ff873b6ab101e9c71de5)) - update dependency com.google.googlejavaformat:google-java-format to v1.15.0 ([#​426](https://togithub.com/googleapis/java-shared-config/issues/426)) ([4c3c4b6](https://togithub.com/googleapis/java-shared-config/commit/4c3c4b66129632181e6bc363a0ecccf4f5aac914)) - update dependency org.graalvm.buildtools:junit-platform-native to v0.9.11 ([#​448](https://togithub.com/googleapis/java-shared-config/issues/448)) ([f7f518e](https://togithub.com/googleapis/java-shared-config/commit/f7f518e87d1d9feb9ac54d7c099f97d8751ee3da)) - update dependency org.graalvm.buildtools:native-maven-plugin to v0.9.11 ([#​449](https://togithub.com/googleapis/java-shared-config/issues/449)) ([3e1c0b5](https://togithub.com/googleapis/java-shared-config/commit/3e1c0b5a1d2f4a0db88c06a0d683ed90cbc745e2))
--- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- google-analytics-data-bom/pom.xml | 2 +- pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/google-analytics-data-bom/pom.xml b/google-analytics-data-bom/pom.xml index 2c677eb7..f6da1d32 100644 --- a/google-analytics-data-bom/pom.xml +++ b/google-analytics-data-bom/pom.xml @@ -8,7 +8,7 @@ com.google.cloud google-cloud-shared-config - 1.3.3 + 1.4.0 Google Analytics Data BOM diff --git a/pom.xml b/pom.xml index 41c40126..084610e4 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 1.3.3 + 1.4.0 From e96123116ba88ee896c259e1140645e3c62b3347 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 5 May 2022 00:56:11 +0200 Subject: [PATCH 07/21] build(deps): update dependency org.apache.maven.plugins:maven-project-info-reports-plugin to v3.3.0 (#488) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [org.apache.maven.plugins:maven-project-info-reports-plugin](https://maven.apache.org/plugins/) | `3.2.2` -> `3.3.0` | [![age](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.3.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.3.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.3.0/compatibility-slim/3.2.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.3.0/confidence-slim/3.2.2)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 084610e4..f8b7efe5 100644 --- a/pom.xml +++ b/pom.xml @@ -113,7 +113,7 @@ org.apache.maven.plugins maven-project-info-reports-plugin - 3.2.2 + 3.3.0 From 8b0004cf71d430903d59faa2da84499b8c3b14ba Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Thu, 5 May 2022 19:12:19 +0000 Subject: [PATCH 08/21] Synchronize new proto/yaml changes. (#486) - [ ] Regenerate this pull request now. PiperOrigin-RevId: 446264416 Source-Link: https://github.com/googleapis/googleapis/commit/3a976a38edfb67cff5432cd2bfe1edf7746822b5 Source-Link: https://github.com/googleapis/googleapis-gen/commit/0548a716a01383382344958ab20bb4d522388154 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDU0OGE3MTZhMDEzODMzODIzNDQ5NThhYjIwYmI0ZDUyMjM4ODE1NCJ9 chore(deps): upgrade gapic-generator-java to 2.7.0 and update gax-java to 2.16.0 PiperOrigin-RevId: 446250659 Source-Link: https://github.com/googleapis/googleapis/commit/dc4ef314fecf1b00833e78288cf2eb4d2b165ad1 Source-Link: https://github.com/googleapis/googleapis-gen/commit/5fdda4ddfbab87998e77e4a453e0ff87986d2db8 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNWZkZGE0ZGRmYmFiODc5OThlNzdlNGE0NTNlMGZmODc5ODZkMmRiOCJ9 chore(bazel): update version of Protobuf to v3.20.1 PiperOrigin-RevId: 444328399 Source-Link: https://github.com/googleapis/googleapis/commit/c7ca416c2856aad6a3f7092924e56b8cf0cb2534 Source-Link: https://github.com/googleapis/googleapis-gen/commit/d61705453a62b3ecda78aa30c192840ebc5a8a90 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZDYxNzA1NDUzYTYyYjNlY2RhNzhhYTMwYzE5Mjg0MGViYzVhOGE5MCJ9 --- .../data/v1beta/BetaAnalyticsDataClient.java | 40 ++++++++++++++- .../v1beta/BetaAnalyticsDataSettings.java | 4 +- .../analytics/data/v1beta/package-info.java | 4 +- .../v1beta/stub/BetaAnalyticsDataStub.java | 2 +- .../stub/BetaAnalyticsDataStubSettings.java | 4 +- .../GrpcBetaAnalyticsDataCallableFactory.java | 2 +- .../stub/GrpcBetaAnalyticsDataStub.java | 2 +- .../v1beta/BetaAnalyticsDataClientTest.java | 2 +- .../data/v1beta/MockBetaAnalyticsData.java | 2 +- .../v1beta/MockBetaAnalyticsDataImpl.java | 2 +- .../v1beta/BatchRunPivotReportsRequest.java | 2 + .../v1beta/BatchRunPivotReportsResponse.java | 2 + .../data/v1beta/BatchRunReportsRequest.java | 2 + .../data/v1beta/BatchRunReportsResponse.java | 2 + .../v1beta/CheckCompatibilityRequest.java | 2 + .../v1beta/CheckCompatibilityResponse.java | 2 + .../google/analytics/data/v1beta/Cohort.java | 2 + .../data/v1beta/CohortReportSettings.java | 2 + .../analytics/data/v1beta/CohortSpec.java | 2 + .../analytics/data/v1beta/CohortsRange.java | 2 + .../analytics/data/v1beta/DateRange.java | 2 + .../analytics/data/v1beta/Dimension.java | 2 + .../data/v1beta/DimensionCompatibility.java | 2 + .../data/v1beta/DimensionExpression.java | 15 ++++-- .../data/v1beta/DimensionHeader.java | 2 + .../data/v1beta/DimensionMetadata.java | 2 + .../analytics/data/v1beta/DimensionValue.java | 2 + .../google/analytics/data/v1beta/Filter.java | 22 ++++++-- .../data/v1beta/FilterExpression.java | 14 ++++-- .../data/v1beta/FilterExpressionList.java | 2 + .../data/v1beta/GetMetadataRequest.java | 2 + .../analytics/data/v1beta/Metadata.java | 2 + .../analytics/data/v1beta/MetadataName.java | 2 +- .../google/analytics/data/v1beta/Metric.java | 2 + .../data/v1beta/MetricCompatibility.java | 2 + .../analytics/data/v1beta/MetricHeader.java | 2 + .../analytics/data/v1beta/MetricMetadata.java | 2 + .../analytics/data/v1beta/MetricValue.java | 2 + .../analytics/data/v1beta/MinuteRange.java | 50 ++++++++++--------- .../data/v1beta/MinuteRangeOrBuilder.java | 16 +++--- .../analytics/data/v1beta/NumericValue.java | 6 ++- .../google/analytics/data/v1beta/OrderBy.java | 19 +++++-- .../google/analytics/data/v1beta/Pivot.java | 2 + .../data/v1beta/PivotDimensionHeader.java | 2 + .../analytics/data/v1beta/PivotHeader.java | 2 + .../analytics/data/v1beta/PropertyQuota.java | 2 + .../analytics/data/v1beta/QuotaStatus.java | 2 + .../data/v1beta/ResponseMetaData.java | 6 +++ .../com/google/analytics/data/v1beta/Row.java | 2 + .../data/v1beta/RunPivotReportRequest.java | 2 + .../data/v1beta/RunPivotReportResponse.java | 2 + .../data/v1beta/RunRealtimeReportRequest.java | 2 + .../v1beta/RunRealtimeReportResponse.java | 2 + .../data/v1beta/RunReportRequest.java | 2 + .../data/v1beta/RunReportResponse.java | 2 + .../google/analytics/data/v1beta/data.proto | 8 +-- 56 files changed, 231 insertions(+), 63 deletions(-) diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClient.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClient.java index 6bc3ea3f..fcd8eb10 100644 --- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClient.java +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClient.java @@ -1,5 +1,5 @@ /* - * Copyright 2021 Google LLC + * Copyright 2022 Google LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -33,6 +33,8 @@ * calls that map to API methods. Sample code to get started: * *
{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
  * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
  *   RunReportRequest request =
  *       RunReportRequest.newBuilder()
@@ -85,6 +87,8 @@
  * 

To customize credentials: * *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
  * BetaAnalyticsDataSettings betaAnalyticsDataSettings =
  *     BetaAnalyticsDataSettings.newBuilder()
  *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
@@ -96,6 +100,8 @@
  * 

To customize the endpoint: * *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
  * BetaAnalyticsDataSettings betaAnalyticsDataSettings =
  *     BetaAnalyticsDataSettings.newBuilder().setEndpoint(myEndpoint).build();
  * BetaAnalyticsDataClient betaAnalyticsDataClient =
@@ -169,6 +175,8 @@ public BetaAnalyticsDataStub getStub() {
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   RunReportRequest request =
    *       RunReportRequest.newBuilder()
@@ -209,6 +217,8 @@ public final RunReportResponse runReport(RunReportRequest request) {
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   RunReportRequest request =
    *       RunReportRequest.newBuilder()
@@ -248,6 +258,8 @@ public final UnaryCallable runReportCallabl
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   RunPivotReportRequest request =
    *       RunPivotReportRequest.newBuilder()
@@ -284,6 +296,8 @@ public final RunPivotReportResponse runPivotReport(RunPivotReportRequest request
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   RunPivotReportRequest request =
    *       RunPivotReportRequest.newBuilder()
@@ -318,6 +332,8 @@ public final RunPivotReportResponse runPivotReport(RunPivotReportRequest request
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   BatchRunReportsRequest request =
    *       BatchRunReportsRequest.newBuilder()
@@ -342,6 +358,8 @@ public final BatchRunReportsResponse batchRunReports(BatchRunReportsRequest requ
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   BatchRunReportsRequest request =
    *       BatchRunReportsRequest.newBuilder()
@@ -367,6 +385,8 @@ public final BatchRunReportsResponse batchRunReports(BatchRunReportsRequest requ
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   BatchRunPivotReportsRequest request =
    *       BatchRunPivotReportsRequest.newBuilder()
@@ -392,6 +412,8 @@ public final BatchRunPivotReportsResponse batchRunPivotReports(
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   BatchRunPivotReportsRequest request =
    *       BatchRunPivotReportsRequest.newBuilder()
@@ -424,6 +446,8 @@ public final BatchRunPivotReportsResponse batchRunPivotReports(
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   MetadataName name = MetadataName.of("[PROPERTY]");
    *   Metadata response = betaAnalyticsDataClient.getMetadata(name);
@@ -459,6 +483,8 @@ public final Metadata getMetadata(MetadataName name) {
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   String name = MetadataName.of("[PROPERTY]").toString();
    *   Metadata response = betaAnalyticsDataClient.getMetadata(name);
@@ -493,6 +519,8 @@ public final Metadata getMetadata(String name) {
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   GetMetadataRequest request =
    *       GetMetadataRequest.newBuilder().setName(MetadataName.of("[PROPERTY]").toString()).build();
@@ -521,6 +549,8 @@ public final Metadata getMetadata(GetMetadataRequest request) {
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   GetMetadataRequest request =
    *       GetMetadataRequest.newBuilder().setName(MetadataName.of("[PROPERTY]").toString()).build();
@@ -543,6 +573,8 @@ public final UnaryCallable getMetadataCallable() {
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   RunRealtimeReportRequest request =
    *       RunRealtimeReportRequest.newBuilder()
@@ -576,6 +608,8 @@ public final RunRealtimeReportResponse runRealtimeReport(RunRealtimeReportReques
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   RunRealtimeReportRequest request =
    *       RunRealtimeReportRequest.newBuilder()
@@ -618,6 +652,8 @@ public final RunRealtimeReportResponse runRealtimeReport(RunRealtimeReportReques
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   CheckCompatibilityRequest request =
    *       CheckCompatibilityRequest.newBuilder()
@@ -655,6 +691,8 @@ public final CheckCompatibilityResponse checkCompatibility(CheckCompatibilityReq
    * 

Sample code: * *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
    * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
    *   CheckCompatibilityRequest request =
    *       CheckCompatibilityRequest.newBuilder()
diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataSettings.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataSettings.java
index 1b53659a..bc1d0cee 100644
--- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataSettings.java
+++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/BetaAnalyticsDataSettings.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -49,6 +49,8 @@
  * 

For example, to set the total timeout of runReport to 30 seconds: * *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
  * BetaAnalyticsDataSettings.Builder betaAnalyticsDataSettingsBuilder =
  *     BetaAnalyticsDataSettings.newBuilder();
  * betaAnalyticsDataSettingsBuilder
diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/package-info.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/package-info.java
index 44439dd3..9fce29c0 100644
--- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/package-info.java
+++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/package-info.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -24,6 +24,8 @@
  * 

Sample for BetaAnalyticsDataClient: * *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
  * try (BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.create()) {
  *   RunReportRequest request =
  *       RunReportRequest.newBuilder()
diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStub.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStub.java
index 96b8e57b..1f39e741 100644
--- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStub.java
+++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStub.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStubSettings.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStubSettings.java
index 4606ba3a..be447b8f 100644
--- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStubSettings.java
+++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/BetaAnalyticsDataStubSettings.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -72,6 +72,8 @@
  * 

For example, to set the total timeout of runReport to 30 seconds: * *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
  * BetaAnalyticsDataStubSettings.Builder betaAnalyticsDataSettingsBuilder =
  *     BetaAnalyticsDataStubSettings.newBuilder();
  * betaAnalyticsDataSettingsBuilder
diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataCallableFactory.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataCallableFactory.java
index c1606ff0..b12e6e4e 100644
--- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataCallableFactory.java
+++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataCallableFactory.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataStub.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataStub.java
index 5994aba8..586ca680 100644
--- a/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataStub.java
+++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1beta/stub/GrpcBetaAnalyticsDataStub.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClientTest.java b/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClientTest.java
index 5a705d40..25470ad6 100644
--- a/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClientTest.java
+++ b/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/BetaAnalyticsDataClientTest.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsData.java b/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsData.java
index 2d49aa0c..584e549e 100644
--- a/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsData.java
+++ b/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsData.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsDataImpl.java b/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsDataImpl.java
index 618d05c2..ef40e48e 100644
--- a/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsDataImpl.java
+++ b/google-analytics-data/src/test/java/com/google/analytics/data/v1beta/MockBetaAnalyticsDataImpl.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsRequest.java
index 893069af..3e3757a4 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsRequest.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsRequest.java
@@ -104,6 +104,8 @@ private BatchRunPivotReportsRequest(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsResponse.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsResponse.java
index dad592ab..870058c6 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsResponse.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunPivotReportsResponse.java
@@ -104,6 +104,8 @@ private BatchRunPivotReportsResponse(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsRequest.java
index bb6c60c9..b2fa5e94 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsRequest.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsRequest.java
@@ -103,6 +103,8 @@ private BatchRunReportsRequest(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsResponse.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsResponse.java
index 53855a60..6ea58ea2 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsResponse.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/BatchRunReportsResponse.java
@@ -103,6 +103,8 @@ private BatchRunReportsResponse(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityRequest.java
index d76d84c4..7486453c 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityRequest.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityRequest.java
@@ -158,6 +158,8 @@ private CheckCompatibilityRequest(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityResponse.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityResponse.java
index d4bdc8c6..f0b227ba 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityResponse.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CheckCompatibilityResponse.java
@@ -110,6 +110,8 @@ private CheckCompatibilityResponse(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Cohort.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Cohort.java
index cfbf8c85..01718c73 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Cohort.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Cohort.java
@@ -114,6 +114,8 @@ private Cohort(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortReportSettings.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortReportSettings.java
index a7be7e46..8fb6d206 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortReportSettings.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortReportSettings.java
@@ -84,6 +84,8 @@ private CohortReportSettings(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortSpec.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortSpec.java
index 85ac27e7..afa54f35 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortSpec.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortSpec.java
@@ -138,6 +138,8 @@ private CohortSpec(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortsRange.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortsRange.java
index 89faa7b5..01288a51 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortsRange.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/CohortsRange.java
@@ -99,6 +99,8 @@ private CohortsRange(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DateRange.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DateRange.java
index ae0a3ce8..5627b500 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DateRange.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DateRange.java
@@ -105,6 +105,8 @@ private DateRange(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Dimension.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Dimension.java
index e689caf8..ca2201ab 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Dimension.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Dimension.java
@@ -108,6 +108,8 @@ private Dimension(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionCompatibility.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionCompatibility.java
index bfe2a8d6..52282ece 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionCompatibility.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionCompatibility.java
@@ -106,6 +106,8 @@ private DimensionCompatibility(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionExpression.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionExpression.java
index ee7cefb8..1f39bcb5 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionExpression.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionExpression.java
@@ -152,6 +152,8 @@ private DimensionExpression(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
@@ -277,6 +279,8 @@ private CaseExpression(
         }
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
         throw e.setUnfinishedMessage(this);
+      } catch (com.google.protobuf.UninitializedMessageException e) {
+        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
       } catch (java.io.IOException e) {
         throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
       } finally {
@@ -1025,6 +1029,8 @@ private ConcatenateExpression(
         }
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
         throw e.setUnfinishedMessage(this);
+      } catch (com.google.protobuf.UninitializedMessageException e) {
+        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
       } catch (java.io.IOException e) {
         throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
       } finally {
@@ -2683,8 +2689,9 @@ public Builder mergeLowerCase(
       } else {
         if (oneExpressionCase_ == 4) {
           lowerCaseBuilder_.mergeFrom(value);
+        } else {
+          lowerCaseBuilder_.setMessage(value);
         }
-        lowerCaseBuilder_.setMessage(value);
       }
       oneExpressionCase_ = 4;
       return this;
@@ -2908,8 +2915,9 @@ public Builder mergeUpperCase(
       } else {
         if (oneExpressionCase_ == 5) {
           upperCaseBuilder_.mergeFrom(value);
+        } else {
+          upperCaseBuilder_.setMessage(value);
         }
-        upperCaseBuilder_.setMessage(value);
       }
       oneExpressionCase_ = 5;
       return this;
@@ -3149,8 +3157,9 @@ public Builder mergeConcatenate(
       } else {
         if (oneExpressionCase_ == 6) {
           concatenateBuilder_.mergeFrom(value);
+        } else {
+          concatenateBuilder_.setMessage(value);
         }
-        concatenateBuilder_.setMessage(value);
       }
       oneExpressionCase_ = 6;
       return this;
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionHeader.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionHeader.java
index 6b833e2e..4b1356ab 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionHeader.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionHeader.java
@@ -91,6 +91,8 @@ private DimensionHeader(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionMetadata.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionMetadata.java
index f839aa91..16328792 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionMetadata.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionMetadata.java
@@ -129,6 +129,8 @@ private DimensionMetadata(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionValue.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionValue.java
index 524b4c88..de0488c7 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionValue.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/DimensionValue.java
@@ -86,6 +86,8 @@ private DimensionValue(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Filter.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Filter.java
index ea691b3e..1c439269 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Filter.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Filter.java
@@ -166,6 +166,8 @@ private Filter(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
@@ -340,6 +342,8 @@ private StringFilter(
         }
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
         throw e.setUnfinishedMessage(this);
+      } catch (com.google.protobuf.UninitializedMessageException e) {
+        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
       } catch (java.io.IOException e) {
         throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
       } finally {
@@ -1528,6 +1532,8 @@ private InListFilter(
         }
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
         throw e.setUnfinishedMessage(this);
+      } catch (com.google.protobuf.UninitializedMessageException e) {
+        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
       } catch (java.io.IOException e) {
         throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
       } finally {
@@ -2427,6 +2433,8 @@ private NumericFilter(
         }
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
         throw e.setUnfinishedMessage(this);
+      } catch (com.google.protobuf.UninitializedMessageException e) {
+        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
       } catch (java.io.IOException e) {
         throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
       } finally {
@@ -3615,6 +3623,8 @@ private BetweenFilter(
         }
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
         throw e.setUnfinishedMessage(this);
+      } catch (com.google.protobuf.UninitializedMessageException e) {
+        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
       } catch (java.io.IOException e) {
         throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
       } finally {
@@ -5510,8 +5520,9 @@ public Builder mergeStringFilter(com.google.analytics.data.v1beta.Filter.StringF
       } else {
         if (oneFilterCase_ == 3) {
           stringFilterBuilder_.mergeFrom(value);
+        } else {
+          stringFilterBuilder_.setMessage(value);
         }
-        stringFilterBuilder_.setMessage(value);
       }
       oneFilterCase_ = 3;
       return this;
@@ -5721,8 +5732,9 @@ public Builder mergeInListFilter(com.google.analytics.data.v1beta.Filter.InListF
       } else {
         if (oneFilterCase_ == 4) {
           inListFilterBuilder_.mergeFrom(value);
+        } else {
+          inListFilterBuilder_.setMessage(value);
         }
-        inListFilterBuilder_.setMessage(value);
       }
       oneFilterCase_ = 4;
       return this;
@@ -5932,8 +5944,9 @@ public Builder mergeNumericFilter(com.google.analytics.data.v1beta.Filter.Numeri
       } else {
         if (oneFilterCase_ == 5) {
           numericFilterBuilder_.mergeFrom(value);
+        } else {
+          numericFilterBuilder_.setMessage(value);
         }
-        numericFilterBuilder_.setMessage(value);
       }
       oneFilterCase_ = 5;
       return this;
@@ -6143,8 +6156,9 @@ public Builder mergeBetweenFilter(com.google.analytics.data.v1beta.Filter.Betwee
       } else {
         if (oneFilterCase_ == 6) {
           betweenFilterBuilder_.mergeFrom(value);
+        } else {
+          betweenFilterBuilder_.setMessage(value);
         }
-        betweenFilterBuilder_.setMessage(value);
       }
       oneFilterCase_ = 6;
       return this;
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpression.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpression.java
index 2f6047b4..bdbc736c 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpression.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpression.java
@@ -151,6 +151,8 @@ private FilterExpression(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
@@ -994,8 +996,9 @@ public Builder mergeAndGroup(com.google.analytics.data.v1beta.FilterExpressionLi
       } else {
         if (exprCase_ == 1) {
           andGroupBuilder_.mergeFrom(value);
+        } else {
+          andGroupBuilder_.setMessage(value);
         }
-        andGroupBuilder_.setMessage(value);
       }
       exprCase_ = 1;
       return this;
@@ -1204,8 +1207,9 @@ public Builder mergeOrGroup(com.google.analytics.data.v1beta.FilterExpressionLis
       } else {
         if (exprCase_ == 2) {
           orGroupBuilder_.mergeFrom(value);
+        } else {
+          orGroupBuilder_.setMessage(value);
         }
-        orGroupBuilder_.setMessage(value);
       }
       exprCase_ = 2;
       return this;
@@ -1413,8 +1417,9 @@ public Builder mergeNotExpression(com.google.analytics.data.v1beta.FilterExpress
       } else {
         if (exprCase_ == 3) {
           notExpressionBuilder_.mergeFrom(value);
+        } else {
+          notExpressionBuilder_.setMessage(value);
         }
-        notExpressionBuilder_.setMessage(value);
       }
       exprCase_ = 3;
       return this;
@@ -1631,8 +1636,9 @@ public Builder mergeFilter(com.google.analytics.data.v1beta.Filter value) {
       } else {
         if (exprCase_ == 4) {
           filterBuilder_.mergeFrom(value);
+        } else {
+          filterBuilder_.setMessage(value);
         }
-        filterBuilder_.setMessage(value);
       }
       exprCase_ = 4;
       return this;
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpressionList.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpressionList.java
index b98c33ca..bc5d8d6f 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpressionList.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/FilterExpressionList.java
@@ -95,6 +95,8 @@ private FilterExpressionList(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/GetMetadataRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/GetMetadataRequest.java
index ba989de0..f91837b8 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/GetMetadataRequest.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/GetMetadataRequest.java
@@ -88,6 +88,8 @@ private GetMetadataRequest(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metadata.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metadata.java
index 9aa44745..6dbfe59f 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metadata.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metadata.java
@@ -116,6 +116,8 @@ private Metadata(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetadataName.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetadataName.java
index 969799f2..0fe36b44 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetadataName.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetadataName.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2021 Google LLC
+ * Copyright 2022 Google LLC
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metric.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metric.java
index b7f45f6d..4f0b200e 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metric.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Metric.java
@@ -103,6 +103,8 @@ private Metric(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricCompatibility.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricCompatibility.java
index 730006c6..4ddddcda 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricCompatibility.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricCompatibility.java
@@ -105,6 +105,8 @@ private MetricCompatibility(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricHeader.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricHeader.java
index dbc42080..dd6797f6 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricHeader.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricHeader.java
@@ -99,6 +99,8 @@ private MetricHeader(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricMetadata.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricMetadata.java
index 0e1d42d9..f2baaf5b 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricMetadata.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricMetadata.java
@@ -171,6 +171,8 @@ private MetricMetadata(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricValue.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricValue.java
index af070afd..3cbd35f6 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricValue.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MetricValue.java
@@ -86,6 +86,8 @@ private MetricValue(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRange.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRange.java
index c930f8ad..ddadc997 100644
--- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRange.java
+++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRange.java
@@ -102,6 +102,8 @@ private MinuteRange(
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
+    } catch (com.google.protobuf.UninitializedMessageException e) {
+      throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
       throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
@@ -137,8 +139,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
    * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`.
    * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics
    * properties can request up to the last 30 minutes of event data
-   * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to
-   * the last 60 minutes of event data (`startMinutesAgo <= 59`).
+   * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request
+   * up to the last 60 minutes of event data (`startMinutesAgo <= 59`).
    * 
* * optional int32 start_minutes_ago = 1; @@ -158,8 +160,8 @@ public boolean hasStartMinutesAgo() { * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -183,8 +185,8 @@ public int getStartMinutesAgo() { * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; @@ -205,8 +207,8 @@ public boolean hasEndMinutesAgo() { * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; @@ -651,8 +653,8 @@ public Builder mergeFrom( * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -672,8 +674,8 @@ public boolean hasStartMinutesAgo() { * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -693,8 +695,8 @@ public int getStartMinutesAgo() { * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -717,8 +719,8 @@ public Builder setStartMinutesAgo(int value) { * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -743,8 +745,8 @@ public Builder clearStartMinutesAgo() { * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; @@ -765,8 +767,8 @@ public boolean hasEndMinutesAgo() { * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; @@ -787,8 +789,8 @@ public int getEndMinutesAgo() { * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; @@ -812,8 +814,8 @@ public Builder setEndMinutesAgo(int value) { * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRangeOrBuilder.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRangeOrBuilder.java index 3726076c..64a24d0e 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRangeOrBuilder.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/MinuteRangeOrBuilder.java @@ -32,8 +32,8 @@ public interface MinuteRangeOrBuilder * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -50,8 +50,8 @@ public interface MinuteRangeOrBuilder * event data from 29 minutes ago and after. Cannot be after `endMinutesAgo`. * If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics * properties can request up to the last 30 minutes of event data - * (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - * the last 60 minutes of event data (`startMinutesAgo <= 59`). + * (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + * up to the last 60 minutes of event data (`startMinutesAgo <= 59`). *
* * optional int32 start_minutes_ago = 1; @@ -70,8 +70,8 @@ public interface MinuteRangeOrBuilder * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; @@ -89,8 +89,8 @@ public interface MinuteRangeOrBuilder * ago. * If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics * properties can request any minute in the last 30 minutes of event data - * (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - * minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + * (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + * any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). *
* * optional int32 end_minutes_ago = 2; diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/NumericValue.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/NumericValue.java index 027ae1aa..a3863b5a 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/NumericValue.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/NumericValue.java @@ -70,14 +70,14 @@ private NumericValue( break; case 8: { - oneValueCase_ = 1; oneValue_ = input.readInt64(); + oneValueCase_ = 1; break; } case 17: { - oneValueCase_ = 2; oneValue_ = input.readDouble(); + oneValueCase_ = 2; break; } default: @@ -91,6 +91,8 @@ private NumericValue( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/OrderBy.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/OrderBy.java index e7d417c4..0c1ec818 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/OrderBy.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/OrderBy.java @@ -144,6 +144,8 @@ private OrderBy( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { @@ -267,6 +269,8 @@ private MetricOrderBy( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { @@ -953,6 +957,8 @@ private DimensionOrderBy( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { @@ -2055,6 +2061,8 @@ private PivotOrderBy( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { @@ -2227,6 +2235,8 @@ private PivotSelection( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(this); @@ -4910,8 +4920,9 @@ public Builder mergeMetric(com.google.analytics.data.v1beta.OrderBy.MetricOrderB } else { if (oneOrderByCase_ == 1) { metricBuilder_.mergeFrom(value); + } else { + metricBuilder_.setMessage(value); } - metricBuilder_.setMessage(value); } oneOrderByCase_ = 1; return this; @@ -5120,8 +5131,9 @@ public Builder mergeDimension(com.google.analytics.data.v1beta.OrderBy.Dimension } else { if (oneOrderByCase_ == 2) { dimensionBuilder_.mergeFrom(value); + } else { + dimensionBuilder_.setMessage(value); } - dimensionBuilder_.setMessage(value); } oneOrderByCase_ = 2; return this; @@ -5332,8 +5344,9 @@ public Builder mergePivot(com.google.analytics.data.v1beta.OrderBy.PivotOrderBy } else { if (oneOrderByCase_ == 3) { pivotBuilder_.mergeFrom(value); + } else { + pivotBuilder_.setMessage(value); } - pivotBuilder_.setMessage(value); } oneOrderByCase_ = 3; return this; diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Pivot.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Pivot.java index d3a2e672..9917b4f6 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Pivot.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Pivot.java @@ -140,6 +140,8 @@ private Pivot( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotDimensionHeader.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotDimensionHeader.java index c6c5b916..2052de33 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotDimensionHeader.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotDimensionHeader.java @@ -94,6 +94,8 @@ private PivotDimensionHeader( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotHeader.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotHeader.java index 6391c40b..de283d5e 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotHeader.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PivotHeader.java @@ -101,6 +101,8 @@ private PivotHeader( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PropertyQuota.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PropertyQuota.java index 5836d2c1..ea83a8f6 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PropertyQuota.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/PropertyQuota.java @@ -161,6 +161,8 @@ private PropertyQuota( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/QuotaStatus.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/QuotaStatus.java index 87c4fd23..1ad1d455 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/QuotaStatus.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/QuotaStatus.java @@ -89,6 +89,8 @@ private QuotaStatus( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/ResponseMetaData.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/ResponseMetaData.java index e7d0f6d7..d04a9ce2 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/ResponseMetaData.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/ResponseMetaData.java @@ -129,6 +129,8 @@ private ResponseMetaData( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { @@ -326,6 +328,8 @@ private SchemaRestrictionResponse( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { @@ -568,6 +572,8 @@ private ActiveMetricRestriction( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(this); diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Row.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Row.java index d76dc002..88f8faac 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Row.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/Row.java @@ -140,6 +140,8 @@ private Row( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportRequest.java index 3830daad..a75a6e88 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportRequest.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportRequest.java @@ -205,6 +205,8 @@ private RunPivotReportRequest( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportResponse.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportResponse.java index 7eff2522..475def98 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportResponse.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunPivotReportResponse.java @@ -186,6 +186,8 @@ private RunPivotReportResponse( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportRequest.java index 32dfaf3a..2fdc5925 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportRequest.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportRequest.java @@ -208,6 +208,8 @@ private RunRealtimeReportRequest( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportResponse.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportResponse.java index 7a86dd3a..299b42e9 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportResponse.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunRealtimeReportResponse.java @@ -185,6 +185,8 @@ private RunRealtimeReportResponse( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportRequest.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportRequest.java index 4462e42b..a9921b3f 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportRequest.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportRequest.java @@ -241,6 +241,8 @@ private RunReportRequest( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportResponse.java b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportResponse.java index f2cdbdee..934ed440 100644 --- a/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportResponse.java +++ b/proto-google-analytics-data-v1beta/src/main/java/com/google/analytics/data/v1beta/RunReportResponse.java @@ -202,6 +202,8 @@ private RunReportResponse( } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { diff --git a/proto-google-analytics-data-v1beta/src/main/proto/google/analytics/data/v1beta/data.proto b/proto-google-analytics-data-v1beta/src/main/proto/google/analytics/data/v1beta/data.proto index 7f9b1450..a33d4553 100644 --- a/proto-google-analytics-data-v1beta/src/main/proto/google/analytics/data/v1beta/data.proto +++ b/proto-google-analytics-data-v1beta/src/main/proto/google/analytics/data/v1beta/data.proto @@ -52,8 +52,8 @@ message MinuteRange { // // If unspecified, `startMinutesAgo` is defaulted to 29. Standard Analytics // properties can request up to the last 30 minutes of event data - // (`startMinutesAgo <= 29`), and 360 Analytics properties can request up to - // the last 60 minutes of event data (`startMinutesAgo <= 59`). + // (`startMinutesAgo <= 29`), and Google Analytics 360 properties can request + // up to the last 60 minutes of event data (`startMinutesAgo <= 59`). optional int32 start_minutes_ago = 1; // The inclusive end minute for the query as a number of minutes before now. @@ -63,8 +63,8 @@ message MinuteRange { // // If unspecified, `endMinutesAgo` is defaulted to 0. Standard Analytics // properties can request any minute in the last 30 minutes of event data - // (`endMinutesAgo <= 29`), and 360 Analytics properties can request any - // minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). + // (`endMinutesAgo <= 29`), and Google Analytics 360 properties can request + // any minute in the last 60 minutes of event data (`endMinutesAgo <= 59`). optional int32 end_minutes_ago = 2; // Assigns a name to this minute range. The dimension `dateRange` is valued to From 1969feecac73306525a79e39b7098fdb2a5a05d2 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Tue, 17 May 2022 06:16:32 -0700 Subject: [PATCH 09/21] feat: add `runFunnelReport` method to the Alpha version of the Data API (#490) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: add `runFunnelReport` method to the Alpha version of the Data API PiperOrigin-RevId: 446813357 Source-Link: https://github.com/googleapis/googleapis/commit/6d3ae1aca71340d9d92ccade8147a98bb5de4309 Source-Link: https://github.com/googleapis/googleapis-gen/commit/1cfc0eb66874f05c4182d422e1c89bd5e2f2abe7 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMWNmYzBlYjY2ODc0ZjA1YzQxODJkNDIyZTFjODliZDVlMmYyYWJlNyJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Ignore changes in v1alpha API * Delete clirr-ignored-differences.xml * Update clirr-ignored-differences.xml Ignore v1Alpha changes * Update clirr-ignored-differences.xml Ignore v1alpha changes. * Update clirr-ignored-differences.xml Ignore deleted fields in v1alpha. * Update clirr-ignored-differences.xml * Update clirr-ignored-differences.xml * Update clirr-ignored-differences.xml * Update clirr-ignored-differences.xml * Update clirr-ignored-differences.xml * Create clirr-ignored-differences.xml * Update pom.xml Remove unused dependencies. * Update pom.xml Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- google-analytics-data-bom/pom.xml | 10 + .../clirr-ignored-differences.xml | 17 +- google-analytics-data/pom.xml | 9 + .../v1alpha/AlphaAnalyticsDataClient.java | 272 ++ .../v1alpha/AlphaAnalyticsDataSettings.java | 187 + .../data/v1alpha/gapic_metadata.json | 21 + .../analytics/data/v1alpha/package-info.java | 51 + .../v1alpha/stub/AlphaAnalyticsDataStub.java | 42 + .../stub/AlphaAnalyticsDataStubSettings.java | 282 ++ ...GrpcAlphaAnalyticsDataCallableFactory.java | 115 + .../stub/GrpcAlphaAnalyticsDataStub.java | 167 + .../v1alpha/AlphaAnalyticsDataClientTest.java | 151 + .../data/v1alpha/MockAlphaAnalyticsData.java | 59 + .../v1alpha/MockAlphaAnalyticsDataImpl.java | 81 + .../clirr-ignored-differences.xml | 45 + grpc-google-analytics-data-v1alpha/pom.xml | 65 + .../data/v1alpha/AlphaAnalyticsDataGrpc.java | 398 ++ pom.xml | 12 + .../clirr-ignored-differences.xml | 45 + proto-google-analytics-data-v1alpha/pom.xml | 34 + .../data/v1alpha/AnalyticsDataApiProto.java | 136 + .../analytics/data/v1alpha/BetweenFilter.java | 1013 +++++ .../data/v1alpha/BetweenFilterOrBuilder.java | 95 + .../analytics/data/v1alpha/DateRange.java | 1059 +++++ .../data/v1alpha/DateRangeOrBuilder.java | 118 + .../analytics/data/v1alpha/Dimension.java | 999 +++++ .../data/v1alpha/DimensionExpression.java | 3355 +++++++++++++++ .../v1alpha/DimensionExpressionOrBuilder.java | 142 + .../data/v1alpha/DimensionHeader.java | 644 +++ .../v1alpha/DimensionHeaderOrBuilder.java | 50 + .../data/v1alpha/DimensionOrBuilder.java | 106 + .../data/v1alpha/DimensionValue.java | 767 ++++ .../data/v1alpha/DimensionValueOrBuilder.java | 64 + .../data/v1alpha/EventCriteriaScoping.java | 162 + .../data/v1alpha/EventExclusionDuration.java | 162 + .../analytics/data/v1alpha/EventSegment.java | 1035 +++++ .../v1alpha/EventSegmentConditionGroup.java | 960 +++++ .../EventSegmentConditionGroupOrBuilder.java | 99 + .../data/v1alpha/EventSegmentCriteria.java | 1054 +++++ .../EventSegmentCriteriaOrBuilder.java | 94 + .../data/v1alpha/EventSegmentExclusion.java | 949 +++++ .../EventSegmentExclusionOrBuilder.java | 95 + .../data/v1alpha/EventSegmentOrBuilder.java | 96 + .../google/analytics/data/v1alpha/Filter.java | 1947 +++++++++ .../data/v1alpha/FilterExpression.java | 1782 ++++++++ .../data/v1alpha/FilterExpressionList.java | 964 +++++ .../FilterExpressionListOrBuilder.java | 77 + .../v1alpha/FilterExpressionOrBuilder.java | 170 + .../data/v1alpha/FilterOrBuilder.java | 194 + .../google/analytics/data/v1alpha/Funnel.java | 1058 +++++ .../data/v1alpha/FunnelBreakdown.java | 908 ++++ .../v1alpha/FunnelBreakdownOrBuilder.java | 95 + .../data/v1alpha/FunnelEventFilter.java | 1062 +++++ .../v1alpha/FunnelEventFilterOrBuilder.java | 117 + .../analytics/data/v1alpha/FunnelFilter.java | 1941 +++++++++ .../data/v1alpha/FunnelFilterExpression.java | 2140 ++++++++++ .../v1alpha/FunnelFilterExpressionList.java | 976 +++++ .../FunnelFilterExpressionListOrBuilder.java | 78 + .../FunnelFilterExpressionOrBuilder.java | 211 + .../data/v1alpha/FunnelFilterOrBuilder.java | 192 + .../data/v1alpha/FunnelNextAction.java | 930 +++++ .../v1alpha/FunnelNextActionOrBuilder.java | 98 + .../data/v1alpha/FunnelOrBuilder.java | 92 + .../data/v1alpha/FunnelParameterFilter.java | 2437 +++++++++++ .../FunnelParameterFilterExpression.java | 1892 +++++++++ .../FunnelParameterFilterExpressionList.java | 1036 +++++ ...arameterFilterExpressionListOrBuilder.java | 85 + ...nelParameterFilterExpressionOrBuilder.java | 177 + .../FunnelParameterFilterOrBuilder.java | 286 ++ .../data/v1alpha/FunnelResponseMetadata.java | 1111 +++++ .../FunnelResponseMetadataOrBuilder.java | 108 + .../analytics/data/v1alpha/FunnelStep.java | 1429 +++++++ .../data/v1alpha/FunnelStepOrBuilder.java | 164 + .../data/v1alpha/FunnelSubReport.java | 2327 +++++++++++ .../v1alpha/FunnelSubReportOrBuilder.java | 236 ++ .../analytics/data/v1alpha/InListFilter.java | 840 ++++ .../data/v1alpha/InListFilterOrBuilder.java | 93 + .../analytics/data/v1alpha/MetricHeader.java | 792 ++++ .../data/v1alpha/MetricHeaderOrBuilder.java | 75 + .../analytics/data/v1alpha/MetricType.java | 398 ++ .../analytics/data/v1alpha/MetricValue.java | 766 ++++ .../data/v1alpha/MetricValueOrBuilder.java | 64 + .../analytics/data/v1alpha/NumericFilter.java | 1117 +++++ .../data/v1alpha/NumericFilterOrBuilder.java | 85 + .../analytics/data/v1alpha/NumericValue.java | 805 ++++ .../data/v1alpha/NumericValueOrBuilder.java | 77 + .../analytics/data/v1alpha/PropertyQuota.java | 2038 +++++++++ .../data/v1alpha/PropertyQuotaOrBuilder.java | 238 ++ .../analytics/data/v1alpha/QuotaStatus.java | 636 +++ .../data/v1alpha/QuotaStatusOrBuilder.java | 51 + .../data/v1alpha/ReportingApiProto.java | 1111 +++++ .../google/analytics/data/v1alpha/Row.java | 1543 +++++++ .../analytics/data/v1alpha/RowOrBuilder.java | 134 + .../data/v1alpha/RunFunnelReportRequest.java | 3672 +++++++++++++++++ .../RunFunnelReportRequestOrBuilder.java | 447 ++ .../data/v1alpha/RunFunnelReportResponse.java | 1615 ++++++++ .../RunFunnelReportResponseOrBuilder.java | 189 + .../data/v1alpha/SamplingMetadata.java | 676 +++ .../v1alpha/SamplingMetadataOrBuilder.java | 58 + .../analytics/data/v1alpha/Segment.java | 1695 ++++++++ .../data/v1alpha/SegmentEventFilter.java | 1066 +++++ .../v1alpha/SegmentEventFilterOrBuilder.java | 117 + .../analytics/data/v1alpha/SegmentFilter.java | 2225 ++++++++++ .../data/v1alpha/SegmentFilterExpression.java | 2144 ++++++++++ .../v1alpha/SegmentFilterExpressionList.java | 979 +++++ .../SegmentFilterExpressionListOrBuilder.java | 78 + .../SegmentFilterExpressionOrBuilder.java | 211 + .../data/v1alpha/SegmentFilterOrBuilder.java | 227 + .../data/v1alpha/SegmentFilterScoping.java | 657 +++ .../SegmentFilterScopingOrBuilder.java | 70 + .../data/v1alpha/SegmentOrBuilder.java | 169 + .../data/v1alpha/SegmentParameterFilter.java | 2723 ++++++++++++ .../SegmentParameterFilterExpression.java | 1912 +++++++++ .../SegmentParameterFilterExpressionList.java | 1041 +++++ ...arameterFilterExpressionListOrBuilder.java | 85 + ...entParameterFilterExpressionOrBuilder.java | 183 + .../SegmentParameterFilterOrBuilder.java | 322 ++ .../SegmentParameterFilterScoping.java | 724 ++++ ...egmentParameterFilterScopingOrBuilder.java | 90 + .../data/v1alpha/SessionCriteriaScoping.java | 186 + .../v1alpha/SessionExclusionDuration.java | 186 + .../data/v1alpha/SessionSegment.java | 1041 +++++ .../v1alpha/SessionSegmentConditionGroup.java | 1028 +++++ ...SessionSegmentConditionGroupOrBuilder.java | 117 + .../data/v1alpha/SessionSegmentCriteria.java | 1054 +++++ .../SessionSegmentCriteriaOrBuilder.java | 94 + .../data/v1alpha/SessionSegmentExclusion.java | 963 +++++ .../SessionSegmentExclusionOrBuilder.java | 100 + .../data/v1alpha/SessionSegmentOrBuilder.java | 99 + .../analytics/data/v1alpha/StringFilter.java | 1129 +++++ .../data/v1alpha/StringFilterOrBuilder.java | 88 + .../data/v1alpha/UserCriteriaScoping.java | 210 + .../data/v1alpha/UserExclusionDuration.java | 186 + .../analytics/data/v1alpha/UserSegment.java | 1025 +++++ .../v1alpha/UserSegmentConditionGroup.java | 1020 +++++ .../UserSegmentConditionGroupOrBuilder.java | 117 + .../data/v1alpha/UserSegmentCriteria.java | 1682 ++++++++ .../v1alpha/UserSegmentCriteriaOrBuilder.java | 168 + .../data/v1alpha/UserSegmentExclusion.java | 945 +++++ .../UserSegmentExclusionOrBuilder.java | 95 + .../data/v1alpha/UserSegmentOrBuilder.java | 96 + .../v1alpha/UserSegmentSequenceGroup.java | 1587 +++++++ .../UserSegmentSequenceGroupOrBuilder.java | 178 + .../data/v1alpha/UserSequenceStep.java | 1096 +++++ .../v1alpha/UserSequenceStepOrBuilder.java | 126 + .../data/v1alpha/analytics_data_api.proto | 166 + .../google/analytics/data/v1alpha/data.proto | 1230 ++++++ versions.txt | 2 + 148 files changed, 91888 insertions(+), 1 deletion(-) create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClient.java create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataSettings.java create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/gapic_metadata.json create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/package-info.java create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStub.java create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStubSettings.java create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataCallableFactory.java create mode 100644 google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataStub.java create mode 100644 google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClientTest.java create mode 100644 google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsData.java create mode 100644 google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsDataImpl.java create mode 100644 grpc-google-analytics-data-v1alpha/clirr-ignored-differences.xml create mode 100644 grpc-google-analytics-data-v1alpha/pom.xml create mode 100644 grpc-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataGrpc.java create mode 100644 proto-google-analytics-data-v1alpha/clirr-ignored-differences.xml create mode 100644 proto-google-analytics-data-v1alpha/pom.xml create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AnalyticsDataApiProto.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRange.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRangeOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Dimension.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpression.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpressionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeader.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeaderOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValue.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValueOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventCriteriaScoping.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventExclusionDuration.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegment.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroup.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroupOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteria.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteriaOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusion.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Filter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpression.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionList.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionListOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Funnel.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdown.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdownOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpression.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionList.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionListOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextAction.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextActionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpression.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionList.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionListOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadata.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadataOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStep.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStepOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReport.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReportOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeader.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeaderOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricType.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValue.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValueOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValue.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValueOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuota.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuotaOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatus.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatusOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/ReportingApiProto.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Row.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RowOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequest.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequestOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponse.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponseOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadata.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadataOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Segment.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpression.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionList.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionListOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScoping.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScopingOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpression.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionList.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionListOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScoping.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScopingOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionCriteriaScoping.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionExclusionDuration.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegment.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroup.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroupOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteria.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteriaOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusion.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilter.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilterOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserCriteriaScoping.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserExclusionDuration.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegment.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroup.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroupOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteria.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteriaOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusion.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusionOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroup.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroupOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStep.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStepOrBuilder.java create mode 100644 proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/analytics_data_api.proto create mode 100644 proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/data.proto diff --git a/google-analytics-data-bom/pom.xml b/google-analytics-data-bom/pom.xml index f6da1d32..cee94a05 100644 --- a/google-analytics-data-bom/pom.xml +++ b/google-analytics-data-bom/pom.xml @@ -63,11 +63,21 @@ grpc-google-analytics-data-v1beta 0.11.10 + + com.google.api.grpc + grpc-google-analytics-data-v1alpha + 0.11.10 + com.google.api.grpc proto-google-analytics-data-v1beta 0.11.10 + + com.google.api.grpc + proto-google-analytics-data-v1alpha + 0.11.10 + diff --git a/google-analytics-data/clirr-ignored-differences.xml b/google-analytics-data/clirr-ignored-differences.xml index 163361e7..a3466b5a 100644 --- a/google-analytics-data/clirr-ignored-differences.xml +++ b/google-analytics-data/clirr-ignored-differences.xml @@ -3,6 +3,21 @@ 8001 - com/google/analytics/data/v1alpha/** + com/google/analytics/data/v1alpha/* + + + 7006 + com/google/analytics/data/v1alpha/* + * + + + 7002 + com/google/analytics/data/v1alpha/* + * + + + 7005 + com/google/analytics/data/v1alpha/* + * diff --git a/google-analytics-data/pom.xml b/google-analytics-data/pom.xml index 2462e75d..ae68608d 100644 --- a/google-analytics-data/pom.xml +++ b/google-analytics-data/pom.xml @@ -42,6 +42,10 @@ proto-google-common-protos + + com.google.api.grpc + proto-google-analytics-data-v1alpha + com.google.api.grpc proto-google-analytics-data-v1beta @@ -76,6 +80,11 @@ grpc-google-analytics-data-v1beta test + + com.google.api.grpc + grpc-google-analytics-data-v1alpha + test + com.google.api diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClient.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClient.java new file mode 100644 index 00000000..37078f50 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClient.java @@ -0,0 +1,272 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha; + +import com.google.analytics.data.v1alpha.stub.AlphaAnalyticsDataStub; +import com.google.analytics.data.v1alpha.stub.AlphaAnalyticsDataStubSettings; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import java.io.IOException; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: Google Analytics reporting data service. + * + *

This class provides the ability to make remote calls to the backing service through method + * calls that map to API methods. Sample code to get started: + * + *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
+ * try (AlphaAnalyticsDataClient alphaAnalyticsDataClient = AlphaAnalyticsDataClient.create()) {
+ *   RunFunnelReportRequest request =
+ *       RunFunnelReportRequest.newBuilder()
+ *           .setProperty("property-993141291")
+ *           .addAllDateRanges(new ArrayList())
+ *           .setFunnel(Funnel.newBuilder().build())
+ *           .setFunnelBreakdown(FunnelBreakdown.newBuilder().build())
+ *           .setFunnelNextAction(FunnelNextAction.newBuilder().build())
+ *           .addAllSegments(new ArrayList())
+ *           .setLimit(102976443)
+ *           .setDimensionFilter(FilterExpression.newBuilder().build())
+ *           .setReturnPropertyQuota(true)
+ *           .build();
+ *   RunFunnelReportResponse response = alphaAnalyticsDataClient.runFunnelReport(request);
+ * }
+ * }
+ * + *

Note: close() needs to be called on the AlphaAnalyticsDataClient object to clean up resources + * such as threads. In the example above, try-with-resources is used, which automatically calls + * close(). + * + *

The surface of this class includes several types of Java methods for each of the API's + * methods: + * + *

    + *
  1. A "flattened" method. With this type of method, the fields of the request type have been + * converted into function parameters. It may be the case that not all fields are available as + * parameters, and not every API method will have a flattened method entry point. + *
  2. A "request object" method. This type of method only takes one parameter, a request object, + * which must be constructed before the call. Not every API method will have a request object + * method. + *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API + * callable object, which can be used to initiate calls to the service. + *
+ * + *

See the individual methods for example code. + * + *

Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *

This class can be customized by passing in a custom instance of AlphaAnalyticsDataSettings to + * create(). For example: + * + *

To customize credentials: + * + *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
+ * AlphaAnalyticsDataSettings alphaAnalyticsDataSettings =
+ *     AlphaAnalyticsDataSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * AlphaAnalyticsDataClient alphaAnalyticsDataClient =
+ *     AlphaAnalyticsDataClient.create(alphaAnalyticsDataSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
+ * AlphaAnalyticsDataSettings alphaAnalyticsDataSettings =
+ *     AlphaAnalyticsDataSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * AlphaAnalyticsDataClient alphaAnalyticsDataClient =
+ *     AlphaAnalyticsDataClient.create(alphaAnalyticsDataSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class AlphaAnalyticsDataClient implements BackgroundResource { + private final AlphaAnalyticsDataSettings settings; + private final AlphaAnalyticsDataStub stub; + + /** Constructs an instance of AlphaAnalyticsDataClient with default settings. */ + public static final AlphaAnalyticsDataClient create() throws IOException { + return create(AlphaAnalyticsDataSettings.newBuilder().build()); + } + + /** + * Constructs an instance of AlphaAnalyticsDataClient, using the given settings. The channels are + * created based on the settings passed in, or defaults for any settings that are not set. + */ + public static final AlphaAnalyticsDataClient create(AlphaAnalyticsDataSettings settings) + throws IOException { + return new AlphaAnalyticsDataClient(settings); + } + + /** + * Constructs an instance of AlphaAnalyticsDataClient, using the given stub for making calls. This + * is for advanced usage - prefer using create(AlphaAnalyticsDataSettings). + */ + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public static final AlphaAnalyticsDataClient create(AlphaAnalyticsDataStub stub) { + return new AlphaAnalyticsDataClient(stub); + } + + /** + * Constructs an instance of AlphaAnalyticsDataClient, using the given settings. This is protected + * so that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected AlphaAnalyticsDataClient(AlphaAnalyticsDataSettings settings) throws IOException { + this.settings = settings; + this.stub = ((AlphaAnalyticsDataStubSettings) settings.getStubSettings()).createStub(); + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + protected AlphaAnalyticsDataClient(AlphaAnalyticsDataStub stub) { + this.settings = null; + this.stub = stub; + } + + public final AlphaAnalyticsDataSettings getSettings() { + return settings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public AlphaAnalyticsDataStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns a customized funnel report of your Google Analytics event data. The data returned from + * the API is as a table with columns for the requested dimensions and metrics. + * + *

Funnel exploration lets you visualize the steps your users take to complete a task and + * quickly see how well they are succeeding or failing at each step. For example, how do prospects + * become shoppers and then become buyers? How do one time buyers become repeat buyers? With this + * information, you can improve inefficient or abandoned customer journeys. To learn more, see + * [GA4 Funnel Explorations](https://support.google.com/analytics/answer/9327974). + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
+   * try (AlphaAnalyticsDataClient alphaAnalyticsDataClient = AlphaAnalyticsDataClient.create()) {
+   *   RunFunnelReportRequest request =
+   *       RunFunnelReportRequest.newBuilder()
+   *           .setProperty("property-993141291")
+   *           .addAllDateRanges(new ArrayList())
+   *           .setFunnel(Funnel.newBuilder().build())
+   *           .setFunnelBreakdown(FunnelBreakdown.newBuilder().build())
+   *           .setFunnelNextAction(FunnelNextAction.newBuilder().build())
+   *           .addAllSegments(new ArrayList())
+   *           .setLimit(102976443)
+   *           .setDimensionFilter(FilterExpression.newBuilder().build())
+   *           .setReturnPropertyQuota(true)
+   *           .build();
+   *   RunFunnelReportResponse response = alphaAnalyticsDataClient.runFunnelReport(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final RunFunnelReportResponse runFunnelReport(RunFunnelReportRequest request) { + return runFunnelReportCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns a customized funnel report of your Google Analytics event data. The data returned from + * the API is as a table with columns for the requested dimensions and metrics. + * + *

Funnel exploration lets you visualize the steps your users take to complete a task and + * quickly see how well they are succeeding or failing at each step. For example, how do prospects + * become shoppers and then become buyers? How do one time buyers become repeat buyers? With this + * information, you can improve inefficient or abandoned customer journeys. To learn more, see + * [GA4 Funnel Explorations](https://support.google.com/analytics/answer/9327974). + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated for illustrative purposes only.
+   * // It may require modifications to work in your environment.
+   * try (AlphaAnalyticsDataClient alphaAnalyticsDataClient = AlphaAnalyticsDataClient.create()) {
+   *   RunFunnelReportRequest request =
+   *       RunFunnelReportRequest.newBuilder()
+   *           .setProperty("property-993141291")
+   *           .addAllDateRanges(new ArrayList())
+   *           .setFunnel(Funnel.newBuilder().build())
+   *           .setFunnelBreakdown(FunnelBreakdown.newBuilder().build())
+   *           .setFunnelNextAction(FunnelNextAction.newBuilder().build())
+   *           .addAllSegments(new ArrayList())
+   *           .setLimit(102976443)
+   *           .setDimensionFilter(FilterExpression.newBuilder().build())
+   *           .setReturnPropertyQuota(true)
+   *           .build();
+   *   ApiFuture future =
+   *       alphaAnalyticsDataClient.runFunnelReportCallable().futureCall(request);
+   *   // Do something.
+   *   RunFunnelReportResponse response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + runFunnelReportCallable() { + return stub.runFunnelReportCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } +} diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataSettings.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataSettings.java new file mode 100644 index 00000000..12452b95 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataSettings.java @@ -0,0 +1,187 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha; + +import com.google.analytics.data.v1alpha.stub.AlphaAnalyticsDataStubSettings; +import com.google.api.core.ApiFunction; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link AlphaAnalyticsDataClient}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (analyticsdata.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the total timeout of runFunnelReport to 30 seconds: + * + *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
+ * AlphaAnalyticsDataSettings.Builder alphaAnalyticsDataSettingsBuilder =
+ *     AlphaAnalyticsDataSettings.newBuilder();
+ * alphaAnalyticsDataSettingsBuilder
+ *     .runFunnelReportSettings()
+ *     .setRetrySettings(
+ *         alphaAnalyticsDataSettingsBuilder
+ *             .runFunnelReportSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * AlphaAnalyticsDataSettings alphaAnalyticsDataSettings =
+ *     alphaAnalyticsDataSettingsBuilder.build();
+ * }
+ */ +@BetaApi +@Generated("by gapic-generator-java") +public class AlphaAnalyticsDataSettings extends ClientSettings { + + /** Returns the object with the settings used for calls to runFunnelReport. */ + public UnaryCallSettings + runFunnelReportSettings() { + return ((AlphaAnalyticsDataStubSettings) getStubSettings()).runFunnelReportSettings(); + } + + public static final AlphaAnalyticsDataSettings create(AlphaAnalyticsDataStubSettings stub) + throws IOException { + return new AlphaAnalyticsDataSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return AlphaAnalyticsDataStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return AlphaAnalyticsDataStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return AlphaAnalyticsDataStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return AlphaAnalyticsDataStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return AlphaAnalyticsDataStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return AlphaAnalyticsDataStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return AlphaAnalyticsDataStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected AlphaAnalyticsDataSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for AlphaAnalyticsDataSettings. */ + public static class Builder extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(AlphaAnalyticsDataStubSettings.newBuilder(clientContext)); + } + + protected Builder(AlphaAnalyticsDataSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(AlphaAnalyticsDataStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(AlphaAnalyticsDataStubSettings.newBuilder()); + } + + public AlphaAnalyticsDataStubSettings.Builder getStubSettingsBuilder() { + return ((AlphaAnalyticsDataStubSettings.Builder) getStubSettings()); + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to runFunnelReport. */ + public UnaryCallSettings.Builder + runFunnelReportSettings() { + return getStubSettingsBuilder().runFunnelReportSettings(); + } + + @Override + public AlphaAnalyticsDataSettings build() throws IOException { + return new AlphaAnalyticsDataSettings(this); + } + } +} diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/gapic_metadata.json b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/gapic_metadata.json new file mode 100644 index 00000000..270aa547 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/gapic_metadata.json @@ -0,0 +1,21 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", + "language": "java", + "protoPackage": "google.analytics.data.v1alpha", + "libraryPackage": "com.google.analytics.data.v1alpha", + "services": { + "AlphaAnalyticsData": { + "clients": { + "grpc": { + "libraryClient": "AlphaAnalyticsDataClient", + "rpcs": { + "RunFunnelReport": { + "methods": ["runFunnelReport", "runFunnelReportCallable"] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/package-info.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/package-info.java new file mode 100644 index 00000000..67b78cb9 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/package-info.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 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. + */ + +/** + * A client to Google Analytics Data API + * + *

The interfaces provided are listed below, along with usage samples. + * + *

======================= AlphaAnalyticsDataClient ======================= + * + *

Service Description: Google Analytics reporting data service. + * + *

Sample for AlphaAnalyticsDataClient: + * + *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
+ * try (AlphaAnalyticsDataClient alphaAnalyticsDataClient = AlphaAnalyticsDataClient.create()) {
+ *   RunFunnelReportRequest request =
+ *       RunFunnelReportRequest.newBuilder()
+ *           .setProperty("property-993141291")
+ *           .addAllDateRanges(new ArrayList())
+ *           .setFunnel(Funnel.newBuilder().build())
+ *           .setFunnelBreakdown(FunnelBreakdown.newBuilder().build())
+ *           .setFunnelNextAction(FunnelNextAction.newBuilder().build())
+ *           .addAllSegments(new ArrayList())
+ *           .setLimit(102976443)
+ *           .setDimensionFilter(FilterExpression.newBuilder().build())
+ *           .setReturnPropertyQuota(true)
+ *           .build();
+ *   RunFunnelReportResponse response = alphaAnalyticsDataClient.runFunnelReport(request);
+ * }
+ * }
+ */ +@Generated("by gapic-generator-java") +package com.google.analytics.data.v1alpha; + +import javax.annotation.Generated; diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStub.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStub.java new file mode 100644 index 00000000..18da5c70 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStub.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha.stub; + +import com.google.analytics.data.v1alpha.RunFunnelReportRequest; +import com.google.analytics.data.v1alpha.RunFunnelReportResponse; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the AlphaAnalyticsData service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@BetaApi +@Generated("by gapic-generator-java") +public abstract class AlphaAnalyticsDataStub implements BackgroundResource { + + public UnaryCallable runFunnelReportCallable() { + throw new UnsupportedOperationException("Not implemented: runFunnelReportCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStubSettings.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStubSettings.java new file mode 100644 index 00000000..b0a94da0 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/AlphaAnalyticsDataStubSettings.java @@ -0,0 +1,282 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha.stub; + +import com.google.analytics.data.v1alpha.RunFunnelReportRequest; +import com.google.analytics.data.v1alpha.RunFunnelReportResponse; +import com.google.api.core.ApiFunction; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.GrpcTransportChannel; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link AlphaAnalyticsDataStub}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (analyticsdata.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the total timeout of runFunnelReport to 30 seconds: + * + *

{@code
+ * // This snippet has been automatically generated for illustrative purposes only.
+ * // It may require modifications to work in your environment.
+ * AlphaAnalyticsDataStubSettings.Builder alphaAnalyticsDataSettingsBuilder =
+ *     AlphaAnalyticsDataStubSettings.newBuilder();
+ * alphaAnalyticsDataSettingsBuilder
+ *     .runFunnelReportSettings()
+ *     .setRetrySettings(
+ *         alphaAnalyticsDataSettingsBuilder
+ *             .runFunnelReportSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * AlphaAnalyticsDataStubSettings alphaAnalyticsDataSettings =
+ *     alphaAnalyticsDataSettingsBuilder.build();
+ * }
+ */ +@BetaApi +@Generated("by gapic-generator-java") +public class AlphaAnalyticsDataStubSettings extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder() + .add("https://www.googleapis.com/auth/analytics") + .add("https://www.googleapis.com/auth/analytics.readonly") + .build(); + + private final UnaryCallSettings + runFunnelReportSettings; + + /** Returns the object with the settings used for calls to runFunnelReport. */ + public UnaryCallSettings + runFunnelReportSettings() { + return runFunnelReportSettings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public AlphaAnalyticsDataStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcAlphaAnalyticsDataStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "analyticsdata.googleapis.com:443"; + } + + /** Returns the default mTLS service endpoint. */ + public static String getDefaultMtlsEndpoint() { + return "analyticsdata.mtls.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder() + .setScopesToApply(DEFAULT_SERVICE_SCOPES) + .setUseJwtAccessWithScope(true); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(AlphaAnalyticsDataStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected AlphaAnalyticsDataStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + runFunnelReportSettings = settingsBuilder.runFunnelReportSettings().build(); + } + + /** Builder for AlphaAnalyticsDataStubSettings. */ + public static class Builder + extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final UnaryCallSettings.Builder + runFunnelReportSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "no_retry_1_codes", ImmutableSet.copyOf(Lists.newArrayList())); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRpcTimeout(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(60000L)) + .setTotalTimeout(Duration.ofMillis(60000L)) + .build(); + definitions.put("no_retry_1_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + runFunnelReportSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of(runFunnelReportSettings); + initDefaults(this); + } + + protected Builder(AlphaAnalyticsDataStubSettings settings) { + super(settings); + + runFunnelReportSettings = settings.runFunnelReportSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of(runFunnelReportSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .runFunnelReportSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + return builder; + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to runFunnelReport. */ + public UnaryCallSettings.Builder + runFunnelReportSettings() { + return runFunnelReportSettings; + } + + @Override + public AlphaAnalyticsDataStubSettings build() throws IOException { + return new AlphaAnalyticsDataStubSettings(this); + } + } +} diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataCallableFactory.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataCallableFactory.java new file mode 100644 index 00000000..ee9bed88 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataCallableFactory.java @@ -0,0 +1,115 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha.stub; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcCallableFactory; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.BidiStreamingCallable; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientStreamingCallable; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.StreamingCallSettings; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC callable factory implementation for the AlphaAnalyticsData service API. + * + *

This class is for advanced usage. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class GrpcAlphaAnalyticsDataCallableFactory implements GrpcStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + GrpcCallSettings grpcCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + GrpcCallSettings grpcCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createPagedCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + GrpcCallSettings grpcCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBatchingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + OperationCallable createOperationCallable( + GrpcCallSettings grpcCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + return GrpcCallableFactory.createOperationCallable( + grpcCallSettings, callSettings, clientContext, operationsStub); + } + + @Override + public + BidiStreamingCallable createBidiStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBidiStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + GrpcCallSettings grpcCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createServerStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ClientStreamingCallable createClientStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createClientStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } +} diff --git a/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataStub.java b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataStub.java new file mode 100644 index 00000000..528c5508 --- /dev/null +++ b/google-analytics-data/src/main/java/com/google/analytics/data/v1alpha/stub/GrpcAlphaAnalyticsDataStub.java @@ -0,0 +1,167 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha.stub; + +import com.google.analytics.data.v1alpha.RunFunnelReportRequest; +import com.google.analytics.data.v1alpha.RunFunnelReportResponse; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.common.collect.ImmutableMap; +import com.google.longrunning.stub.GrpcOperationsStub; +import io.grpc.MethodDescriptor; +import io.grpc.protobuf.ProtoUtils; +import java.io.IOException; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the AlphaAnalyticsData service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class GrpcAlphaAnalyticsDataStub extends AlphaAnalyticsDataStub { + private static final MethodDescriptor + runFunnelReportMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.analytics.data.v1alpha.AlphaAnalyticsData/RunFunnelReport") + .setRequestMarshaller( + ProtoUtils.marshaller(RunFunnelReportRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(RunFunnelReportResponse.getDefaultInstance())) + .build(); + + private final UnaryCallable + runFunnelReportCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcAlphaAnalyticsDataStub create(AlphaAnalyticsDataStubSettings settings) + throws IOException { + return new GrpcAlphaAnalyticsDataStub(settings, ClientContext.create(settings)); + } + + public static final GrpcAlphaAnalyticsDataStub create(ClientContext clientContext) + throws IOException { + return new GrpcAlphaAnalyticsDataStub( + AlphaAnalyticsDataStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcAlphaAnalyticsDataStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcAlphaAnalyticsDataStub( + AlphaAnalyticsDataStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcAlphaAnalyticsDataStub, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcAlphaAnalyticsDataStub( + AlphaAnalyticsDataStubSettings settings, ClientContext clientContext) throws IOException { + this(settings, clientContext, new GrpcAlphaAnalyticsDataCallableFactory()); + } + + /** + * Constructs an instance of GrpcAlphaAnalyticsDataStub, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcAlphaAnalyticsDataStub( + AlphaAnalyticsDataStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings + runFunnelReportTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(runFunnelReportMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("property", String.valueOf(request.getProperty())); + return params.build(); + }) + .build(); + + this.runFunnelReportCallable = + callableFactory.createUnaryCallable( + runFunnelReportTransportSettings, settings.runFunnelReportSettings(), clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + @Override + public UnaryCallable runFunnelReportCallable() { + return runFunnelReportCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClientTest.java b/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClientTest.java new file mode 100644 index 00000000..b198eeeb --- /dev/null +++ b/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataClientTest.java @@ -0,0 +1,151 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.testing.LocalChannelProvider; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.api.gax.grpc.testing.MockServiceHelper; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.protobuf.AbstractMessage; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.UUID; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class AlphaAnalyticsDataClientTest { + private static MockAlphaAnalyticsData mockAlphaAnalyticsData; + private static MockServiceHelper mockServiceHelper; + private LocalChannelProvider channelProvider; + private AlphaAnalyticsDataClient client; + + @BeforeClass + public static void startStaticServer() { + mockAlphaAnalyticsData = new MockAlphaAnalyticsData(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), Arrays.asList(mockAlphaAnalyticsData)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + AlphaAnalyticsDataSettings settings = + AlphaAnalyticsDataSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = AlphaAnalyticsDataClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void runFunnelReportTest() throws Exception { + RunFunnelReportResponse expectedResponse = + RunFunnelReportResponse.newBuilder() + .setFunnelTable(FunnelSubReport.newBuilder().build()) + .setFunnelVisualization(FunnelSubReport.newBuilder().build()) + .setPropertyQuota(PropertyQuota.newBuilder().build()) + .setKind("kind3292052") + .build(); + mockAlphaAnalyticsData.addResponse(expectedResponse); + + RunFunnelReportRequest request = + RunFunnelReportRequest.newBuilder() + .setProperty("property-993141291") + .addAllDateRanges(new ArrayList()) + .setFunnel(Funnel.newBuilder().build()) + .setFunnelBreakdown(FunnelBreakdown.newBuilder().build()) + .setFunnelNextAction(FunnelNextAction.newBuilder().build()) + .addAllSegments(new ArrayList()) + .setLimit(102976443) + .setDimensionFilter(FilterExpression.newBuilder().build()) + .setReturnPropertyQuota(true) + .build(); + + RunFunnelReportResponse actualResponse = client.runFunnelReport(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAlphaAnalyticsData.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RunFunnelReportRequest actualRequest = ((RunFunnelReportRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getProperty(), actualRequest.getProperty()); + Assert.assertEquals(request.getDateRangesList(), actualRequest.getDateRangesList()); + Assert.assertEquals(request.getFunnel(), actualRequest.getFunnel()); + Assert.assertEquals(request.getFunnelBreakdown(), actualRequest.getFunnelBreakdown()); + Assert.assertEquals(request.getFunnelNextAction(), actualRequest.getFunnelNextAction()); + Assert.assertEquals( + request.getFunnelVisualizationType(), actualRequest.getFunnelVisualizationType()); + Assert.assertEquals(request.getSegmentsList(), actualRequest.getSegmentsList()); + Assert.assertEquals(request.getLimit(), actualRequest.getLimit()); + Assert.assertEquals(request.getDimensionFilter(), actualRequest.getDimensionFilter()); + Assert.assertEquals(request.getReturnPropertyQuota(), actualRequest.getReturnPropertyQuota()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void runFunnelReportExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAlphaAnalyticsData.addException(exception); + + try { + RunFunnelReportRequest request = + RunFunnelReportRequest.newBuilder() + .setProperty("property-993141291") + .addAllDateRanges(new ArrayList()) + .setFunnel(Funnel.newBuilder().build()) + .setFunnelBreakdown(FunnelBreakdown.newBuilder().build()) + .setFunnelNextAction(FunnelNextAction.newBuilder().build()) + .addAllSegments(new ArrayList()) + .setLimit(102976443) + .setDimensionFilter(FilterExpression.newBuilder().build()) + .setReturnPropertyQuota(true) + .build(); + client.runFunnelReport(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsData.java b/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsData.java new file mode 100644 index 00000000..9acf21d4 --- /dev/null +++ b/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsData.java @@ -0,0 +1,59 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.AbstractMessage; +import io.grpc.ServerServiceDefinition; +import java.util.List; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockAlphaAnalyticsData implements MockGrpcService { + private final MockAlphaAnalyticsDataImpl serviceImpl; + + public MockAlphaAnalyticsData() { + serviceImpl = new MockAlphaAnalyticsDataImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(AbstractMessage response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsDataImpl.java b/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsDataImpl.java new file mode 100644 index 00000000..c5e60e4c --- /dev/null +++ b/google-analytics-data/src/test/java/com/google/analytics/data/v1alpha/MockAlphaAnalyticsDataImpl.java @@ -0,0 +1,81 @@ +/* + * Copyright 2022 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. + */ + +package com.google.analytics.data.v1alpha; + +import com.google.analytics.data.v1alpha.AlphaAnalyticsDataGrpc.AlphaAnalyticsDataImplBase; +import com.google.api.core.BetaApi; +import com.google.protobuf.AbstractMessage; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockAlphaAnalyticsDataImpl extends AlphaAnalyticsDataImplBase { + private List requests; + private Queue responses; + + public MockAlphaAnalyticsDataImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(AbstractMessage response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void runFunnelReport( + RunFunnelReportRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof RunFunnelReportResponse) { + requests.add(request); + responseObserver.onNext(((RunFunnelReportResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method RunFunnelReport, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + RunFunnelReportResponse.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/grpc-google-analytics-data-v1alpha/clirr-ignored-differences.xml b/grpc-google-analytics-data-v1alpha/clirr-ignored-differences.xml new file mode 100644 index 00000000..a2d53f48 --- /dev/null +++ b/grpc-google-analytics-data-v1alpha/clirr-ignored-differences.xml @@ -0,0 +1,45 @@ + + + + + 8001 + com/google/analytics/data/v1alpha/** + + + 7006 + com/google/analytics/data/v1alpha/** + * + * + + + 7002 + com/google/analytics/data/v1alpha/** + * + + + 7005 + com/google/analytics/data/v1alpha/** + * + * + + + 6011 + com/google/analytics/data/v1alpha/** + * + + + 6003 + com/google/analytics/data/v1alpha/** + * + + + 6001 + com/google/analytics/data/v1alpha/** + * + + + 7012 + com/google/analytics/data/v1alpha/** + * + + diff --git a/grpc-google-analytics-data-v1alpha/pom.xml b/grpc-google-analytics-data-v1alpha/pom.xml new file mode 100644 index 00000000..921a9180 --- /dev/null +++ b/grpc-google-analytics-data-v1alpha/pom.xml @@ -0,0 +1,65 @@ + + 4.0.0 + com.google.api.grpc + grpc-google-analytics-data-v1alpha + 0.11.10 + grpc-google-analytics-data-v1alpha + GRPC library for google-analytics-data + + com.google.analytics + google-analytics-data-parent + 0.11.10 + + + + io.grpc + grpc-api + + + io.grpc + grpc-stub + + + io.grpc + grpc-protobuf + + + com.google.protobuf + protobuf-java + + + com.google.api.grpc + proto-google-analytics-data-v1alpha + + + com.google.guava + guava + + + + + + java9 + + [9,) + + + + javax.annotation + javax.annotation-api + + + + + + + + + org.codehaus.mojo + flatten-maven-plugin + + + + diff --git a/grpc-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataGrpc.java b/grpc-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataGrpc.java new file mode 100644 index 00000000..d5b8dad6 --- /dev/null +++ b/grpc-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AlphaAnalyticsDataGrpc.java @@ -0,0 +1,398 @@ +/* + * Copyright 2020 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. + */ +package com.google.analytics.data.v1alpha; + +import static io.grpc.MethodDescriptor.generateFullMethodName; + +/** + * + * + *
+ * Google Analytics reporting data service.
+ * 
+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/analytics/data/v1alpha/analytics_data_api.proto") +@io.grpc.stub.annotations.GrpcGenerated +public final class AlphaAnalyticsDataGrpc { + + private AlphaAnalyticsDataGrpc() {} + + public static final String SERVICE_NAME = "google.analytics.data.v1alpha.AlphaAnalyticsData"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.analytics.data.v1alpha.RunFunnelReportRequest, + com.google.analytics.data.v1alpha.RunFunnelReportResponse> + getRunFunnelReportMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "RunFunnelReport", + requestType = com.google.analytics.data.v1alpha.RunFunnelReportRequest.class, + responseType = com.google.analytics.data.v1alpha.RunFunnelReportResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.analytics.data.v1alpha.RunFunnelReportRequest, + com.google.analytics.data.v1alpha.RunFunnelReportResponse> + getRunFunnelReportMethod() { + io.grpc.MethodDescriptor< + com.google.analytics.data.v1alpha.RunFunnelReportRequest, + com.google.analytics.data.v1alpha.RunFunnelReportResponse> + getRunFunnelReportMethod; + if ((getRunFunnelReportMethod = AlphaAnalyticsDataGrpc.getRunFunnelReportMethod) == null) { + synchronized (AlphaAnalyticsDataGrpc.class) { + if ((getRunFunnelReportMethod = AlphaAnalyticsDataGrpc.getRunFunnelReportMethod) == null) { + AlphaAnalyticsDataGrpc.getRunFunnelReportMethod = + getRunFunnelReportMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "RunFunnelReport")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.analytics.data.v1alpha.RunFunnelReportRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.analytics.data.v1alpha.RunFunnelReportResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AlphaAnalyticsDataMethodDescriptorSupplier("RunFunnelReport")) + .build(); + } + } + } + return getRunFunnelReportMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static AlphaAnalyticsDataStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AlphaAnalyticsDataStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AlphaAnalyticsDataStub(channel, callOptions); + } + }; + return AlphaAnalyticsDataStub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static AlphaAnalyticsDataBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AlphaAnalyticsDataBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AlphaAnalyticsDataBlockingStub(channel, callOptions); + } + }; + return AlphaAnalyticsDataBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static AlphaAnalyticsDataFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AlphaAnalyticsDataFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AlphaAnalyticsDataFutureStub(channel, callOptions); + } + }; + return AlphaAnalyticsDataFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Google Analytics reporting data service.
+   * 
+ */ + public abstract static class AlphaAnalyticsDataImplBase implements io.grpc.BindableService { + + /** + * + * + *
+     * Returns a customized funnel report of your Google Analytics event data. The
+     * data returned from the API is as a table with columns for the requested
+     * dimensions and metrics.
+     * Funnel exploration lets you visualize the steps your users take to complete
+     * a task and quickly see how well they are succeeding or failing at each
+     * step. For example, how do prospects become shoppers and then become buyers?
+     * How do one time buyers become repeat buyers? With this information, you can
+     * improve inefficient or abandoned customer journeys. To learn more, see [GA4
+     * Funnel Explorations](https://support.google.com/analytics/answer/9327974).
+     * 
+ */ + public void runFunnelReport( + com.google.analytics.data.v1alpha.RunFunnelReportRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getRunFunnelReportMethod(), responseObserver); + } + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getRunFunnelReportMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.analytics.data.v1alpha.RunFunnelReportRequest, + com.google.analytics.data.v1alpha.RunFunnelReportResponse>( + this, METHODID_RUN_FUNNEL_REPORT))) + .build(); + } + } + + /** + * + * + *
+   * Google Analytics reporting data service.
+   * 
+ */ + public static final class AlphaAnalyticsDataStub + extends io.grpc.stub.AbstractAsyncStub { + private AlphaAnalyticsDataStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AlphaAnalyticsDataStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AlphaAnalyticsDataStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns a customized funnel report of your Google Analytics event data. The
+     * data returned from the API is as a table with columns for the requested
+     * dimensions and metrics.
+     * Funnel exploration lets you visualize the steps your users take to complete
+     * a task and quickly see how well they are succeeding or failing at each
+     * step. For example, how do prospects become shoppers and then become buyers?
+     * How do one time buyers become repeat buyers? With this information, you can
+     * improve inefficient or abandoned customer journeys. To learn more, see [GA4
+     * Funnel Explorations](https://support.google.com/analytics/answer/9327974).
+     * 
+ */ + public void runFunnelReport( + com.google.analytics.data.v1alpha.RunFunnelReportRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getRunFunnelReportMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * + * + *
+   * Google Analytics reporting data service.
+   * 
+ */ + public static final class AlphaAnalyticsDataBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private AlphaAnalyticsDataBlockingStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AlphaAnalyticsDataBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AlphaAnalyticsDataBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns a customized funnel report of your Google Analytics event data. The
+     * data returned from the API is as a table with columns for the requested
+     * dimensions and metrics.
+     * Funnel exploration lets you visualize the steps your users take to complete
+     * a task and quickly see how well they are succeeding or failing at each
+     * step. For example, how do prospects become shoppers and then become buyers?
+     * How do one time buyers become repeat buyers? With this information, you can
+     * improve inefficient or abandoned customer journeys. To learn more, see [GA4
+     * Funnel Explorations](https://support.google.com/analytics/answer/9327974).
+     * 
+ */ + public com.google.analytics.data.v1alpha.RunFunnelReportResponse runFunnelReport( + com.google.analytics.data.v1alpha.RunFunnelReportRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getRunFunnelReportMethod(), getCallOptions(), request); + } + } + + /** + * + * + *
+   * Google Analytics reporting data service.
+   * 
+ */ + public static final class AlphaAnalyticsDataFutureStub + extends io.grpc.stub.AbstractFutureStub { + private AlphaAnalyticsDataFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AlphaAnalyticsDataFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AlphaAnalyticsDataFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns a customized funnel report of your Google Analytics event data. The
+     * data returned from the API is as a table with columns for the requested
+     * dimensions and metrics.
+     * Funnel exploration lets you visualize the steps your users take to complete
+     * a task and quickly see how well they are succeeding or failing at each
+     * step. For example, how do prospects become shoppers and then become buyers?
+     * How do one time buyers become repeat buyers? With this information, you can
+     * improve inefficient or abandoned customer journeys. To learn more, see [GA4
+     * Funnel Explorations](https://support.google.com/analytics/answer/9327974).
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.analytics.data.v1alpha.RunFunnelReportResponse> + runFunnelReport(com.google.analytics.data.v1alpha.RunFunnelReportRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getRunFunnelReportMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_RUN_FUNNEL_REPORT = 0; + + private static final class MethodHandlers + implements io.grpc.stub.ServerCalls.UnaryMethod, + io.grpc.stub.ServerCalls.ServerStreamingMethod, + io.grpc.stub.ServerCalls.ClientStreamingMethod, + io.grpc.stub.ServerCalls.BidiStreamingMethod { + private final AlphaAnalyticsDataImplBase serviceImpl; + private final int methodId; + + MethodHandlers(AlphaAnalyticsDataImplBase serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_RUN_FUNNEL_REPORT: + serviceImpl.runFunnelReport( + (com.google.analytics.data.v1alpha.RunFunnelReportRequest) request, + (io.grpc.stub.StreamObserver< + com.google.analytics.data.v1alpha.RunFunnelReportResponse>) + responseObserver); + break; + default: + throw new AssertionError(); + } + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public io.grpc.stub.StreamObserver invoke( + io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + default: + throw new AssertionError(); + } + } + } + + private abstract static class AlphaAnalyticsDataBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + AlphaAnalyticsDataBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("AlphaAnalyticsData"); + } + } + + private static final class AlphaAnalyticsDataFileDescriptorSupplier + extends AlphaAnalyticsDataBaseDescriptorSupplier { + AlphaAnalyticsDataFileDescriptorSupplier() {} + } + + private static final class AlphaAnalyticsDataMethodDescriptorSupplier + extends AlphaAnalyticsDataBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final String methodName; + + AlphaAnalyticsDataMethodDescriptorSupplier(String methodName) { + this.methodName = methodName; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { + return getServiceDescriptor().findMethodByName(methodName); + } + } + + private static volatile io.grpc.ServiceDescriptor serviceDescriptor; + + public static io.grpc.ServiceDescriptor getServiceDescriptor() { + io.grpc.ServiceDescriptor result = serviceDescriptor; + if (result == null) { + synchronized (AlphaAnalyticsDataGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new AlphaAnalyticsDataFileDescriptorSupplier()) + .addMethod(getRunFunnelReportMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/pom.xml b/pom.xml index f8b7efe5..7c72eb5e 100644 --- a/pom.xml +++ b/pom.xml @@ -63,6 +63,16 @@ google-analytics-data 0.11.10 + + com.google.api.grpc + proto-google-analytics-data-v1alpha + 0.11.10 + + + com.google.api.grpc + grpc-google-analytics-data-v1alpha + 0.11.10 + com.google.api.grpc proto-google-analytics-data-v1beta @@ -104,7 +114,9 @@ google-analytics-data grpc-google-analytics-data-v1beta + grpc-google-analytics-data-v1alpha proto-google-analytics-data-v1beta + proto-google-analytics-data-v1alpha google-analytics-data-bom diff --git a/proto-google-analytics-data-v1alpha/clirr-ignored-differences.xml b/proto-google-analytics-data-v1alpha/clirr-ignored-differences.xml new file mode 100644 index 00000000..a2d53f48 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/clirr-ignored-differences.xml @@ -0,0 +1,45 @@ + + + + + 8001 + com/google/analytics/data/v1alpha/** + + + 7006 + com/google/analytics/data/v1alpha/** + * + * + + + 7002 + com/google/analytics/data/v1alpha/** + * + + + 7005 + com/google/analytics/data/v1alpha/** + * + * + + + 6011 + com/google/analytics/data/v1alpha/** + * + + + 6003 + com/google/analytics/data/v1alpha/** + * + + + 6001 + com/google/analytics/data/v1alpha/** + * + + + 7012 + com/google/analytics/data/v1alpha/** + * + + diff --git a/proto-google-analytics-data-v1alpha/pom.xml b/proto-google-analytics-data-v1alpha/pom.xml new file mode 100644 index 00000000..99eeea6d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/pom.xml @@ -0,0 +1,34 @@ + + 4.0.0 + com.google.api.grpc + proto-google-analytics-data-v1alpha + 0.11.10 + proto-google-analytics-data-v1alpha + Proto library for google-analytics-data + + com.google.analytics + google-analytics-data-parent + 0.11.10 + + + + com.google.protobuf + protobuf-java + + + com.google.api.grpc + proto-google-common-protos + + + + + + + org.codehaus.mojo + flatten-maven-plugin + + + + diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AnalyticsDataApiProto.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AnalyticsDataApiProto.java new file mode 100644 index 00000000..3f89bffd --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/AnalyticsDataApiProto.java @@ -0,0 +1,136 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/analytics_data_api.proto + +package com.google.analytics.data.v1alpha; + +public final class AnalyticsDataApiProto { + private AnalyticsDataApiProto() {} + + 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_analytics_data_v1alpha_RunFunnelReportRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n6google/analytics/data/v1alpha/analytic" + + "s_data_api.proto\022\035google.analytics.data." + + "v1alpha\032(google/analytics/data/v1alpha/d" + + "ata.proto\032\034google/api/annotations.proto\032" + + "\027google/api/client.proto\"\313\005\n\026RunFunnelRe" + + "portRequest\022\020\n\010property\030\001 \001(\t\022=\n\013date_ra" + + "nges\030\002 \003(\0132(.google.analytics.data.v1alp" + + "ha.DateRange\0225\n\006funnel\030\003 \001(\0132%.google.an" + + "alytics.data.v1alpha.Funnel\022H\n\020funnel_br" + + "eakdown\030\004 \001(\0132..google.analytics.data.v1" + + "alpha.FunnelBreakdown\022K\n\022funnel_next_act" + + "ion\030\005 \001(\0132/.google.analytics.data.v1alph" + + "a.FunnelNextAction\022p\n\031funnel_visualizati" + + "on_type\030\006 \001(\0162M.google.analytics.data.v1" + + "alpha.RunFunnelReportRequest.FunnelVisua" + + "lizationType\0228\n\010segments\030\007 \003(\0132&.google." + + "analytics.data.v1alpha.Segment\022\r\n\005limit\030" + + "\t \001(\003\022I\n\020dimension_filter\030\n \001(\0132/.google" + + ".analytics.data.v1alpha.FilterExpression" + + "\022\035\n\025return_property_quota\030\014 \001(\010\"m\n\027Funne" + + "lVisualizationType\022)\n%FUNNEL_VISUALIZATI" + + "ON_TYPE_UNSPECIFIED\020\000\022\023\n\017STANDARD_FUNNEL" + + "\020\001\022\022\n\016TRENDED_FUNNEL\020\002\"\201\002\n\027RunFunnelRepo" + + "rtResponse\022D\n\014funnel_table\030\001 \001(\0132..googl" + + "e.analytics.data.v1alpha.FunnelSubReport" + + "\022L\n\024funnel_visualization\030\002 \001(\0132..google." + + "analytics.data.v1alpha.FunnelSubReport\022D" + + "\n\016property_quota\030\003 \001(\0132,.google.analytic" + + "s.data.v1alpha.PropertyQuota\022\014\n\004kind\030\004 \001" + + "(\t2\324\002\n\022AlphaAnalyticsData\022\275\001\n\017RunFunnelR" + + "eport\0225.google.analytics.data.v1alpha.Ru" + + "nFunnelReportRequest\0326.google.analytics." + + "data.v1alpha.RunFunnelReportResponse\";\202\323" + + "\344\223\0025\"0/v1alpha/{property=properties/*}:r" + + "unFunnelReport:\001*\032~\312A\034analyticsdata.goog" + + "leapis.com\322A\\https://www.googleapis.com/" + + "auth/analytics,https://www.googleapis.co" + + "m/auth/analytics.readonlyB\177\n!com.google." + + "analytics.data.v1alphaB\025AnalyticsDataApi" + + "ProtoP\001ZAgoogle.golang.org/genproto/goog" + + "leapis/analytics/data/v1alpha;datab\006prot" + + "o3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor(), + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + }); + internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_descriptor, + new java.lang.String[] { + "Property", + "DateRanges", + "Funnel", + "FunnelBreakdown", + "FunnelNextAction", + "FunnelVisualizationType", + "Segments", + "Limit", + "DimensionFilter", + "ReturnPropertyQuota", + }); + internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_descriptor, + new java.lang.String[] { + "FunnelTable", "FunnelVisualization", "PropertyQuota", "Kind", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.oauthScopes); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor(); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilter.java new file mode 100644 index 00000000..d8bf74b5 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilter.java @@ -0,0 +1,1013 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * To express that the result needs to be between two numbers (inclusive).
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.BetweenFilter} + */ +public final class BetweenFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.BetweenFilter) + BetweenFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use BetweenFilter.newBuilder() to construct. + private BetweenFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private BetweenFilter() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new BetweenFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private BetweenFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.NumericValue.Builder subBuilder = null; + if (fromValue_ != null) { + subBuilder = fromValue_.toBuilder(); + } + fromValue_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericValue.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(fromValue_); + fromValue_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.analytics.data.v1alpha.NumericValue.Builder subBuilder = null; + if (toValue_ != null) { + subBuilder = toValue_.toBuilder(); + } + toValue_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericValue.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(toValue_); + toValue_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_BetweenFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_BetweenFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.BetweenFilter.class, + com.google.analytics.data.v1alpha.BetweenFilter.Builder.class); + } + + public static final int FROM_VALUE_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.NumericValue fromValue_; + /** + * + * + *
+   * Begins with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + * + * @return Whether the fromValue field is set. + */ + @java.lang.Override + public boolean hasFromValue() { + return fromValue_ != null; + } + /** + * + * + *
+   * Begins with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + * + * @return The fromValue. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValue getFromValue() { + return fromValue_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : fromValue_; + } + /** + * + * + *
+   * Begins with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValueOrBuilder getFromValueOrBuilder() { + return getFromValue(); + } + + public static final int TO_VALUE_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.NumericValue toValue_; + /** + * + * + *
+   * Ends with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + * + * @return Whether the toValue field is set. + */ + @java.lang.Override + public boolean hasToValue() { + return toValue_ != null; + } + /** + * + * + *
+   * Ends with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + * + * @return The toValue. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValue getToValue() { + return toValue_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : toValue_; + } + /** + * + * + *
+   * Ends with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValueOrBuilder getToValueOrBuilder() { + return getToValue(); + } + + 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 (fromValue_ != null) { + output.writeMessage(1, getFromValue()); + } + if (toValue_ != null) { + output.writeMessage(2, getToValue()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (fromValue_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getFromValue()); + } + if (toValue_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getToValue()); + } + size += unknownFields.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.analytics.data.v1alpha.BetweenFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.BetweenFilter other = + (com.google.analytics.data.v1alpha.BetweenFilter) obj; + + if (hasFromValue() != other.hasFromValue()) return false; + if (hasFromValue()) { + if (!getFromValue().equals(other.getFromValue())) return false; + } + if (hasToValue() != other.hasToValue()) return false; + if (hasToValue()) { + if (!getToValue().equals(other.getToValue())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasFromValue()) { + hash = (37 * hash) + FROM_VALUE_FIELD_NUMBER; + hash = (53 * hash) + getFromValue().hashCode(); + } + if (hasToValue()) { + hash = (37 * hash) + TO_VALUE_FIELD_NUMBER; + hash = (53 * hash) + getToValue().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter 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.analytics.data.v1alpha.BetweenFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.BetweenFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * To express that the result needs to be between two numbers (inclusive).
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.BetweenFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.BetweenFilter) + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_BetweenFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_BetweenFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.BetweenFilter.class, + com.google.analytics.data.v1alpha.BetweenFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.BetweenFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (fromValueBuilder_ == null) { + fromValue_ = null; + } else { + fromValue_ = null; + fromValueBuilder_ = null; + } + if (toValueBuilder_ == null) { + toValue_ = null; + } else { + toValue_ = null; + toValueBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_BetweenFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter build() { + com.google.analytics.data.v1alpha.BetweenFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter buildPartial() { + com.google.analytics.data.v1alpha.BetweenFilter result = + new com.google.analytics.data.v1alpha.BetweenFilter(this); + if (fromValueBuilder_ == null) { + result.fromValue_ = fromValue_; + } else { + result.fromValue_ = fromValueBuilder_.build(); + } + if (toValueBuilder_ == null) { + result.toValue_ = toValue_; + } else { + result.toValue_ = toValueBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.BetweenFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.BetweenFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.BetweenFilter other) { + if (other == com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance()) + return this; + if (other.hasFromValue()) { + mergeFromValue(other.getFromValue()); + } + if (other.hasToValue()) { + mergeToValue(other.getToValue()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.BetweenFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.BetweenFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.analytics.data.v1alpha.NumericValue fromValue_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder> + fromValueBuilder_; + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + * + * @return Whether the fromValue field is set. + */ + public boolean hasFromValue() { + return fromValueBuilder_ != null || fromValue_ != null; + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + * + * @return The fromValue. + */ + public com.google.analytics.data.v1alpha.NumericValue getFromValue() { + if (fromValueBuilder_ == null) { + return fromValue_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : fromValue_; + } else { + return fromValueBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + public Builder setFromValue(com.google.analytics.data.v1alpha.NumericValue value) { + if (fromValueBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + fromValue_ = value; + onChanged(); + } else { + fromValueBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + public Builder setFromValue( + com.google.analytics.data.v1alpha.NumericValue.Builder builderForValue) { + if (fromValueBuilder_ == null) { + fromValue_ = builderForValue.build(); + onChanged(); + } else { + fromValueBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + public Builder mergeFromValue(com.google.analytics.data.v1alpha.NumericValue value) { + if (fromValueBuilder_ == null) { + if (fromValue_ != null) { + fromValue_ = + com.google.analytics.data.v1alpha.NumericValue.newBuilder(fromValue_) + .mergeFrom(value) + .buildPartial(); + } else { + fromValue_ = value; + } + onChanged(); + } else { + fromValueBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + public Builder clearFromValue() { + if (fromValueBuilder_ == null) { + fromValue_ = null; + onChanged(); + } else { + fromValue_ = null; + fromValueBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + public com.google.analytics.data.v1alpha.NumericValue.Builder getFromValueBuilder() { + + onChanged(); + return getFromValueFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + public com.google.analytics.data.v1alpha.NumericValueOrBuilder getFromValueOrBuilder() { + if (fromValueBuilder_ != null) { + return fromValueBuilder_.getMessageOrBuilder(); + } else { + return fromValue_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : fromValue_; + } + } + /** + * + * + *
+     * Begins with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder> + getFromValueFieldBuilder() { + if (fromValueBuilder_ == null) { + fromValueBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder>( + getFromValue(), getParentForChildren(), isClean()); + fromValue_ = null; + } + return fromValueBuilder_; + } + + private com.google.analytics.data.v1alpha.NumericValue toValue_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder> + toValueBuilder_; + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + * + * @return Whether the toValue field is set. + */ + public boolean hasToValue() { + return toValueBuilder_ != null || toValue_ != null; + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + * + * @return The toValue. + */ + public com.google.analytics.data.v1alpha.NumericValue getToValue() { + if (toValueBuilder_ == null) { + return toValue_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : toValue_; + } else { + return toValueBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + public Builder setToValue(com.google.analytics.data.v1alpha.NumericValue value) { + if (toValueBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + toValue_ = value; + onChanged(); + } else { + toValueBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + public Builder setToValue( + com.google.analytics.data.v1alpha.NumericValue.Builder builderForValue) { + if (toValueBuilder_ == null) { + toValue_ = builderForValue.build(); + onChanged(); + } else { + toValueBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + public Builder mergeToValue(com.google.analytics.data.v1alpha.NumericValue value) { + if (toValueBuilder_ == null) { + if (toValue_ != null) { + toValue_ = + com.google.analytics.data.v1alpha.NumericValue.newBuilder(toValue_) + .mergeFrom(value) + .buildPartial(); + } else { + toValue_ = value; + } + onChanged(); + } else { + toValueBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + public Builder clearToValue() { + if (toValueBuilder_ == null) { + toValue_ = null; + onChanged(); + } else { + toValue_ = null; + toValueBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + public com.google.analytics.data.v1alpha.NumericValue.Builder getToValueBuilder() { + + onChanged(); + return getToValueFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + public com.google.analytics.data.v1alpha.NumericValueOrBuilder getToValueOrBuilder() { + if (toValueBuilder_ != null) { + return toValueBuilder_.getMessageOrBuilder(); + } else { + return toValue_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : toValue_; + } + } + /** + * + * + *
+     * Ends with this number.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder> + getToValueFieldBuilder() { + if (toValueBuilder_ == null) { + toValueBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder>( + getToValue(), getParentForChildren(), isClean()); + toValue_ = null; + } + return toValueBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.BetweenFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.BetweenFilter) + private static final com.google.analytics.data.v1alpha.BetweenFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.BetweenFilter(); + } + + public static com.google.analytics.data.v1alpha.BetweenFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BetweenFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new BetweenFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.BetweenFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilterOrBuilder.java new file mode 100644 index 00000000..ec16ff09 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/BetweenFilterOrBuilder.java @@ -0,0 +1,95 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface BetweenFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.BetweenFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Begins with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + * + * @return Whether the fromValue field is set. + */ + boolean hasFromValue(); + /** + * + * + *
+   * Begins with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + * + * @return The fromValue. + */ + com.google.analytics.data.v1alpha.NumericValue getFromValue(); + /** + * + * + *
+   * Begins with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + com.google.analytics.data.v1alpha.NumericValueOrBuilder getFromValueOrBuilder(); + + /** + * + * + *
+   * Ends with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + * + * @return Whether the toValue field is set. + */ + boolean hasToValue(); + /** + * + * + *
+   * Ends with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + * + * @return The toValue. + */ + com.google.analytics.data.v1alpha.NumericValue getToValue(); + /** + * + * + *
+   * Ends with this number.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + com.google.analytics.data.v1alpha.NumericValueOrBuilder getToValueOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRange.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRange.java new file mode 100644 index 00000000..c2fda774 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRange.java @@ -0,0 +1,1059 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests
+ * are allowed up to 4 date ranges.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DateRange} + */ +public final class DateRange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.DateRange) + DateRangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use DateRange.newBuilder() to construct. + private DateRange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DateRange() { + startDate_ = ""; + endDate_ = ""; + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DateRange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DateRange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + startDate_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + endDate_ = s; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DateRange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DateRange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DateRange.class, + com.google.analytics.data.v1alpha.DateRange.Builder.class); + } + + public static final int START_DATE_FIELD_NUMBER = 1; + private volatile java.lang.Object startDate_; + /** + * + * + *
+   * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+   * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+   * accepted, and in that case, the date is inferred based on the property's
+   * reporting time zone.
+   * 
+ * + * string start_date = 1; + * + * @return The startDate. + */ + @java.lang.Override + public java.lang.String getStartDate() { + java.lang.Object ref = startDate_; + 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(); + startDate_ = s; + return s; + } + } + /** + * + * + *
+   * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+   * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+   * accepted, and in that case, the date is inferred based on the property's
+   * reporting time zone.
+   * 
+ * + * string start_date = 1; + * + * @return The bytes for startDate. + */ + @java.lang.Override + public com.google.protobuf.ByteString getStartDateBytes() { + java.lang.Object ref = startDate_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + startDate_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int END_DATE_FIELD_NUMBER = 2; + private volatile java.lang.Object endDate_; + /** + * + * + *
+   * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+   * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+   * also accepted, and in that case, the date is inferred based on the
+   * property's reporting time zone.
+   * 
+ * + * string end_date = 2; + * + * @return The endDate. + */ + @java.lang.Override + public java.lang.String getEndDate() { + java.lang.Object ref = endDate_; + 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(); + endDate_ = s; + return s; + } + } + /** + * + * + *
+   * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+   * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+   * also accepted, and in that case, the date is inferred based on the
+   * property's reporting time zone.
+   * 
+ * + * string end_date = 2; + * + * @return The bytes for endDate. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEndDateBytes() { + java.lang.Object ref = endDate_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + endDate_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int NAME_FIELD_NUMBER = 3; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Assigns a name to this date range. The dimension `dateRange` is valued to
+   * this name in a report response. If set, cannot begin with `date_range_` or
+   * `RESERVED_`. If not set, date ranges are named by their zero based index in
+   * the request: `date_range_0`, `date_range_1`, etc.
+   * 
+ * + * string name = 3; + * + * @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; + } + } + /** + * + * + *
+   * Assigns a name to this date range. The dimension `dateRange` is valued to
+   * this name in a report response. If set, cannot begin with `date_range_` or
+   * `RESERVED_`. If not set, date ranges are named by their zero based index in
+   * the request: `date_range_0`, `date_range_1`, etc.
+   * 
+ * + * string name = 3; + * + * @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.GeneratedMessageV3.isStringEmpty(startDate_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, startDate_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(endDate_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, endDate_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(startDate_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, startDate_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(endDate_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, endDate_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); + } + size += unknownFields.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.analytics.data.v1alpha.DateRange)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.DateRange other = + (com.google.analytics.data.v1alpha.DateRange) obj; + + if (!getStartDate().equals(other.getStartDate())) return false; + if (!getEndDate().equals(other.getEndDate())) return false; + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + START_DATE_FIELD_NUMBER; + hash = (53 * hash) + getStartDate().hashCode(); + hash = (37 * hash) + END_DATE_FIELD_NUMBER; + hash = (53 * hash) + getEndDate().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DateRange 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.analytics.data.v1alpha.DateRange parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DateRange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DateRange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DateRange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.DateRange 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests
+   * are allowed up to 4 date ranges.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DateRange} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.DateRange) + com.google.analytics.data.v1alpha.DateRangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DateRange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DateRange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DateRange.class, + com.google.analytics.data.v1alpha.DateRange.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.DateRange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + startDate_ = ""; + + endDate_ = ""; + + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DateRange_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DateRange getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.DateRange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DateRange build() { + com.google.analytics.data.v1alpha.DateRange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DateRange buildPartial() { + com.google.analytics.data.v1alpha.DateRange result = + new com.google.analytics.data.v1alpha.DateRange(this); + result.startDate_ = startDate_; + result.endDate_ = endDate_; + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.DateRange) { + return mergeFrom((com.google.analytics.data.v1alpha.DateRange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.DateRange other) { + if (other == com.google.analytics.data.v1alpha.DateRange.getDefaultInstance()) return this; + if (!other.getStartDate().isEmpty()) { + startDate_ = other.startDate_; + onChanged(); + } + if (!other.getEndDate().isEmpty()) { + endDate_ = other.endDate_; + onChanged(); + } + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.DateRange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.DateRange) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object startDate_ = ""; + /** + * + * + *
+     * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+     * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+     * accepted, and in that case, the date is inferred based on the property's
+     * reporting time zone.
+     * 
+ * + * string start_date = 1; + * + * @return The startDate. + */ + public java.lang.String getStartDate() { + java.lang.Object ref = startDate_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + startDate_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+     * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+     * accepted, and in that case, the date is inferred based on the property's
+     * reporting time zone.
+     * 
+ * + * string start_date = 1; + * + * @return The bytes for startDate. + */ + public com.google.protobuf.ByteString getStartDateBytes() { + java.lang.Object ref = startDate_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + startDate_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+     * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+     * accepted, and in that case, the date is inferred based on the property's
+     * reporting time zone.
+     * 
+ * + * string start_date = 1; + * + * @param value The startDate to set. + * @return This builder for chaining. + */ + public Builder setStartDate(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + startDate_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+     * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+     * accepted, and in that case, the date is inferred based on the property's
+     * reporting time zone.
+     * 
+ * + * string start_date = 1; + * + * @return This builder for chaining. + */ + public Builder clearStartDate() { + + startDate_ = getDefaultInstance().getStartDate(); + onChanged(); + return this; + } + /** + * + * + *
+     * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+     * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+     * accepted, and in that case, the date is inferred based on the property's
+     * reporting time zone.
+     * 
+ * + * string start_date = 1; + * + * @param value The bytes for startDate to set. + * @return This builder for chaining. + */ + public Builder setStartDateBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + startDate_ = value; + onChanged(); + return this; + } + + private java.lang.Object endDate_ = ""; + /** + * + * + *
+     * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+     * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+     * also accepted, and in that case, the date is inferred based on the
+     * property's reporting time zone.
+     * 
+ * + * string end_date = 2; + * + * @return The endDate. + */ + public java.lang.String getEndDate() { + java.lang.Object ref = endDate_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + endDate_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+     * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+     * also accepted, and in that case, the date is inferred based on the
+     * property's reporting time zone.
+     * 
+ * + * string end_date = 2; + * + * @return The bytes for endDate. + */ + public com.google.protobuf.ByteString getEndDateBytes() { + java.lang.Object ref = endDate_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + endDate_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+     * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+     * also accepted, and in that case, the date is inferred based on the
+     * property's reporting time zone.
+     * 
+ * + * string end_date = 2; + * + * @param value The endDate to set. + * @return This builder for chaining. + */ + public Builder setEndDate(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + endDate_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+     * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+     * also accepted, and in that case, the date is inferred based on the
+     * property's reporting time zone.
+     * 
+ * + * string end_date = 2; + * + * @return This builder for chaining. + */ + public Builder clearEndDate() { + + endDate_ = getDefaultInstance().getEndDate(); + onChanged(); + return this; + } + /** + * + * + *
+     * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+     * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+     * also accepted, and in that case, the date is inferred based on the
+     * property's reporting time zone.
+     * 
+ * + * string end_date = 2; + * + * @param value The bytes for endDate to set. + * @return This builder for chaining. + */ + public Builder setEndDateBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + endDate_ = value; + onChanged(); + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Assigns a name to this date range. The dimension `dateRange` is valued to
+     * this name in a report response. If set, cannot begin with `date_range_` or
+     * `RESERVED_`. If not set, date ranges are named by their zero based index in
+     * the request: `date_range_0`, `date_range_1`, etc.
+     * 
+ * + * string name = 3; + * + * @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; + } + } + /** + * + * + *
+     * Assigns a name to this date range. The dimension `dateRange` is valued to
+     * this name in a report response. If set, cannot begin with `date_range_` or
+     * `RESERVED_`. If not set, date ranges are named by their zero based index in
+     * the request: `date_range_0`, `date_range_1`, etc.
+     * 
+ * + * string name = 3; + * + * @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; + } + } + /** + * + * + *
+     * Assigns a name to this date range. The dimension `dateRange` is valued to
+     * this name in a report response. If set, cannot begin with `date_range_` or
+     * `RESERVED_`. If not set, date ranges are named by their zero based index in
+     * the request: `date_range_0`, `date_range_1`, etc.
+     * 
+ * + * string name = 3; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * Assigns a name to this date range. The dimension `dateRange` is valued to
+     * this name in a report response. If set, cannot begin with `date_range_` or
+     * `RESERVED_`. If not set, date ranges are named by their zero based index in
+     * the request: `date_range_0`, `date_range_1`, etc.
+     * 
+ * + * string name = 3; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Assigns a name to this date range. The dimension `dateRange` is valued to
+     * this name in a report response. If set, cannot begin with `date_range_` or
+     * `RESERVED_`. If not set, date ranges are named by their zero based index in
+     * the request: `date_range_0`, `date_range_1`, etc.
+     * 
+ * + * string name = 3; + * + * @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; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.DateRange) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.DateRange) + private static final com.google.analytics.data.v1alpha.DateRange DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.DateRange(); + } + + public static com.google.analytics.data.v1alpha.DateRange getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DateRange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DateRange(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.DateRange getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRangeOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRangeOrBuilder.java new file mode 100644 index 00000000..f111e6c0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DateRangeOrBuilder.java @@ -0,0 +1,118 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface DateRangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.DateRange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+   * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+   * accepted, and in that case, the date is inferred based on the property's
+   * reporting time zone.
+   * 
+ * + * string start_date = 1; + * + * @return The startDate. + */ + java.lang.String getStartDate(); + /** + * + * + *
+   * The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot
+   * be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also
+   * accepted, and in that case, the date is inferred based on the property's
+   * reporting time zone.
+   * 
+ * + * string start_date = 1; + * + * @return The bytes for startDate. + */ + com.google.protobuf.ByteString getStartDateBytes(); + + /** + * + * + *
+   * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+   * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+   * also accepted, and in that case, the date is inferred based on the
+   * property's reporting time zone.
+   * 
+ * + * string end_date = 2; + * + * @return The endDate. + */ + java.lang.String getEndDate(); + /** + * + * + *
+   * The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot
+   * be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is
+   * also accepted, and in that case, the date is inferred based on the
+   * property's reporting time zone.
+   * 
+ * + * string end_date = 2; + * + * @return The bytes for endDate. + */ + com.google.protobuf.ByteString getEndDateBytes(); + + /** + * + * + *
+   * Assigns a name to this date range. The dimension `dateRange` is valued to
+   * this name in a report response. If set, cannot begin with `date_range_` or
+   * `RESERVED_`. If not set, date ranges are named by their zero based index in
+   * the request: `date_range_0`, `date_range_1`, etc.
+   * 
+ * + * string name = 3; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Assigns a name to this date range. The dimension `dateRange` is valued to
+   * this name in a report response. If set, cannot begin with `date_range_` or
+   * `RESERVED_`. If not set, date ranges are named by their zero based index in
+   * the request: `date_range_0`, `date_range_1`, etc.
+   * 
+ * + * string name = 3; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Dimension.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Dimension.java new file mode 100644 index 00000000..1f4b3d48 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Dimension.java @@ -0,0 +1,999 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Dimensions are attributes of your data. For example, the dimension city
+ * indicates the city from which an event originates. Dimension values in report
+ * responses are strings; for example, the city could be "Paris" or "New York".
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Dimension} + */ +public final class Dimension extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.Dimension) + DimensionOrBuilder { + private static final long serialVersionUID = 0L; + // Use Dimension.newBuilder() to construct. + private Dimension(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Dimension() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Dimension(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Dimension( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + name_ = s; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.DimensionExpression.Builder subBuilder = null; + if (dimensionExpression_ != null) { + subBuilder = dimensionExpression_.toBuilder(); + } + dimensionExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.DimensionExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(dimensionExpression_); + dimensionExpression_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Dimension_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Dimension_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Dimension.class, + com.google.analytics.data.v1alpha.Dimension.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The name of the dimension. See the [API
+   * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+   * for the list of dimension names.
+   * If `dimensionExpression` is specified, `name` can be any string that you
+   * would like within the allowed character set. For example if a
+   * `dimensionExpression` concatenates `country` and `city`, you could call
+   * that dimension `countryAndCity`. Dimension names that you choose must match
+   * the regular expression `^[a-zA-Z0-9_]$`.
+   * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+   * `dimensionExpression`, and `pivots`.
+   * 
+ * + * 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 name of the dimension. See the [API
+   * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+   * for the list of dimension names.
+   * If `dimensionExpression` is specified, `name` can be any string that you
+   * would like within the allowed character set. For example if a
+   * `dimensionExpression` concatenates `country` and `city`, you could call
+   * that dimension `countryAndCity`. Dimension names that you choose must match
+   * the regular expression `^[a-zA-Z0-9_]$`.
+   * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+   * `dimensionExpression`, and `pivots`.
+   * 
+ * + * 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 DIMENSION_EXPRESSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.DimensionExpression dimensionExpression_; + /** + * + * + *
+   * One dimension can be the result of an expression of multiple dimensions.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * + * @return Whether the dimensionExpression field is set. + */ + @java.lang.Override + public boolean hasDimensionExpression() { + return dimensionExpression_ != null; + } + /** + * + * + *
+   * One dimension can be the result of an expression of multiple dimensions.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * + * @return The dimensionExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression getDimensionExpression() { + return dimensionExpression_ == null + ? com.google.analytics.data.v1alpha.DimensionExpression.getDefaultInstance() + : dimensionExpression_; + } + /** + * + * + *
+   * One dimension can be the result of an expression of multiple dimensions.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder + getDimensionExpressionOrBuilder() { + return getDimensionExpression(); + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (dimensionExpression_ != null) { + output.writeMessage(2, getDimensionExpression()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (dimensionExpression_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getDimensionExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.Dimension)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.Dimension other = + (com.google.analytics.data.v1alpha.Dimension) obj; + + if (!getName().equals(other.getName())) return false; + if (hasDimensionExpression() != other.hasDimensionExpression()) return false; + if (hasDimensionExpression()) { + if (!getDimensionExpression().equals(other.getDimensionExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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(); + if (hasDimensionExpression()) { + hash = (37 * hash) + DIMENSION_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getDimensionExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Dimension 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.analytics.data.v1alpha.Dimension parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Dimension parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Dimension parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Dimension parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.Dimension 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Dimensions are attributes of your data. For example, the dimension city
+   * indicates the city from which an event originates. Dimension values in report
+   * responses are strings; for example, the city could be "Paris" or "New York".
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Dimension} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.Dimension) + com.google.analytics.data.v1alpha.DimensionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Dimension_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Dimension_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Dimension.class, + com.google.analytics.data.v1alpha.Dimension.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.Dimension.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + if (dimensionExpressionBuilder_ == null) { + dimensionExpression_ = null; + } else { + dimensionExpression_ = null; + dimensionExpressionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Dimension_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Dimension getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.Dimension.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Dimension build() { + com.google.analytics.data.v1alpha.Dimension result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Dimension buildPartial() { + com.google.analytics.data.v1alpha.Dimension result = + new com.google.analytics.data.v1alpha.Dimension(this); + result.name_ = name_; + if (dimensionExpressionBuilder_ == null) { + result.dimensionExpression_ = dimensionExpression_; + } else { + result.dimensionExpression_ = dimensionExpressionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.Dimension) { + return mergeFrom((com.google.analytics.data.v1alpha.Dimension) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.Dimension other) { + if (other == com.google.analytics.data.v1alpha.Dimension.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.hasDimensionExpression()) { + mergeDimensionExpression(other.getDimensionExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.Dimension parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.Dimension) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The name of the dimension. See the [API
+     * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+     * for the list of dimension names.
+     * If `dimensionExpression` is specified, `name` can be any string that you
+     * would like within the allowed character set. For example if a
+     * `dimensionExpression` concatenates `country` and `city`, you could call
+     * that dimension `countryAndCity`. Dimension names that you choose must match
+     * the regular expression `^[a-zA-Z0-9_]$`.
+     * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+     * `dimensionExpression`, and `pivots`.
+     * 
+ * + * 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 name of the dimension. See the [API
+     * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+     * for the list of dimension names.
+     * If `dimensionExpression` is specified, `name` can be any string that you
+     * would like within the allowed character set. For example if a
+     * `dimensionExpression` concatenates `country` and `city`, you could call
+     * that dimension `countryAndCity`. Dimension names that you choose must match
+     * the regular expression `^[a-zA-Z0-9_]$`.
+     * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+     * `dimensionExpression`, and `pivots`.
+     * 
+ * + * 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 name of the dimension. See the [API
+     * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+     * for the list of dimension names.
+     * If `dimensionExpression` is specified, `name` can be any string that you
+     * would like within the allowed character set. For example if a
+     * `dimensionExpression` concatenates `country` and `city`, you could call
+     * that dimension `countryAndCity`. Dimension names that you choose must match
+     * the regular expression `^[a-zA-Z0-9_]$`.
+     * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+     * `dimensionExpression`, and `pivots`.
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the dimension. See the [API
+     * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+     * for the list of dimension names.
+     * If `dimensionExpression` is specified, `name` can be any string that you
+     * would like within the allowed character set. For example if a
+     * `dimensionExpression` concatenates `country` and `city`, you could call
+     * that dimension `countryAndCity`. Dimension names that you choose must match
+     * the regular expression `^[a-zA-Z0-9_]$`.
+     * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+     * `dimensionExpression`, and `pivots`.
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the dimension. See the [API
+     * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+     * for the list of dimension names.
+     * If `dimensionExpression` is specified, `name` can be any string that you
+     * would like within the allowed character set. For example if a
+     * `dimensionExpression` concatenates `country` and `city`, you could call
+     * that dimension `countryAndCity`. Dimension names that you choose must match
+     * the regular expression `^[a-zA-Z0-9_]$`.
+     * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+     * `dimensionExpression`, and `pivots`.
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.DimensionExpression dimensionExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression, + com.google.analytics.data.v1alpha.DimensionExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder> + dimensionExpressionBuilder_; + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * + * @return Whether the dimensionExpression field is set. + */ + public boolean hasDimensionExpression() { + return dimensionExpressionBuilder_ != null || dimensionExpression_ != null; + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * + * @return The dimensionExpression. + */ + public com.google.analytics.data.v1alpha.DimensionExpression getDimensionExpression() { + if (dimensionExpressionBuilder_ == null) { + return dimensionExpression_ == null + ? com.google.analytics.data.v1alpha.DimensionExpression.getDefaultInstance() + : dimensionExpression_; + } else { + return dimensionExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + public Builder setDimensionExpression( + com.google.analytics.data.v1alpha.DimensionExpression value) { + if (dimensionExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + dimensionExpression_ = value; + onChanged(); + } else { + dimensionExpressionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + public Builder setDimensionExpression( + com.google.analytics.data.v1alpha.DimensionExpression.Builder builderForValue) { + if (dimensionExpressionBuilder_ == null) { + dimensionExpression_ = builderForValue.build(); + onChanged(); + } else { + dimensionExpressionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + public Builder mergeDimensionExpression( + com.google.analytics.data.v1alpha.DimensionExpression value) { + if (dimensionExpressionBuilder_ == null) { + if (dimensionExpression_ != null) { + dimensionExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.newBuilder(dimensionExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + dimensionExpression_ = value; + } + onChanged(); + } else { + dimensionExpressionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + public Builder clearDimensionExpression() { + if (dimensionExpressionBuilder_ == null) { + dimensionExpression_ = null; + onChanged(); + } else { + dimensionExpression_ = null; + dimensionExpressionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + public com.google.analytics.data.v1alpha.DimensionExpression.Builder + getDimensionExpressionBuilder() { + + onChanged(); + return getDimensionExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + public com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder + getDimensionExpressionOrBuilder() { + if (dimensionExpressionBuilder_ != null) { + return dimensionExpressionBuilder_.getMessageOrBuilder(); + } else { + return dimensionExpression_ == null + ? com.google.analytics.data.v1alpha.DimensionExpression.getDefaultInstance() + : dimensionExpression_; + } + } + /** + * + * + *
+     * One dimension can be the result of an expression of multiple dimensions.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression, + com.google.analytics.data.v1alpha.DimensionExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder> + getDimensionExpressionFieldBuilder() { + if (dimensionExpressionBuilder_ == null) { + dimensionExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression, + com.google.analytics.data.v1alpha.DimensionExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder>( + getDimensionExpression(), getParentForChildren(), isClean()); + dimensionExpression_ = null; + } + return dimensionExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.Dimension) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.Dimension) + private static final com.google.analytics.data.v1alpha.Dimension DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.Dimension(); + } + + public static com.google.analytics.data.v1alpha.Dimension getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Dimension parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Dimension(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.Dimension getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpression.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpression.java new file mode 100644 index 00000000..2defd65d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpression.java @@ -0,0 +1,3355 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Used to express a dimension which is the result of a formula of multiple
+ * dimensions. Example usages:
+ * 1) lower_case(dimension)
+ * 2) concatenate(dimension1, symbol, dimension2).
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionExpression} + */ +public final class DimensionExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.DimensionExpression) + DimensionExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use DimensionExpression.newBuilder() to construct. + private DimensionExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DimensionExpression() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DimensionExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DimensionExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 34: + { + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder + subBuilder = null; + if (oneExpressionCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_) + .toBuilder(); + } + oneExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_); + oneExpression_ = subBuilder.buildPartial(); + } + oneExpressionCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder + subBuilder = null; + if (oneExpressionCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_) + .toBuilder(); + } + oneExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_); + oneExpression_ = subBuilder.buildPartial(); + } + oneExpressionCase_ = 5; + break; + } + case 50: + { + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder + subBuilder = null; + if (oneExpressionCase_ == 6) { + subBuilder = + ((com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_) + .toBuilder(); + } + oneExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_); + oneExpression_ = subBuilder.buildPartial(); + } + oneExpressionCase_ = 6; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionExpression.class, + com.google.analytics.data.v1alpha.DimensionExpression.Builder.class); + } + + public interface CaseExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Name of a dimension. The name must refer back to a name in dimensions
+     * field of the request.
+     * 
+ * + * string dimension_name = 1; + * + * @return The dimensionName. + */ + java.lang.String getDimensionName(); + /** + * + * + *
+     * Name of a dimension. The name must refer back to a name in dimensions
+     * field of the request.
+     * 
+ * + * string dimension_name = 1; + * + * @return The bytes for dimensionName. + */ + com.google.protobuf.ByteString getDimensionNameBytes(); + } + /** + * + * + *
+   * Used to convert a dimension value to a single case.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionExpression.CaseExpression} + */ + public static final class CaseExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + CaseExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use CaseExpression.newBuilder() to construct. + private CaseExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CaseExpression() { + dimensionName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CaseExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private CaseExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + dimensionName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.class, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder.class); + } + + public static final int DIMENSION_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object dimensionName_; + /** + * + * + *
+     * Name of a dimension. The name must refer back to a name in dimensions
+     * field of the request.
+     * 
+ * + * string dimension_name = 1; + * + * @return The dimensionName. + */ + @java.lang.Override + public java.lang.String getDimensionName() { + java.lang.Object ref = dimensionName_; + 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(); + dimensionName_ = s; + return s; + } + } + /** + * + * + *
+     * Name of a dimension. The name must refer back to a name in dimensions
+     * field of the request.
+     * 
+ * + * string dimension_name = 1; + * + * @return The bytes for dimensionName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDimensionNameBytes() { + java.lang.Object ref = dimensionName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dimensionName_ = 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.GeneratedMessageV3.isStringEmpty(dimensionName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, dimensionName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dimensionName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, dimensionName_); + } + size += unknownFields.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.analytics.data.v1alpha.DimensionExpression.CaseExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression other = + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) obj; + + if (!getDimensionName().equals(other.getDimensionName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + DIMENSION_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDimensionName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression 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.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.DimensionExpression.CaseExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Used to convert a dimension value to a single case.
+     * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionExpression.CaseExpression} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.class, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder.class); + } + + // Construct using + // com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + dimensionName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression build() { + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression buildPartial() { + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression result = + new com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression(this); + result.dimensionName_ = dimensionName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) { + return mergeFrom( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression other) { + if (other + == com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance()) return this; + if (!other.getDimensionName().isEmpty()) { + dimensionName_ = other.dimensionName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object dimensionName_ = ""; + /** + * + * + *
+       * Name of a dimension. The name must refer back to a name in dimensions
+       * field of the request.
+       * 
+ * + * string dimension_name = 1; + * + * @return The dimensionName. + */ + public java.lang.String getDimensionName() { + java.lang.Object ref = dimensionName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dimensionName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Name of a dimension. The name must refer back to a name in dimensions
+       * field of the request.
+       * 
+ * + * string dimension_name = 1; + * + * @return The bytes for dimensionName. + */ + public com.google.protobuf.ByteString getDimensionNameBytes() { + java.lang.Object ref = dimensionName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dimensionName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Name of a dimension. The name must refer back to a name in dimensions
+       * field of the request.
+       * 
+ * + * string dimension_name = 1; + * + * @param value The dimensionName to set. + * @return This builder for chaining. + */ + public Builder setDimensionName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + dimensionName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Name of a dimension. The name must refer back to a name in dimensions
+       * field of the request.
+       * 
+ * + * string dimension_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearDimensionName() { + + dimensionName_ = getDefaultInstance().getDimensionName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Name of a dimension. The name must refer back to a name in dimensions
+       * field of the request.
+       * 
+ * + * string dimension_name = 1; + * + * @param value The bytes for dimensionName to set. + * @return This builder for chaining. + */ + public Builder setDimensionNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + dimensionName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + private static final com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression(); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CaseExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new CaseExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.DimensionExpression.CaseExpression + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ConcatenateExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @return A list containing the dimensionNames. + */ + java.util.List getDimensionNamesList(); + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @return The count of dimensionNames. + */ + int getDimensionNamesCount(); + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index of the element to return. + * @return The dimensionNames at the given index. + */ + java.lang.String getDimensionNames(int index); + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index of the value to return. + * @return The bytes of the dimensionNames at the given index. + */ + com.google.protobuf.ByteString getDimensionNamesBytes(int index); + + /** + * + * + *
+     * The delimiter placed between dimension names.
+     * Delimiters are often single characters such as "|" or "," but can be
+     * longer strings. If a dimension value contains the delimiter, both will be
+     * present in response with no distinction. For example if dimension 1 value
+     * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+     * response will contain "US,FR,JP".
+     * 
+ * + * string delimiter = 2; + * + * @return The delimiter. + */ + java.lang.String getDelimiter(); + /** + * + * + *
+     * The delimiter placed between dimension names.
+     * Delimiters are often single characters such as "|" or "," but can be
+     * longer strings. If a dimension value contains the delimiter, both will be
+     * present in response with no distinction. For example if dimension 1 value
+     * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+     * response will contain "US,FR,JP".
+     * 
+ * + * string delimiter = 2; + * + * @return The bytes for delimiter. + */ + com.google.protobuf.ByteString getDelimiterBytes(); + } + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression} + */ + public static final class ConcatenateExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + ConcatenateExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use ConcatenateExpression.newBuilder() to construct. + private ConcatenateExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ConcatenateExpression() { + dimensionNames_ = com.google.protobuf.LazyStringArrayList.EMPTY; + delimiter_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ConcatenateExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ConcatenateExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + dimensionNames_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + dimensionNames_.add(s); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + delimiter_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + dimensionNames_ = dimensionNames_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.class, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder + .class); + } + + public static final int DIMENSION_NAMES_FIELD_NUMBER = 1; + private com.google.protobuf.LazyStringList dimensionNames_; + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @return A list containing the dimensionNames. + */ + public com.google.protobuf.ProtocolStringList getDimensionNamesList() { + return dimensionNames_; + } + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @return The count of dimensionNames. + */ + public int getDimensionNamesCount() { + return dimensionNames_.size(); + } + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index of the element to return. + * @return The dimensionNames at the given index. + */ + public java.lang.String getDimensionNames(int index) { + return dimensionNames_.get(index); + } + /** + * + * + *
+     * Names of dimensions. The names must refer back to names in the dimensions
+     * field of the request.
+     * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index of the value to return. + * @return The bytes of the dimensionNames at the given index. + */ + public com.google.protobuf.ByteString getDimensionNamesBytes(int index) { + return dimensionNames_.getByteString(index); + } + + public static final int DELIMITER_FIELD_NUMBER = 2; + private volatile java.lang.Object delimiter_; + /** + * + * + *
+     * The delimiter placed between dimension names.
+     * Delimiters are often single characters such as "|" or "," but can be
+     * longer strings. If a dimension value contains the delimiter, both will be
+     * present in response with no distinction. For example if dimension 1 value
+     * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+     * response will contain "US,FR,JP".
+     * 
+ * + * string delimiter = 2; + * + * @return The delimiter. + */ + @java.lang.Override + public java.lang.String getDelimiter() { + java.lang.Object ref = delimiter_; + 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(); + delimiter_ = s; + return s; + } + } + /** + * + * + *
+     * The delimiter placed between dimension names.
+     * Delimiters are often single characters such as "|" or "," but can be
+     * longer strings. If a dimension value contains the delimiter, both will be
+     * present in response with no distinction. For example if dimension 1 value
+     * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+     * response will contain "US,FR,JP".
+     * 
+ * + * string delimiter = 2; + * + * @return The bytes for delimiter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDelimiterBytes() { + java.lang.Object ref = delimiter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + delimiter_ = 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 { + for (int i = 0; i < dimensionNames_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, dimensionNames_.getRaw(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(delimiter_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, delimiter_); + } + unknownFields.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 < dimensionNames_.size(); i++) { + dataSize += computeStringSizeNoTag(dimensionNames_.getRaw(i)); + } + size += dataSize; + size += 1 * getDimensionNamesList().size(); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(delimiter_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, delimiter_); + } + size += unknownFields.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.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression other = + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) obj; + + if (!getDimensionNamesList().equals(other.getDimensionNamesList())) return false; + if (!getDelimiter().equals(other.getDelimiter())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getDimensionNamesCount() > 0) { + hash = (37 * hash) + DIMENSION_NAMES_FIELD_NUMBER; + hash = (53 * hash) + getDimensionNamesList().hashCode(); + } + hash = (37 * hash) + DELIMITER_FIELD_NUMBER; + hash = (53 * hash) + getDelimiter().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + 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.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.class, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder + .class); + } + + // Construct using + // com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + dimensionNames_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + delimiter_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression build() { + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + buildPartial() { + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression result = + new com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression(this); + int from_bitField0_ = bitField0_; + if (((bitField0_ & 0x00000001) != 0)) { + dimensionNames_ = dimensionNames_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.dimensionNames_ = dimensionNames_; + result.delimiter_ = delimiter_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) { + return mergeFrom( + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression other) { + if (other + == com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance()) return this; + if (!other.dimensionNames_.isEmpty()) { + if (dimensionNames_.isEmpty()) { + dimensionNames_ = other.dimensionNames_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureDimensionNamesIsMutable(); + dimensionNames_.addAll(other.dimensionNames_); + } + onChanged(); + } + if (!other.getDelimiter().isEmpty()) { + delimiter_ = other.delimiter_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression parsedMessage = + null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringList dimensionNames_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureDimensionNamesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + dimensionNames_ = new com.google.protobuf.LazyStringArrayList(dimensionNames_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @return A list containing the dimensionNames. + */ + public com.google.protobuf.ProtocolStringList getDimensionNamesList() { + return dimensionNames_.getUnmodifiableView(); + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @return The count of dimensionNames. + */ + public int getDimensionNamesCount() { + return dimensionNames_.size(); + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index of the element to return. + * @return The dimensionNames at the given index. + */ + public java.lang.String getDimensionNames(int index) { + return dimensionNames_.get(index); + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index of the value to return. + * @return The bytes of the dimensionNames at the given index. + */ + public com.google.protobuf.ByteString getDimensionNamesBytes(int index) { + return dimensionNames_.getByteString(index); + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @param index The index to set the value at. + * @param value The dimensionNames to set. + * @return This builder for chaining. + */ + public Builder setDimensionNames(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionNamesIsMutable(); + dimensionNames_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @param value The dimensionNames to add. + * @return This builder for chaining. + */ + public Builder addDimensionNames(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionNamesIsMutable(); + dimensionNames_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @param values The dimensionNames to add. + * @return This builder for chaining. + */ + public Builder addAllDimensionNames(java.lang.Iterable values) { + ensureDimensionNamesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, dimensionNames_); + onChanged(); + return this; + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @return This builder for chaining. + */ + public Builder clearDimensionNames() { + dimensionNames_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+       * Names of dimensions. The names must refer back to names in the dimensions
+       * field of the request.
+       * 
+ * + * repeated string dimension_names = 1; + * + * @param value The bytes of the dimensionNames to add. + * @return This builder for chaining. + */ + public Builder addDimensionNamesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureDimensionNamesIsMutable(); + dimensionNames_.add(value); + onChanged(); + return this; + } + + private java.lang.Object delimiter_ = ""; + /** + * + * + *
+       * The delimiter placed between dimension names.
+       * Delimiters are often single characters such as "|" or "," but can be
+       * longer strings. If a dimension value contains the delimiter, both will be
+       * present in response with no distinction. For example if dimension 1 value
+       * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+       * response will contain "US,FR,JP".
+       * 
+ * + * string delimiter = 2; + * + * @return The delimiter. + */ + public java.lang.String getDelimiter() { + java.lang.Object ref = delimiter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + delimiter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The delimiter placed between dimension names.
+       * Delimiters are often single characters such as "|" or "," but can be
+       * longer strings. If a dimension value contains the delimiter, both will be
+       * present in response with no distinction. For example if dimension 1 value
+       * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+       * response will contain "US,FR,JP".
+       * 
+ * + * string delimiter = 2; + * + * @return The bytes for delimiter. + */ + public com.google.protobuf.ByteString getDelimiterBytes() { + java.lang.Object ref = delimiter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + delimiter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The delimiter placed between dimension names.
+       * Delimiters are often single characters such as "|" or "," but can be
+       * longer strings. If a dimension value contains the delimiter, both will be
+       * present in response with no distinction. For example if dimension 1 value
+       * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+       * response will contain "US,FR,JP".
+       * 
+ * + * string delimiter = 2; + * + * @param value The delimiter to set. + * @return This builder for chaining. + */ + public Builder setDelimiter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + delimiter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The delimiter placed between dimension names.
+       * Delimiters are often single characters such as "|" or "," but can be
+       * longer strings. If a dimension value contains the delimiter, both will be
+       * present in response with no distinction. For example if dimension 1 value
+       * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+       * response will contain "US,FR,JP".
+       * 
+ * + * string delimiter = 2; + * + * @return This builder for chaining. + */ + public Builder clearDelimiter() { + + delimiter_ = getDefaultInstance().getDelimiter(); + onChanged(); + return this; + } + /** + * + * + *
+       * The delimiter placed between dimension names.
+       * Delimiters are often single characters such as "|" or "," but can be
+       * longer strings. If a dimension value contains the delimiter, both will be
+       * present in response with no distinction. For example if dimension 1 value
+       * = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the
+       * response will contain "US,FR,JP".
+       * 
+ * + * string delimiter = 2; + * + * @param value The bytes for delimiter to set. + * @return This builder for chaining. + */ + public Builder setDelimiterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + delimiter_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + private static final com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression(); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ConcatenateExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ConcatenateExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int oneExpressionCase_ = 0; + private java.lang.Object oneExpression_; + + public enum OneExpressionCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + LOWER_CASE(4), + UPPER_CASE(5), + CONCATENATE(6), + ONEEXPRESSION_NOT_SET(0); + private final int value; + + private OneExpressionCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneExpressionCase valueOf(int value) { + return forNumber(value); + } + + public static OneExpressionCase forNumber(int value) { + switch (value) { + case 4: + return LOWER_CASE; + case 5: + return UPPER_CASE; + case 6: + return CONCATENATE; + case 0: + return ONEEXPRESSION_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneExpressionCase getOneExpressionCase() { + return OneExpressionCase.forNumber(oneExpressionCase_); + } + + public static final int LOWER_CASE_FIELD_NUMBER = 4; + /** + * + * + *
+   * Used to convert a dimension value to lower case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + * @return Whether the lowerCase field is set. + */ + @java.lang.Override + public boolean hasLowerCase() { + return oneExpressionCase_ == 4; + } + /** + * + * + *
+   * Used to convert a dimension value to lower case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + * @return The lowerCase. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression getLowerCase() { + if (oneExpressionCase_ == 4) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + /** + * + * + *
+   * Used to convert a dimension value to lower case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder + getLowerCaseOrBuilder() { + if (oneExpressionCase_ == 4) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + + public static final int UPPER_CASE_FIELD_NUMBER = 5; + /** + * + * + *
+   * Used to convert a dimension value to upper case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + * @return Whether the upperCase field is set. + */ + @java.lang.Override + public boolean hasUpperCase() { + return oneExpressionCase_ == 5; + } + /** + * + * + *
+   * Used to convert a dimension value to upper case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + * @return The upperCase. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression getUpperCase() { + if (oneExpressionCase_ == 5) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + /** + * + * + *
+   * Used to convert a dimension value to upper case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder + getUpperCaseOrBuilder() { + if (oneExpressionCase_ == 5) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + + public static final int CONCATENATE_FIELD_NUMBER = 6; + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + * + * @return Whether the concatenate field is set. + */ + @java.lang.Override + public boolean hasConcatenate() { + return oneExpressionCase_ == 6; + } + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + * + * @return The concatenate. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + getConcatenate() { + if (oneExpressionCase_ == 6) { + return (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpressionOrBuilder + getConcatenateOrBuilder() { + if (oneExpressionCase_ == 6) { + return (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } + + 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 (oneExpressionCase_ == 4) { + output.writeMessage( + 4, (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) oneExpression_); + } + if (oneExpressionCase_ == 5) { + output.writeMessage( + 5, (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) oneExpression_); + } + if (oneExpressionCase_ == 6) { + output.writeMessage( + 6, + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (oneExpressionCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_); + } + if (oneExpressionCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_); + } + if (oneExpressionCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_); + } + size += unknownFields.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.analytics.data.v1alpha.DimensionExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.DimensionExpression other = + (com.google.analytics.data.v1alpha.DimensionExpression) obj; + + if (!getOneExpressionCase().equals(other.getOneExpressionCase())) return false; + switch (oneExpressionCase_) { + case 4: + if (!getLowerCase().equals(other.getLowerCase())) return false; + break; + case 5: + if (!getUpperCase().equals(other.getUpperCase())) return false; + break; + case 6: + if (!getConcatenate().equals(other.getConcatenate())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (oneExpressionCase_) { + case 4: + hash = (37 * hash) + LOWER_CASE_FIELD_NUMBER; + hash = (53 * hash) + getLowerCase().hashCode(); + break; + case 5: + hash = (37 * hash) + UPPER_CASE_FIELD_NUMBER; + hash = (53 * hash) + getUpperCase().hashCode(); + break; + case 6: + hash = (37 * hash) + CONCATENATE_FIELD_NUMBER; + hash = (53 * hash) + getConcatenate().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression 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.analytics.data.v1alpha.DimensionExpression parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.DimensionExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Used to express a dimension which is the result of a formula of multiple
+   * dimensions. Example usages:
+   * 1) lower_case(dimension)
+   * 2) concatenate(dimension1, symbol, dimension2).
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionExpression} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.DimensionExpression) + com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionExpression.class, + com.google.analytics.data.v1alpha.DimensionExpression.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.DimensionExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + oneExpressionCase_ = 0; + oneExpression_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.DimensionExpression.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression build() { + com.google.analytics.data.v1alpha.DimensionExpression result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression buildPartial() { + com.google.analytics.data.v1alpha.DimensionExpression result = + new com.google.analytics.data.v1alpha.DimensionExpression(this); + if (oneExpressionCase_ == 4) { + if (lowerCaseBuilder_ == null) { + result.oneExpression_ = oneExpression_; + } else { + result.oneExpression_ = lowerCaseBuilder_.build(); + } + } + if (oneExpressionCase_ == 5) { + if (upperCaseBuilder_ == null) { + result.oneExpression_ = oneExpression_; + } else { + result.oneExpression_ = upperCaseBuilder_.build(); + } + } + if (oneExpressionCase_ == 6) { + if (concatenateBuilder_ == null) { + result.oneExpression_ = oneExpression_; + } else { + result.oneExpression_ = concatenateBuilder_.build(); + } + } + result.oneExpressionCase_ = oneExpressionCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.DimensionExpression) { + return mergeFrom((com.google.analytics.data.v1alpha.DimensionExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.DimensionExpression other) { + if (other == com.google.analytics.data.v1alpha.DimensionExpression.getDefaultInstance()) + return this; + switch (other.getOneExpressionCase()) { + case LOWER_CASE: + { + mergeLowerCase(other.getLowerCase()); + break; + } + case UPPER_CASE: + { + mergeUpperCase(other.getUpperCase()); + break; + } + case CONCATENATE: + { + mergeConcatenate(other.getConcatenate()); + break; + } + case ONEEXPRESSION_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.DimensionExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.DimensionExpression) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneExpressionCase_ = 0; + private java.lang.Object oneExpression_; + + public OneExpressionCase getOneExpressionCase() { + return OneExpressionCase.forNumber(oneExpressionCase_); + } + + public Builder clearOneExpression() { + oneExpressionCase_ = 0; + oneExpression_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder> + lowerCaseBuilder_; + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + * + * @return Whether the lowerCase field is set. + */ + @java.lang.Override + public boolean hasLowerCase() { + return oneExpressionCase_ == 4; + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + * + * @return The lowerCase. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression getLowerCase() { + if (lowerCaseBuilder_ == null) { + if (oneExpressionCase_ == 4) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } else { + if (oneExpressionCase_ == 4) { + return lowerCaseBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + public Builder setLowerCase( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression value) { + if (lowerCaseBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneExpression_ = value; + onChanged(); + } else { + lowerCaseBuilder_.setMessage(value); + } + oneExpressionCase_ = 4; + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + public Builder setLowerCase( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder + builderForValue) { + if (lowerCaseBuilder_ == null) { + oneExpression_ = builderForValue.build(); + onChanged(); + } else { + lowerCaseBuilder_.setMessage(builderForValue.build()); + } + oneExpressionCase_ = 4; + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + public Builder mergeLowerCase( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression value) { + if (lowerCaseBuilder_ == null) { + if (oneExpressionCase_ == 4 + && oneExpression_ + != com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance()) { + oneExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.newBuilder( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + oneExpression_ = value; + } + onChanged(); + } else { + if (oneExpressionCase_ == 4) { + lowerCaseBuilder_.mergeFrom(value); + } else { + lowerCaseBuilder_.setMessage(value); + } + } + oneExpressionCase_ = 4; + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + public Builder clearLowerCase() { + if (lowerCaseBuilder_ == null) { + if (oneExpressionCase_ == 4) { + oneExpressionCase_ = 0; + oneExpression_ = null; + onChanged(); + } + } else { + if (oneExpressionCase_ == 4) { + oneExpressionCase_ = 0; + oneExpression_ = null; + } + lowerCaseBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder + getLowerCaseBuilder() { + return getLowerCaseFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder + getLowerCaseOrBuilder() { + if ((oneExpressionCase_ == 4) && (lowerCaseBuilder_ != null)) { + return lowerCaseBuilder_.getMessageOrBuilder(); + } else { + if (oneExpressionCase_ == 4) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Used to convert a dimension value to lower case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder> + getLowerCaseFieldBuilder() { + if (lowerCaseBuilder_ == null) { + if (!(oneExpressionCase_ == 4)) { + oneExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + lowerCaseBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_, + getParentForChildren(), + isClean()); + oneExpression_ = null; + } + oneExpressionCase_ = 4; + onChanged(); + ; + return lowerCaseBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder> + upperCaseBuilder_; + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + * + * @return Whether the upperCase field is set. + */ + @java.lang.Override + public boolean hasUpperCase() { + return oneExpressionCase_ == 5; + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + * + * @return The upperCase. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression getUpperCase() { + if (upperCaseBuilder_ == null) { + if (oneExpressionCase_ == 5) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } else { + if (oneExpressionCase_ == 5) { + return upperCaseBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + public Builder setUpperCase( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression value) { + if (upperCaseBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneExpression_ = value; + onChanged(); + } else { + upperCaseBuilder_.setMessage(value); + } + oneExpressionCase_ = 5; + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + public Builder setUpperCase( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder + builderForValue) { + if (upperCaseBuilder_ == null) { + oneExpression_ = builderForValue.build(); + onChanged(); + } else { + upperCaseBuilder_.setMessage(builderForValue.build()); + } + oneExpressionCase_ = 5; + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + public Builder mergeUpperCase( + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression value) { + if (upperCaseBuilder_ == null) { + if (oneExpressionCase_ == 5 + && oneExpression_ + != com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance()) { + oneExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.newBuilder( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + oneExpression_ = value; + } + onChanged(); + } else { + if (oneExpressionCase_ == 5) { + upperCaseBuilder_.mergeFrom(value); + } else { + upperCaseBuilder_.setMessage(value); + } + } + oneExpressionCase_ = 5; + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + public Builder clearUpperCase() { + if (upperCaseBuilder_ == null) { + if (oneExpressionCase_ == 5) { + oneExpressionCase_ = 0; + oneExpression_ = null; + onChanged(); + } + } else { + if (oneExpressionCase_ == 5) { + oneExpressionCase_ = 0; + oneExpression_ = null; + } + upperCaseBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder + getUpperCaseBuilder() { + return getUpperCaseFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder + getUpperCaseOrBuilder() { + if ((oneExpressionCase_ == 5) && (upperCaseBuilder_ != null)) { + return upperCaseBuilder_.getMessageOrBuilder(); + } else { + if (oneExpressionCase_ == 5) { + return (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Used to convert a dimension value to upper case.
+     * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder> + getUpperCaseFieldBuilder() { + if (upperCaseBuilder_ == null) { + if (!(oneExpressionCase_ == 5)) { + oneExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression + .getDefaultInstance(); + } + upperCaseBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression) + oneExpression_, + getParentForChildren(), + isClean()); + oneExpression_ = null; + } + oneExpressionCase_ = 5; + onChanged(); + ; + return upperCaseBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpressionOrBuilder> + concatenateBuilder_; + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + * + * @return Whether the concatenate field is set. + */ + @java.lang.Override + public boolean hasConcatenate() { + return oneExpressionCase_ == 6; + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + * + * @return The concatenate. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + getConcatenate() { + if (concatenateBuilder_ == null) { + if (oneExpressionCase_ == 6) { + return (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } else { + if (oneExpressionCase_ == 6) { + return concatenateBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + public Builder setConcatenate( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression value) { + if (concatenateBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneExpression_ = value; + onChanged(); + } else { + concatenateBuilder_.setMessage(value); + } + oneExpressionCase_ = 6; + return this; + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + public Builder setConcatenate( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder + builderForValue) { + if (concatenateBuilder_ == null) { + oneExpression_ = builderForValue.build(); + onChanged(); + } else { + concatenateBuilder_.setMessage(builderForValue.build()); + } + oneExpressionCase_ = 6; + return this; + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + public Builder mergeConcatenate( + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression value) { + if (concatenateBuilder_ == null) { + if (oneExpressionCase_ == 6 + && oneExpression_ + != com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance()) { + oneExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .newBuilder( + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + oneExpression_ = value; + } + onChanged(); + } else { + if (oneExpressionCase_ == 6) { + concatenateBuilder_.mergeFrom(value); + } else { + concatenateBuilder_.setMessage(value); + } + } + oneExpressionCase_ = 6; + return this; + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + public Builder clearConcatenate() { + if (concatenateBuilder_ == null) { + if (oneExpressionCase_ == 6) { + oneExpressionCase_ = 0; + oneExpression_ = null; + onChanged(); + } + } else { + if (oneExpressionCase_ == 6) { + oneExpressionCase_ = 0; + oneExpression_ = null; + } + concatenateBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder + getConcatenateBuilder() { + return getConcatenateFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpressionOrBuilder + getConcatenateOrBuilder() { + if ((oneExpressionCase_ == 6) && (concatenateBuilder_ != null)) { + return concatenateBuilder_.getMessageOrBuilder(); + } else { + if (oneExpressionCase_ == 6) { + return (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_; + } + return com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Used to combine dimension values to a single dimension.
+     * For example, dimension "country, city": concatenate(country, ", ", city).
+     * 
+ * + * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpressionOrBuilder> + getConcatenateFieldBuilder() { + if (concatenateBuilder_ == null) { + if (!(oneExpressionCase_ == 6)) { + oneExpression_ = + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + .getDefaultInstance(); + } + concatenateBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression, + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression.Builder, + com.google.analytics.data.v1alpha.DimensionExpression + .ConcatenateExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression) + oneExpression_, + getParentForChildren(), + isClean()); + oneExpression_ = null; + } + oneExpressionCase_ = 6; + onChanged(); + ; + return concatenateBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.DimensionExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.DimensionExpression) + private static final com.google.analytics.data.v1alpha.DimensionExpression DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.DimensionExpression(); + } + + public static com.google.analytics.data.v1alpha.DimensionExpression getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DimensionExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DimensionExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.DimensionExpression getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpressionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpressionOrBuilder.java new file mode 100644 index 00000000..78304cc0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionExpressionOrBuilder.java @@ -0,0 +1,142 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface DimensionExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.DimensionExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Used to convert a dimension value to lower case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + * @return Whether the lowerCase field is set. + */ + boolean hasLowerCase(); + /** + * + * + *
+   * Used to convert a dimension value to lower case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * + * @return The lowerCase. + */ + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression getLowerCase(); + /** + * + * + *
+   * Used to convert a dimension value to lower case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + */ + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder + getLowerCaseOrBuilder(); + + /** + * + * + *
+   * Used to convert a dimension value to upper case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + * @return Whether the upperCase field is set. + */ + boolean hasUpperCase(); + /** + * + * + *
+   * Used to convert a dimension value to upper case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * + * @return The upperCase. + */ + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpression getUpperCase(); + /** + * + * + *
+   * Used to convert a dimension value to upper case.
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + */ + com.google.analytics.data.v1alpha.DimensionExpression.CaseExpressionOrBuilder + getUpperCaseOrBuilder(); + + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + * + * @return Whether the concatenate field is set. + */ + boolean hasConcatenate(); + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + * + * @return The concatenate. + */ + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression getConcatenate(); + /** + * + * + *
+   * Used to combine dimension values to a single dimension.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * + */ + com.google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpressionOrBuilder + getConcatenateOrBuilder(); + + public com.google.analytics.data.v1alpha.DimensionExpression.OneExpressionCase + getOneExpressionCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeader.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeader.java new file mode 100644 index 00000000..418da030 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeader.java @@ -0,0 +1,644 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Describes a dimension column in the report. Dimensions requested in a report
+ * produce column entries within rows and DimensionHeaders. However, dimensions
+ * used exclusively within filters or expressions do not produce columns in a
+ * report; correspondingly, those dimensions do not produce headers.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionHeader} + */ +public final class DimensionHeader extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.DimensionHeader) + DimensionHeaderOrBuilder { + private static final long serialVersionUID = 0L; + // Use DimensionHeader.newBuilder() to construct. + private DimensionHeader(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DimensionHeader() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DimensionHeader(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DimensionHeader( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionHeader_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionHeader_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionHeader.class, + com.google.analytics.data.v1alpha.DimensionHeader.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The dimension's name.
+   * 
+ * + * 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 dimension's name.
+   * 
+ * + * 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; + } + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.analytics.data.v1alpha.DimensionHeader)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.DimensionHeader other = + (com.google.analytics.data.v1alpha.DimensionHeader) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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 = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader 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.analytics.data.v1alpha.DimensionHeader parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.DimensionHeader 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Describes a dimension column in the report. Dimensions requested in a report
+   * produce column entries within rows and DimensionHeaders. However, dimensions
+   * used exclusively within filters or expressions do not produce columns in a
+   * report; correspondingly, those dimensions do not produce headers.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionHeader} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.DimensionHeader) + com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionHeader_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionHeader_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionHeader.class, + com.google.analytics.data.v1alpha.DimensionHeader.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.DimensionHeader.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionHeader_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionHeader getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.DimensionHeader.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionHeader build() { + com.google.analytics.data.v1alpha.DimensionHeader result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionHeader buildPartial() { + com.google.analytics.data.v1alpha.DimensionHeader result = + new com.google.analytics.data.v1alpha.DimensionHeader(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.DimensionHeader) { + return mergeFrom((com.google.analytics.data.v1alpha.DimensionHeader) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.DimensionHeader other) { + if (other == com.google.analytics.data.v1alpha.DimensionHeader.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.DimensionHeader parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.DimensionHeader) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The dimension's name.
+     * 
+ * + * 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 dimension's name.
+     * 
+ * + * 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 dimension's name.
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension's name.
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension's name.
+     * 
+ * + * 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; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.DimensionHeader) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.DimensionHeader) + private static final com.google.analytics.data.v1alpha.DimensionHeader DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.DimensionHeader(); + } + + public static com.google.analytics.data.v1alpha.DimensionHeader getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DimensionHeader parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DimensionHeader(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.DimensionHeader getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeaderOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeaderOrBuilder.java new file mode 100644 index 00000000..e514389a --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionHeaderOrBuilder.java @@ -0,0 +1,50 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface DimensionHeaderOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.DimensionHeader) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The dimension's name.
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The dimension's name.
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionOrBuilder.java new file mode 100644 index 00000000..06c69152 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionOrBuilder.java @@ -0,0 +1,106 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface DimensionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.Dimension) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The name of the dimension. See the [API
+   * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+   * for the list of dimension names.
+   * If `dimensionExpression` is specified, `name` can be any string that you
+   * would like within the allowed character set. For example if a
+   * `dimensionExpression` concatenates `country` and `city`, you could call
+   * that dimension `countryAndCity`. Dimension names that you choose must match
+   * the regular expression `^[a-zA-Z0-9_]$`.
+   * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+   * `dimensionExpression`, and `pivots`.
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The name of the dimension. See the [API
+   * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions)
+   * for the list of dimension names.
+   * If `dimensionExpression` is specified, `name` can be any string that you
+   * would like within the allowed character set. For example if a
+   * `dimensionExpression` concatenates `country` and `city`, you could call
+   * that dimension `countryAndCity`. Dimension names that you choose must match
+   * the regular expression `^[a-zA-Z0-9_]$`.
+   * Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`,
+   * `dimensionExpression`, and `pivots`.
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * One dimension can be the result of an expression of multiple dimensions.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * + * @return Whether the dimensionExpression field is set. + */ + boolean hasDimensionExpression(); + /** + * + * + *
+   * One dimension can be the result of an expression of multiple dimensions.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * + * @return The dimensionExpression. + */ + com.google.analytics.data.v1alpha.DimensionExpression getDimensionExpression(); + /** + * + * + *
+   * One dimension can be the result of an expression of multiple dimensions.
+   * For example, dimension "country, city": concatenate(country, ", ", city).
+   * 
+ * + * .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + com.google.analytics.data.v1alpha.DimensionExpressionOrBuilder getDimensionExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValue.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValue.java new file mode 100644 index 00000000..b878cc79 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValue.java @@ -0,0 +1,767 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The value of a dimension.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionValue} + */ +public final class DimensionValue extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.DimensionValue) + DimensionValueOrBuilder { + private static final long serialVersionUID = 0L; + // Use DimensionValue.newBuilder() to construct. + private DimensionValue(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DimensionValue() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DimensionValue(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DimensionValue( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + oneValueCase_ = 1; + oneValue_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionValue_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionValue_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionValue.class, + com.google.analytics.data.v1alpha.DimensionValue.Builder.class); + } + + private int oneValueCase_ = 0; + private java.lang.Object oneValue_; + + public enum OneValueCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + VALUE(1), + ONEVALUE_NOT_SET(0); + private final int value; + + private OneValueCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneValueCase valueOf(int value) { + return forNumber(value); + } + + public static OneValueCase forNumber(int value) { + switch (value) { + case 1: + return VALUE; + case 0: + return ONEVALUE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneValueCase getOneValueCase() { + return OneValueCase.forNumber(oneValueCase_); + } + + public static final int VALUE_FIELD_NUMBER = 1; + /** + * + * + *
+   * Value as a string if the dimension type is a string.
+   * 
+ * + * string value = 1; + * + * @return Whether the value field is set. + */ + public boolean hasValue() { + return oneValueCase_ == 1; + } + /** + * + * + *
+   * Value as a string if the dimension type is a string.
+   * 
+ * + * string value = 1; + * + * @return The value. + */ + public java.lang.String getValue() { + java.lang.Object ref = ""; + if (oneValueCase_ == 1) { + ref = oneValue_; + } + 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(); + if (oneValueCase_ == 1) { + oneValue_ = s; + } + return s; + } + } + /** + * + * + *
+   * Value as a string if the dimension type is a string.
+   * 
+ * + * string value = 1; + * + * @return The bytes for value. + */ + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = ""; + if (oneValueCase_ == 1) { + ref = oneValue_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneValueCase_ == 1) { + oneValue_ = 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 (oneValueCase_ == 1) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, oneValue_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (oneValueCase_ == 1) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, oneValue_); + } + size += unknownFields.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.analytics.data.v1alpha.DimensionValue)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.DimensionValue other = + (com.google.analytics.data.v1alpha.DimensionValue) obj; + + if (!getOneValueCase().equals(other.getOneValueCase())) return false; + switch (oneValueCase_) { + case 1: + if (!getValue().equals(other.getValue())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (oneValueCase_) { + case 1: + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionValue 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.analytics.data.v1alpha.DimensionValue parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.DimensionValue parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.DimensionValue 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The value of a dimension.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.DimensionValue} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.DimensionValue) + com.google.analytics.data.v1alpha.DimensionValueOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionValue_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionValue_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.DimensionValue.class, + com.google.analytics.data.v1alpha.DimensionValue.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.DimensionValue.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + oneValueCase_ = 0; + oneValue_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_DimensionValue_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionValue getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.DimensionValue.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionValue build() { + com.google.analytics.data.v1alpha.DimensionValue result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionValue buildPartial() { + com.google.analytics.data.v1alpha.DimensionValue result = + new com.google.analytics.data.v1alpha.DimensionValue(this); + if (oneValueCase_ == 1) { + result.oneValue_ = oneValue_; + } + result.oneValueCase_ = oneValueCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.DimensionValue) { + return mergeFrom((com.google.analytics.data.v1alpha.DimensionValue) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.DimensionValue other) { + if (other == com.google.analytics.data.v1alpha.DimensionValue.getDefaultInstance()) + return this; + switch (other.getOneValueCase()) { + case VALUE: + { + oneValueCase_ = 1; + oneValue_ = other.oneValue_; + onChanged(); + break; + } + case ONEVALUE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.DimensionValue parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.DimensionValue) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneValueCase_ = 0; + private java.lang.Object oneValue_; + + public OneValueCase getOneValueCase() { + return OneValueCase.forNumber(oneValueCase_); + } + + public Builder clearOneValue() { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + return this; + } + + /** + * + * + *
+     * Value as a string if the dimension type is a string.
+     * 
+ * + * string value = 1; + * + * @return Whether the value field is set. + */ + @java.lang.Override + public boolean hasValue() { + return oneValueCase_ == 1; + } + /** + * + * + *
+     * Value as a string if the dimension type is a string.
+     * 
+ * + * string value = 1; + * + * @return The value. + */ + @java.lang.Override + public java.lang.String getValue() { + java.lang.Object ref = ""; + if (oneValueCase_ == 1) { + ref = oneValue_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (oneValueCase_ == 1) { + oneValue_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Value as a string if the dimension type is a string.
+     * 
+ * + * string value = 1; + * + * @return The bytes for value. + */ + @java.lang.Override + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = ""; + if (oneValueCase_ == 1) { + ref = oneValue_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneValueCase_ == 1) { + oneValue_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Value as a string if the dimension type is a string.
+     * 
+ * + * string value = 1; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + oneValueCase_ = 1; + oneValue_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Value as a string if the dimension type is a string.
+     * 
+ * + * string value = 1; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + if (oneValueCase_ == 1) { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * Value as a string if the dimension type is a string.
+     * 
+ * + * string value = 1; + * + * @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); + oneValueCase_ = 1; + oneValue_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.DimensionValue) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.DimensionValue) + private static final com.google.analytics.data.v1alpha.DimensionValue DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.DimensionValue(); + } + + public static com.google.analytics.data.v1alpha.DimensionValue getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DimensionValue parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DimensionValue(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.DimensionValue getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValueOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValueOrBuilder.java new file mode 100644 index 00000000..2813f66c --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/DimensionValueOrBuilder.java @@ -0,0 +1,64 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface DimensionValueOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.DimensionValue) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Value as a string if the dimension type is a string.
+   * 
+ * + * string value = 1; + * + * @return Whether the value field is set. + */ + boolean hasValue(); + /** + * + * + *
+   * Value as a string if the dimension type is a string.
+   * 
+ * + * string value = 1; + * + * @return The value. + */ + java.lang.String getValue(); + /** + * + * + *
+   * Value as a string if the dimension type is a string.
+   * 
+ * + * string value = 1; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); + + public com.google.analytics.data.v1alpha.DimensionValue.OneValueCase getOneValueCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventCriteriaScoping.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventCriteriaScoping.java new file mode 100644 index 00000000..555eb191 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventCriteriaScoping.java @@ -0,0 +1,162 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Scoping specifies which events are considered when evaluating if an event
+ * meets a criteria.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.EventCriteriaScoping} + */ +public enum EventCriteriaScoping implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified criteria scoping. Do not specify.
+   * 
+ * + * EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + EVENT_CRITERIA_SCOPING_UNSPECIFIED(0), + /** + * + * + *
+   * If the criteria is satisfied within one event, the event matches the
+   * criteria.
+   * 
+ * + * EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + EVENT_CRITERIA_WITHIN_SAME_EVENT(1), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified criteria scoping. Do not specify.
+   * 
+ * + * EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + public static final int EVENT_CRITERIA_SCOPING_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * If the criteria is satisfied within one event, the event matches the
+   * criteria.
+   * 
+ * + * EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + public static final int EVENT_CRITERIA_WITHIN_SAME_EVENT_VALUE = 1; + + 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 EventCriteriaScoping 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 EventCriteriaScoping forNumber(int value) { + switch (value) { + case 0: + return EVENT_CRITERIA_SCOPING_UNSPECIFIED; + case 1: + return EVENT_CRITERIA_WITHIN_SAME_EVENT; + 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 EventCriteriaScoping findValueByNumber(int number) { + return EventCriteriaScoping.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(4); + } + + private static final EventCriteriaScoping[] VALUES = values(); + + public static EventCriteriaScoping 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 EventCriteriaScoping(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.EventCriteriaScoping) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventExclusionDuration.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventExclusionDuration.java new file mode 100644 index 00000000..c9a8ba35 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventExclusionDuration.java @@ -0,0 +1,162 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Enumerates options for how long an exclusion will last if an event
+ * matches the `eventExclusionCriteria`.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.EventExclusionDuration} + */ +public enum EventExclusionDuration implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified exclusion duration. Do not specify.
+   * 
+ * + * EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + EVENT_EXCLUSION_DURATION_UNSPECIFIED(0), + /** + * + * + *
+   * Permanently exclude events from the segment if the event ever meets
+   * the `eventExclusionCriteria` condition.
+   * 
+ * + * EVENT_EXCLUSION_PERMANENT = 1; + */ + EVENT_EXCLUSION_PERMANENT(1), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified exclusion duration. Do not specify.
+   * 
+ * + * EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + public static final int EVENT_EXCLUSION_DURATION_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * Permanently exclude events from the segment if the event ever meets
+   * the `eventExclusionCriteria` condition.
+   * 
+ * + * EVENT_EXCLUSION_PERMANENT = 1; + */ + public static final int EVENT_EXCLUSION_PERMANENT_VALUE = 1; + + 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 EventExclusionDuration 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 EventExclusionDuration forNumber(int value) { + switch (value) { + case 0: + return EVENT_EXCLUSION_DURATION_UNSPECIFIED; + case 1: + return EVENT_EXCLUSION_PERMANENT; + 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 EventExclusionDuration findValueByNumber(int number) { + return EventExclusionDuration.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(5); + } + + private static final EventExclusionDuration[] VALUES = values(); + + public static EventExclusionDuration 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 EventExclusionDuration(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.EventExclusionDuration) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegment.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegment.java new file mode 100644 index 00000000..e0291152 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegment.java @@ -0,0 +1,1035 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Event segments are subsets of events that were triggered on your site or app.
+ * for example, all purchase events made in a particular location; app_exception
+ * events that occurred on a specific operating system.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegment} + */ +public final class EventSegment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.EventSegment) + EventSegmentOrBuilder { + private static final long serialVersionUID = 0L; + // Use EventSegment.newBuilder() to construct. + private EventSegment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EventSegment() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EventSegment(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EventSegment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder subBuilder = null; + if (eventInclusionCriteria_ != null) { + subBuilder = eventInclusionCriteria_.toBuilder(); + } + eventInclusionCriteria_ = + input.readMessage( + com.google.analytics.data.v1alpha.EventSegmentCriteria.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(eventInclusionCriteria_); + eventInclusionCriteria_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder subBuilder = null; + if (exclusion_ != null) { + subBuilder = exclusion_.toBuilder(); + } + exclusion_ = + input.readMessage( + com.google.analytics.data.v1alpha.EventSegmentExclusion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(exclusion_); + exclusion_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegment.class, + com.google.analytics.data.v1alpha.EventSegment.Builder.class); + } + + public static final int EVENT_INCLUSION_CRITERIA_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.EventSegmentCriteria eventInclusionCriteria_; + /** + * + * + *
+   * Defines which events are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + * @return Whether the eventInclusionCriteria field is set. + */ + @java.lang.Override + public boolean hasEventInclusionCriteria() { + return eventInclusionCriteria_ != null; + } + /** + * + * + *
+   * Defines which events are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + * @return The eventInclusionCriteria. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteria getEventInclusionCriteria() { + return eventInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance() + : eventInclusionCriteria_; + } + /** + * + * + *
+   * Defines which events are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder + getEventInclusionCriteriaOrBuilder() { + return getEventInclusionCriteria(); + } + + public static final int EXCLUSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.EventSegmentExclusion exclusion_; + /** + * + * + *
+   * Defines which events are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + @java.lang.Override + public boolean hasExclusion() { + return exclusion_ != null; + } + /** + * + * + *
+   * Defines which events are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentExclusion getExclusion() { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.EventSegmentExclusion.getDefaultInstance() + : exclusion_; + } + /** + * + * + *
+   * Defines which events are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder getExclusionOrBuilder() { + return getExclusion(); + } + + 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 (eventInclusionCriteria_ != null) { + output.writeMessage(1, getEventInclusionCriteria()); + } + if (exclusion_ != null) { + output.writeMessage(2, getExclusion()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (eventInclusionCriteria_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, getEventInclusionCriteria()); + } + if (exclusion_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getExclusion()); + } + size += unknownFields.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.analytics.data.v1alpha.EventSegment)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.EventSegment other = + (com.google.analytics.data.v1alpha.EventSegment) obj; + + if (hasEventInclusionCriteria() != other.hasEventInclusionCriteria()) return false; + if (hasEventInclusionCriteria()) { + if (!getEventInclusionCriteria().equals(other.getEventInclusionCriteria())) return false; + } + if (hasExclusion() != other.hasExclusion()) return false; + if (hasExclusion()) { + if (!getExclusion().equals(other.getExclusion())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasEventInclusionCriteria()) { + hash = (37 * hash) + EVENT_INCLUSION_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getEventInclusionCriteria().hashCode(); + } + if (hasExclusion()) { + hash = (37 * hash) + EXCLUSION_FIELD_NUMBER; + hash = (53 * hash) + getExclusion().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegment 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.analytics.data.v1alpha.EventSegment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegment parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.EventSegment 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or app.
+   * for example, all purchase events made in a particular location; app_exception
+   * events that occurred on a specific operating system.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.EventSegment) + com.google.analytics.data.v1alpha.EventSegmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegment.class, + com.google.analytics.data.v1alpha.EventSegment.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.EventSegment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (eventInclusionCriteriaBuilder_ == null) { + eventInclusionCriteria_ = null; + } else { + eventInclusionCriteria_ = null; + eventInclusionCriteriaBuilder_ = null; + } + if (exclusionBuilder_ == null) { + exclusion_ = null; + } else { + exclusion_ = null; + exclusionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegment_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegment getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegment build() { + com.google.analytics.data.v1alpha.EventSegment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegment buildPartial() { + com.google.analytics.data.v1alpha.EventSegment result = + new com.google.analytics.data.v1alpha.EventSegment(this); + if (eventInclusionCriteriaBuilder_ == null) { + result.eventInclusionCriteria_ = eventInclusionCriteria_; + } else { + result.eventInclusionCriteria_ = eventInclusionCriteriaBuilder_.build(); + } + if (exclusionBuilder_ == null) { + result.exclusion_ = exclusion_; + } else { + result.exclusion_ = exclusionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.EventSegment) { + return mergeFrom((com.google.analytics.data.v1alpha.EventSegment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.EventSegment other) { + if (other == com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance()) return this; + if (other.hasEventInclusionCriteria()) { + mergeEventInclusionCriteria(other.getEventInclusionCriteria()); + } + if (other.hasExclusion()) { + mergeExclusion(other.getExclusion()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.EventSegment parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.EventSegment) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.analytics.data.v1alpha.EventSegmentCriteria eventInclusionCriteria_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentCriteria, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder> + eventInclusionCriteriaBuilder_; + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + * + * @return Whether the eventInclusionCriteria field is set. + */ + public boolean hasEventInclusionCriteria() { + return eventInclusionCriteriaBuilder_ != null || eventInclusionCriteria_ != null; + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + * + * @return The eventInclusionCriteria. + */ + public com.google.analytics.data.v1alpha.EventSegmentCriteria getEventInclusionCriteria() { + if (eventInclusionCriteriaBuilder_ == null) { + return eventInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance() + : eventInclusionCriteria_; + } else { + return eventInclusionCriteriaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + public Builder setEventInclusionCriteria( + com.google.analytics.data.v1alpha.EventSegmentCriteria value) { + if (eventInclusionCriteriaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + eventInclusionCriteria_ = value; + onChanged(); + } else { + eventInclusionCriteriaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + public Builder setEventInclusionCriteria( + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder builderForValue) { + if (eventInclusionCriteriaBuilder_ == null) { + eventInclusionCriteria_ = builderForValue.build(); + onChanged(); + } else { + eventInclusionCriteriaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + public Builder mergeEventInclusionCriteria( + com.google.analytics.data.v1alpha.EventSegmentCriteria value) { + if (eventInclusionCriteriaBuilder_ == null) { + if (eventInclusionCriteria_ != null) { + eventInclusionCriteria_ = + com.google.analytics.data.v1alpha.EventSegmentCriteria.newBuilder( + eventInclusionCriteria_) + .mergeFrom(value) + .buildPartial(); + } else { + eventInclusionCriteria_ = value; + } + onChanged(); + } else { + eventInclusionCriteriaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + public Builder clearEventInclusionCriteria() { + if (eventInclusionCriteriaBuilder_ == null) { + eventInclusionCriteria_ = null; + onChanged(); + } else { + eventInclusionCriteria_ = null; + eventInclusionCriteriaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder + getEventInclusionCriteriaBuilder() { + + onChanged(); + return getEventInclusionCriteriaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder + getEventInclusionCriteriaOrBuilder() { + if (eventInclusionCriteriaBuilder_ != null) { + return eventInclusionCriteriaBuilder_.getMessageOrBuilder(); + } else { + return eventInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance() + : eventInclusionCriteria_; + } + } + /** + * + * + *
+     * Defines which events are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentCriteria, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder> + getEventInclusionCriteriaFieldBuilder() { + if (eventInclusionCriteriaBuilder_ == null) { + eventInclusionCriteriaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentCriteria, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder>( + getEventInclusionCriteria(), getParentForChildren(), isClean()); + eventInclusionCriteria_ = null; + } + return eventInclusionCriteriaBuilder_; + } + + private com.google.analytics.data.v1alpha.EventSegmentExclusion exclusion_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentExclusion, + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder> + exclusionBuilder_; + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + public boolean hasExclusion() { + return exclusionBuilder_ != null || exclusion_ != null; + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + public com.google.analytics.data.v1alpha.EventSegmentExclusion getExclusion() { + if (exclusionBuilder_ == null) { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.EventSegmentExclusion.getDefaultInstance() + : exclusion_; + } else { + return exclusionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + public Builder setExclusion(com.google.analytics.data.v1alpha.EventSegmentExclusion value) { + if (exclusionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + exclusion_ = value; + onChanged(); + } else { + exclusionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + public Builder setExclusion( + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder builderForValue) { + if (exclusionBuilder_ == null) { + exclusion_ = builderForValue.build(); + onChanged(); + } else { + exclusionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + public Builder mergeExclusion(com.google.analytics.data.v1alpha.EventSegmentExclusion value) { + if (exclusionBuilder_ == null) { + if (exclusion_ != null) { + exclusion_ = + com.google.analytics.data.v1alpha.EventSegmentExclusion.newBuilder(exclusion_) + .mergeFrom(value) + .buildPartial(); + } else { + exclusion_ = value; + } + onChanged(); + } else { + exclusionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + public Builder clearExclusion() { + if (exclusionBuilder_ == null) { + exclusion_ = null; + onChanged(); + } else { + exclusion_ = null; + exclusionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + public com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder getExclusionBuilder() { + + onChanged(); + return getExclusionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + public com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder + getExclusionOrBuilder() { + if (exclusionBuilder_ != null) { + return exclusionBuilder_.getMessageOrBuilder(); + } else { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.EventSegmentExclusion.getDefaultInstance() + : exclusion_; + } + } + /** + * + * + *
+     * Defines which events are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentExclusion, + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder> + getExclusionFieldBuilder() { + if (exclusionBuilder_ == null) { + exclusionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentExclusion, + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder>( + getExclusion(), getParentForChildren(), isClean()); + exclusion_ = null; + } + return exclusionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.EventSegment) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.EventSegment) + private static final com.google.analytics.data.v1alpha.EventSegment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.EventSegment(); + } + + public static com.google.analytics.data.v1alpha.EventSegment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventSegment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EventSegment(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.EventSegment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroup.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroup.java new file mode 100644 index 00000000..a504fc57 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroup.java @@ -0,0 +1,960 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Conditions tell Analytics what data to include in or exclude from the
+ * segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegmentConditionGroup} + */ +public final class EventSegmentConditionGroup extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.EventSegmentConditionGroup) + EventSegmentConditionGroupOrBuilder { + private static final long serialVersionUID = 0L; + // Use EventSegmentConditionGroup.newBuilder() to construct. + private EventSegmentConditionGroup(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EventSegmentConditionGroup() { + conditionScoping_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EventSegmentConditionGroup(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EventSegmentConditionGroup( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + conditionScoping_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder subBuilder = null; + if (segmentFilterExpression_ != null) { + subBuilder = segmentFilterExpression_.toBuilder(); + } + segmentFilterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(segmentFilterExpression_); + segmentFilterExpression_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.class, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder.class); + } + + public static final int CONDITION_SCOPING_FIELD_NUMBER = 1; + private int conditionScoping_; + /** + * + * + *
+   * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+   * Optional. If unspecified, a `conditionScoping` of
+   * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + @java.lang.Override + public int getConditionScopingValue() { + return conditionScoping_; + } + /** + * + * + *
+   * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+   * Optional. If unspecified, a `conditionScoping` of
+   * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventCriteriaScoping getConditionScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.EventCriteriaScoping result = + com.google.analytics.data.v1alpha.EventCriteriaScoping.valueOf(conditionScoping_); + return result == null + ? com.google.analytics.data.v1alpha.EventCriteriaScoping.UNRECOGNIZED + : result; + } + + public static final int SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + @java.lang.Override + public boolean hasSegmentFilterExpression() { + return segmentFilterExpression_ != null; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + return getSegmentFilterExpression(); + } + + 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 (conditionScoping_ + != com.google.analytics.data.v1alpha.EventCriteriaScoping.EVENT_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, conditionScoping_); + } + if (segmentFilterExpression_ != null) { + output.writeMessage(2, getSegmentFilterExpression()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (conditionScoping_ + != com.google.analytics.data.v1alpha.EventCriteriaScoping.EVENT_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, conditionScoping_); + } + if (segmentFilterExpression_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSegmentFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.EventSegmentConditionGroup)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.EventSegmentConditionGroup other = + (com.google.analytics.data.v1alpha.EventSegmentConditionGroup) obj; + + if (conditionScoping_ != other.conditionScoping_) return false; + if (hasSegmentFilterExpression() != other.hasSegmentFilterExpression()) return false; + if (hasSegmentFilterExpression()) { + if (!getSegmentFilterExpression().equals(other.getSegmentFilterExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + CONDITION_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + conditionScoping_; + if (hasSegmentFilterExpression()) { + hash = (37 * hash) + SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getSegmentFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup 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.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.EventSegmentConditionGroup 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Conditions tell Analytics what data to include in or exclude from the
+   * segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegmentConditionGroup} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.EventSegmentConditionGroup) + com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.class, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.EventSegmentConditionGroup.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + conditionScoping_ = 0; + + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.EventSegmentConditionGroup.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup build() { + com.google.analytics.data.v1alpha.EventSegmentConditionGroup result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup buildPartial() { + com.google.analytics.data.v1alpha.EventSegmentConditionGroup result = + new com.google.analytics.data.v1alpha.EventSegmentConditionGroup(this); + result.conditionScoping_ = conditionScoping_; + if (segmentFilterExpressionBuilder_ == null) { + result.segmentFilterExpression_ = segmentFilterExpression_; + } else { + result.segmentFilterExpression_ = segmentFilterExpressionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.EventSegmentConditionGroup) { + return mergeFrom((com.google.analytics.data.v1alpha.EventSegmentConditionGroup) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.EventSegmentConditionGroup other) { + if (other + == com.google.analytics.data.v1alpha.EventSegmentConditionGroup.getDefaultInstance()) + return this; + if (other.conditionScoping_ != 0) { + setConditionScopingValue(other.getConditionScopingValue()); + } + if (other.hasSegmentFilterExpression()) { + mergeSegmentFilterExpression(other.getSegmentFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.EventSegmentConditionGroup parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.EventSegmentConditionGroup) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int conditionScoping_ = 0; + /** + * + * + *
+     * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+     * Optional. If unspecified, a `conditionScoping` of
+     * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + @java.lang.Override + public int getConditionScopingValue() { + return conditionScoping_; + } + /** + * + * + *
+     * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+     * Optional. If unspecified, a `conditionScoping` of
+     * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @param value The enum numeric value on the wire for conditionScoping to set. + * @return This builder for chaining. + */ + public Builder setConditionScopingValue(int value) { + + conditionScoping_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+     * Optional. If unspecified, a `conditionScoping` of
+     * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventCriteriaScoping getConditionScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.EventCriteriaScoping result = + com.google.analytics.data.v1alpha.EventCriteriaScoping.valueOf(conditionScoping_); + return result == null + ? com.google.analytics.data.v1alpha.EventCriteriaScoping.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+     * Optional. If unspecified, a `conditionScoping` of
+     * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @param value The conditionScoping to set. + * @return This builder for chaining. + */ + public Builder setConditionScoping( + com.google.analytics.data.v1alpha.EventCriteriaScoping value) { + if (value == null) { + throw new NullPointerException(); + } + + conditionScoping_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+     * Optional. If unspecified, a `conditionScoping` of
+     * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return This builder for chaining. + */ + public Builder clearConditionScoping() { + + conditionScoping_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + segmentFilterExpressionBuilder_; + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + public boolean hasSegmentFilterExpression() { + return segmentFilterExpressionBuilder_ != null || segmentFilterExpression_ != null; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } else { + return segmentFilterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + segmentFilterExpression_ = value; + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = builderForValue.build(); + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder mergeSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (segmentFilterExpression_ != null) { + segmentFilterExpression_ = + com.google.analytics.data.v1alpha.SegmentFilterExpression.newBuilder( + segmentFilterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + segmentFilterExpression_ = value; + } + onChanged(); + } else { + segmentFilterExpressionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder clearSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + onChanged(); + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder + getSegmentFilterExpressionBuilder() { + + onChanged(); + return getSegmentFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + if (segmentFilterExpressionBuilder_ != null) { + return segmentFilterExpressionBuilder_.getMessageOrBuilder(); + } else { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getSegmentFilterExpressionFieldBuilder() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder>( + getSegmentFilterExpression(), getParentForChildren(), isClean()); + segmentFilterExpression_ = null; + } + return segmentFilterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.EventSegmentConditionGroup) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.EventSegmentConditionGroup) + private static final com.google.analytics.data.v1alpha.EventSegmentConditionGroup + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.EventSegmentConditionGroup(); + } + + public static com.google.analytics.data.v1alpha.EventSegmentConditionGroup getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventSegmentConditionGroup parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EventSegmentConditionGroup(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.EventSegmentConditionGroup getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroupOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroupOrBuilder.java new file mode 100644 index 00000000..33e74cfd --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentConditionGroupOrBuilder.java @@ -0,0 +1,99 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface EventSegmentConditionGroupOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.EventSegmentConditionGroup) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+   * Optional. If unspecified, a `conditionScoping` of
+   * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + int getConditionScopingValue(); + /** + * + * + *
+   * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`.
+   * Optional. If unspecified, a `conditionScoping` of
+   * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + com.google.analytics.data.v1alpha.EventCriteriaScoping getConditionScoping(); + + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + boolean hasSegmentFilterExpression(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteria.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteria.java new file mode 100644 index 00000000..960c6a2a --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteria.java @@ -0,0 +1,1054 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * An event matches a criteria if the event meet the conditions in the
+ * criteria.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegmentCriteria} + */ +public final class EventSegmentCriteria extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.EventSegmentCriteria) + EventSegmentCriteriaOrBuilder { + private static final long serialVersionUID = 0L; + // Use EventSegmentCriteria.newBuilder() to construct. + private EventSegmentCriteria(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EventSegmentCriteria() { + andConditionGroups_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EventSegmentCriteria(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EventSegmentCriteria( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.EventSegmentConditionGroup>(); + mutable_bitField0_ |= 0x00000001; + } + andConditionGroups_.add( + input.readMessage( + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = java.util.Collections.unmodifiableList(andConditionGroups_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegmentCriteria.class, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder.class); + } + + public static final int AND_CONDITION_GROUPS_FIELD_NUMBER = 1; + private java.util.List + andConditionGroups_; + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public java.util.List + getAndConditionGroupsList() { + return andConditionGroups_; + } + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder> + getAndConditionGroupsOrBuilderList() { + return andConditionGroups_; + } + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public int getAndConditionGroupsCount() { + return andConditionGroups_.size(); + } + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup getAndConditionGroups( + int index) { + return andConditionGroups_.get(index); + } + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index) { + return andConditionGroups_.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 < andConditionGroups_.size(); i++) { + output.writeMessage(1, andConditionGroups_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < andConditionGroups_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, andConditionGroups_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.EventSegmentCriteria)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.EventSegmentCriteria other = + (com.google.analytics.data.v1alpha.EventSegmentCriteria) obj; + + if (!getAndConditionGroupsList().equals(other.getAndConditionGroupsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAndConditionGroupsCount() > 0) { + hash = (37 * hash) + AND_CONDITION_GROUPS_FIELD_NUMBER; + hash = (53 * hash) + getAndConditionGroupsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria 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.analytics.data.v1alpha.EventSegmentCriteria parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.EventSegmentCriteria 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * An event matches a criteria if the event meet the conditions in the
+   * criteria.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegmentCriteria} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.EventSegmentCriteria) + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegmentCriteria.class, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.EventSegmentCriteria.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getAndConditionGroupsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (andConditionGroupsBuilder_ == null) { + andConditionGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + andConditionGroupsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteria getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteria build() { + com.google.analytics.data.v1alpha.EventSegmentCriteria result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteria buildPartial() { + com.google.analytics.data.v1alpha.EventSegmentCriteria result = + new com.google.analytics.data.v1alpha.EventSegmentCriteria(this); + int from_bitField0_ = bitField0_; + if (andConditionGroupsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = java.util.Collections.unmodifiableList(andConditionGroups_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.andConditionGroups_ = andConditionGroups_; + } else { + result.andConditionGroups_ = andConditionGroupsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.EventSegmentCriteria) { + return mergeFrom((com.google.analytics.data.v1alpha.EventSegmentCriteria) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.EventSegmentCriteria other) { + if (other == com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance()) + return this; + if (andConditionGroupsBuilder_ == null) { + if (!other.andConditionGroups_.isEmpty()) { + if (andConditionGroups_.isEmpty()) { + andConditionGroups_ = other.andConditionGroups_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.addAll(other.andConditionGroups_); + } + onChanged(); + } + } else { + if (!other.andConditionGroups_.isEmpty()) { + if (andConditionGroupsBuilder_.isEmpty()) { + andConditionGroupsBuilder_.dispose(); + andConditionGroupsBuilder_ = null; + andConditionGroups_ = other.andConditionGroups_; + bitField0_ = (bitField0_ & ~0x00000001); + andConditionGroupsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getAndConditionGroupsFieldBuilder() + : null; + } else { + andConditionGroupsBuilder_.addAllMessages(other.andConditionGroups_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.EventSegmentCriteria parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.EventSegmentCriteria) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + andConditionGroups_ = java.util.Collections.emptyList(); + + private void ensureAndConditionGroupsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = + new java.util.ArrayList( + andConditionGroups_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentConditionGroup, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder> + andConditionGroupsBuilder_; + + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List + getAndConditionGroupsList() { + if (andConditionGroupsBuilder_ == null) { + return java.util.Collections.unmodifiableList(andConditionGroups_); + } else { + return andConditionGroupsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public int getAndConditionGroupsCount() { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.size(); + } else { + return andConditionGroupsBuilder_.getCount(); + } + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup getAndConditionGroups( + int index) { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.get(index); + } else { + return andConditionGroupsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder setAndConditionGroups( + int index, com.google.analytics.data.v1alpha.EventSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.set(index, value); + onChanged(); + } else { + andConditionGroupsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder setAndConditionGroups( + int index, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.set(index, builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + com.google.analytics.data.v1alpha.EventSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(value); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + int index, com.google.analytics.data.v1alpha.EventSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(index, value); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + int index, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(index, builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAllAndConditionGroups( + java.lang.Iterable + values) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, andConditionGroups_); + onChanged(); + } else { + andConditionGroupsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder clearAndConditionGroups() { + if (andConditionGroupsBuilder_ == null) { + andConditionGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + andConditionGroupsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder removeAndConditionGroups(int index) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.remove(index); + onChanged(); + } else { + andConditionGroupsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder + getAndConditionGroupsBuilder(int index) { + return getAndConditionGroupsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index) { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.get(index); + } else { + return andConditionGroupsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder> + getAndConditionGroupsOrBuilderList() { + if (andConditionGroupsBuilder_ != null) { + return andConditionGroupsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(andConditionGroups_); + } + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder + addAndConditionGroupsBuilder() { + return getAndConditionGroupsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.getDefaultInstance()); + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder + addAndConditionGroupsBuilder(int index) { + return getAndConditionGroupsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.getDefaultInstance()); + } + /** + * + * + *
+     * An event matches this criteria if the event matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List + getAndConditionGroupsBuilderList() { + return getAndConditionGroupsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentConditionGroup, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder> + getAndConditionGroupsFieldBuilder() { + if (andConditionGroupsBuilder_ == null) { + andConditionGroupsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentConditionGroup, + com.google.analytics.data.v1alpha.EventSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder>( + andConditionGroups_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + andConditionGroups_ = null; + } + return andConditionGroupsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.EventSegmentCriteria) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.EventSegmentCriteria) + private static final com.google.analytics.data.v1alpha.EventSegmentCriteria DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.EventSegmentCriteria(); + } + + public static com.google.analytics.data.v1alpha.EventSegmentCriteria getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventSegmentCriteria parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EventSegmentCriteria(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.EventSegmentCriteria getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteriaOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteriaOrBuilder.java new file mode 100644 index 00000000..c694e414 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentCriteriaOrBuilder.java @@ -0,0 +1,94 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface EventSegmentCriteriaOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.EventSegmentCriteria) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + java.util.List + getAndConditionGroupsList(); + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + com.google.analytics.data.v1alpha.EventSegmentConditionGroup getAndConditionGroups(int index); + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + int getAndConditionGroupsCount(); + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + java.util.List + getAndConditionGroupsOrBuilderList(); + /** + * + * + *
+   * An event matches this criteria if the event matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * + */ + com.google.analytics.data.v1alpha.EventSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusion.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusion.java new file mode 100644 index 00000000..952466f7 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusion.java @@ -0,0 +1,949 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Specifies which events are excluded in this segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegmentExclusion} + */ +public final class EventSegmentExclusion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.EventSegmentExclusion) + EventSegmentExclusionOrBuilder { + private static final long serialVersionUID = 0L; + // Use EventSegmentExclusion.newBuilder() to construct. + private EventSegmentExclusion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EventSegmentExclusion() { + eventExclusionDuration_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EventSegmentExclusion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EventSegmentExclusion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + eventExclusionDuration_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder subBuilder = null; + if (eventExclusionCriteria_ != null) { + subBuilder = eventExclusionCriteria_.toBuilder(); + } + eventExclusionCriteria_ = + input.readMessage( + com.google.analytics.data.v1alpha.EventSegmentCriteria.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(eventExclusionCriteria_); + eventExclusionCriteria_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegmentExclusion.class, + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder.class); + } + + public static final int EVENT_EXCLUSION_DURATION_FIELD_NUMBER = 1; + private int eventExclusionDuration_; + /** + * + * + *
+   * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+   * Optional. If unspecified, an `eventExclusionDuration` of
+   * `EVENT_EXCLUSION_PERMANENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for eventExclusionDuration. + */ + @java.lang.Override + public int getEventExclusionDurationValue() { + return eventExclusionDuration_; + } + /** + * + * + *
+   * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+   * Optional. If unspecified, an `eventExclusionDuration` of
+   * `EVENT_EXCLUSION_PERMANENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return The eventExclusionDuration. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventExclusionDuration getEventExclusionDuration() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.EventExclusionDuration result = + com.google.analytics.data.v1alpha.EventExclusionDuration.valueOf(eventExclusionDuration_); + return result == null + ? com.google.analytics.data.v1alpha.EventExclusionDuration.UNRECOGNIZED + : result; + } + + public static final int EVENT_EXCLUSION_CRITERIA_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.EventSegmentCriteria eventExclusionCriteria_; + /** + * + * + *
+   * If an event meets this condition, the event is excluded from membership
+   * in the segment for the `eventExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + * @return Whether the eventExclusionCriteria field is set. + */ + @java.lang.Override + public boolean hasEventExclusionCriteria() { + return eventExclusionCriteria_ != null; + } + /** + * + * + *
+   * If an event meets this condition, the event is excluded from membership
+   * in the segment for the `eventExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + * @return The eventExclusionCriteria. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteria getEventExclusionCriteria() { + return eventExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance() + : eventExclusionCriteria_; + } + /** + * + * + *
+   * If an event meets this condition, the event is excluded from membership
+   * in the segment for the `eventExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder + getEventExclusionCriteriaOrBuilder() { + return getEventExclusionCriteria(); + } + + 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 (eventExclusionDuration_ + != com.google.analytics.data.v1alpha.EventExclusionDuration + .EVENT_EXCLUSION_DURATION_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, eventExclusionDuration_); + } + if (eventExclusionCriteria_ != null) { + output.writeMessage(2, getEventExclusionCriteria()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (eventExclusionDuration_ + != com.google.analytics.data.v1alpha.EventExclusionDuration + .EVENT_EXCLUSION_DURATION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, eventExclusionDuration_); + } + if (eventExclusionCriteria_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getEventExclusionCriteria()); + } + size += unknownFields.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.analytics.data.v1alpha.EventSegmentExclusion)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.EventSegmentExclusion other = + (com.google.analytics.data.v1alpha.EventSegmentExclusion) obj; + + if (eventExclusionDuration_ != other.eventExclusionDuration_) return false; + if (hasEventExclusionCriteria() != other.hasEventExclusionCriteria()) return false; + if (hasEventExclusionCriteria()) { + if (!getEventExclusionCriteria().equals(other.getEventExclusionCriteria())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + EVENT_EXCLUSION_DURATION_FIELD_NUMBER; + hash = (53 * hash) + eventExclusionDuration_; + if (hasEventExclusionCriteria()) { + hash = (37 * hash) + EVENT_EXCLUSION_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getEventExclusionCriteria().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion 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.analytics.data.v1alpha.EventSegmentExclusion parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.EventSegmentExclusion 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Specifies which events are excluded in this segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.EventSegmentExclusion} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.EventSegmentExclusion) + com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.EventSegmentExclusion.class, + com.google.analytics.data.v1alpha.EventSegmentExclusion.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.EventSegmentExclusion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + eventExclusionDuration_ = 0; + + if (eventExclusionCriteriaBuilder_ == null) { + eventExclusionCriteria_ = null; + } else { + eventExclusionCriteria_ = null; + eventExclusionCriteriaBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentExclusion getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.EventSegmentExclusion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentExclusion build() { + com.google.analytics.data.v1alpha.EventSegmentExclusion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentExclusion buildPartial() { + com.google.analytics.data.v1alpha.EventSegmentExclusion result = + new com.google.analytics.data.v1alpha.EventSegmentExclusion(this); + result.eventExclusionDuration_ = eventExclusionDuration_; + if (eventExclusionCriteriaBuilder_ == null) { + result.eventExclusionCriteria_ = eventExclusionCriteria_; + } else { + result.eventExclusionCriteria_ = eventExclusionCriteriaBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.EventSegmentExclusion) { + return mergeFrom((com.google.analytics.data.v1alpha.EventSegmentExclusion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.EventSegmentExclusion other) { + if (other == com.google.analytics.data.v1alpha.EventSegmentExclusion.getDefaultInstance()) + return this; + if (other.eventExclusionDuration_ != 0) { + setEventExclusionDurationValue(other.getEventExclusionDurationValue()); + } + if (other.hasEventExclusionCriteria()) { + mergeEventExclusionCriteria(other.getEventExclusionCriteria()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.EventSegmentExclusion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.EventSegmentExclusion) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int eventExclusionDuration_ = 0; + /** + * + * + *
+     * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+     * Optional. If unspecified, an `eventExclusionDuration` of
+     * `EVENT_EXCLUSION_PERMANENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for eventExclusionDuration. + */ + @java.lang.Override + public int getEventExclusionDurationValue() { + return eventExclusionDuration_; + } + /** + * + * + *
+     * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+     * Optional. If unspecified, an `eventExclusionDuration` of
+     * `EVENT_EXCLUSION_PERMANENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @param value The enum numeric value on the wire for eventExclusionDuration to set. + * @return This builder for chaining. + */ + public Builder setEventExclusionDurationValue(int value) { + + eventExclusionDuration_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+     * Optional. If unspecified, an `eventExclusionDuration` of
+     * `EVENT_EXCLUSION_PERMANENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return The eventExclusionDuration. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventExclusionDuration getEventExclusionDuration() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.EventExclusionDuration result = + com.google.analytics.data.v1alpha.EventExclusionDuration.valueOf(eventExclusionDuration_); + return result == null + ? com.google.analytics.data.v1alpha.EventExclusionDuration.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+     * Optional. If unspecified, an `eventExclusionDuration` of
+     * `EVENT_EXCLUSION_PERMANENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @param value The eventExclusionDuration to set. + * @return This builder for chaining. + */ + public Builder setEventExclusionDuration( + com.google.analytics.data.v1alpha.EventExclusionDuration value) { + if (value == null) { + throw new NullPointerException(); + } + + eventExclusionDuration_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+     * Optional. If unspecified, an `eventExclusionDuration` of
+     * `EVENT_EXCLUSION_PERMANENT` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return This builder for chaining. + */ + public Builder clearEventExclusionDuration() { + + eventExclusionDuration_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.EventSegmentCriteria eventExclusionCriteria_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentCriteria, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder> + eventExclusionCriteriaBuilder_; + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + * + * @return Whether the eventExclusionCriteria field is set. + */ + public boolean hasEventExclusionCriteria() { + return eventExclusionCriteriaBuilder_ != null || eventExclusionCriteria_ != null; + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + * + * @return The eventExclusionCriteria. + */ + public com.google.analytics.data.v1alpha.EventSegmentCriteria getEventExclusionCriteria() { + if (eventExclusionCriteriaBuilder_ == null) { + return eventExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance() + : eventExclusionCriteria_; + } else { + return eventExclusionCriteriaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + public Builder setEventExclusionCriteria( + com.google.analytics.data.v1alpha.EventSegmentCriteria value) { + if (eventExclusionCriteriaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + eventExclusionCriteria_ = value; + onChanged(); + } else { + eventExclusionCriteriaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + public Builder setEventExclusionCriteria( + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder builderForValue) { + if (eventExclusionCriteriaBuilder_ == null) { + eventExclusionCriteria_ = builderForValue.build(); + onChanged(); + } else { + eventExclusionCriteriaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + public Builder mergeEventExclusionCriteria( + com.google.analytics.data.v1alpha.EventSegmentCriteria value) { + if (eventExclusionCriteriaBuilder_ == null) { + if (eventExclusionCriteria_ != null) { + eventExclusionCriteria_ = + com.google.analytics.data.v1alpha.EventSegmentCriteria.newBuilder( + eventExclusionCriteria_) + .mergeFrom(value) + .buildPartial(); + } else { + eventExclusionCriteria_ = value; + } + onChanged(); + } else { + eventExclusionCriteriaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + public Builder clearEventExclusionCriteria() { + if (eventExclusionCriteriaBuilder_ == null) { + eventExclusionCriteria_ = null; + onChanged(); + } else { + eventExclusionCriteria_ = null; + eventExclusionCriteriaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder + getEventExclusionCriteriaBuilder() { + + onChanged(); + return getEventExclusionCriteriaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + public com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder + getEventExclusionCriteriaOrBuilder() { + if (eventExclusionCriteriaBuilder_ != null) { + return eventExclusionCriteriaBuilder_.getMessageOrBuilder(); + } else { + return eventExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.EventSegmentCriteria.getDefaultInstance() + : eventExclusionCriteria_; + } + } + /** + * + * + *
+     * If an event meets this condition, the event is excluded from membership
+     * in the segment for the `eventExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentCriteria, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder> + getEventExclusionCriteriaFieldBuilder() { + if (eventExclusionCriteriaBuilder_ == null) { + eventExclusionCriteriaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegmentCriteria, + com.google.analytics.data.v1alpha.EventSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder>( + getEventExclusionCriteria(), getParentForChildren(), isClean()); + eventExclusionCriteria_ = null; + } + return eventExclusionCriteriaBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.EventSegmentExclusion) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.EventSegmentExclusion) + private static final com.google.analytics.data.v1alpha.EventSegmentExclusion DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.EventSegmentExclusion(); + } + + public static com.google.analytics.data.v1alpha.EventSegmentExclusion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventSegmentExclusion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EventSegmentExclusion(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.EventSegmentExclusion getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusionOrBuilder.java new file mode 100644 index 00000000..4965e733 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentExclusionOrBuilder.java @@ -0,0 +1,95 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface EventSegmentExclusionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.EventSegmentExclusion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+   * Optional. If unspecified, an `eventExclusionDuration` of
+   * `EVENT_EXCLUSION_PERMANENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for eventExclusionDuration. + */ + int getEventExclusionDurationValue(); + /** + * + * + *
+   * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`.
+   * Optional. If unspecified, an `eventExclusionDuration` of
+   * `EVENT_EXCLUSION_PERMANENT` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * + * + * @return The eventExclusionDuration. + */ + com.google.analytics.data.v1alpha.EventExclusionDuration getEventExclusionDuration(); + + /** + * + * + *
+   * If an event meets this condition, the event is excluded from membership
+   * in the segment for the `eventExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + * @return Whether the eventExclusionCriteria field is set. + */ + boolean hasEventExclusionCriteria(); + /** + * + * + *
+   * If an event meets this condition, the event is excluded from membership
+   * in the segment for the `eventExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * + * @return The eventExclusionCriteria. + */ + com.google.analytics.data.v1alpha.EventSegmentCriteria getEventExclusionCriteria(); + /** + * + * + *
+   * If an event meets this condition, the event is excluded from membership
+   * in the segment for the `eventExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + */ + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder + getEventExclusionCriteriaOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentOrBuilder.java new file mode 100644 index 00000000..9c0a76f6 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/EventSegmentOrBuilder.java @@ -0,0 +1,96 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface EventSegmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.EventSegment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Defines which events are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + * @return Whether the eventInclusionCriteria field is set. + */ + boolean hasEventInclusionCriteria(); + /** + * + * + *
+   * Defines which events are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * + * @return The eventInclusionCriteria. + */ + com.google.analytics.data.v1alpha.EventSegmentCriteria getEventInclusionCriteria(); + /** + * + * + *
+   * Defines which events are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + */ + com.google.analytics.data.v1alpha.EventSegmentCriteriaOrBuilder + getEventInclusionCriteriaOrBuilder(); + + /** + * + * + *
+   * Defines which events are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + boolean hasExclusion(); + /** + * + * + *
+   * Defines which events are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + com.google.analytics.data.v1alpha.EventSegmentExclusion getExclusion(); + /** + * + * + *
+   * Defines which events are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + com.google.analytics.data.v1alpha.EventSegmentExclusionOrBuilder getExclusionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Filter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Filter.java new file mode 100644 index 00000000..1facc0d4 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Filter.java @@ -0,0 +1,1947 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * An expression to filter dimension or metric values.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Filter} + */ +public final class Filter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.Filter) + FilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use Filter.newBuilder() to construct. + private Filter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Filter() { + fieldName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Filter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Filter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + fieldName_ = s; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.StringFilter.Builder subBuilder = null; + if (oneFilterCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.StringFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.StringFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.InListFilter.Builder subBuilder = null; + if (oneFilterCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.InListFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.InListFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.NumericFilter.Builder subBuilder = null; + if (oneFilterCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.BetweenFilter.Builder subBuilder = null; + if (oneFilterCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.BetweenFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 5; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Filter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Filter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Filter.class, + com.google.analytics.data.v1alpha.Filter.Builder.class); + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public enum OneFilterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + STRING_FILTER(2), + IN_LIST_FILTER(3), + NUMERIC_FILTER(4), + BETWEEN_FILTER(5), + ONEFILTER_NOT_SET(0); + private final int value; + + private OneFilterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneFilterCase valueOf(int value) { + return forNumber(value); + } + + public static OneFilterCase forNumber(int value) { + switch (value) { + case 2: + return STRING_FILTER; + case 3: + return IN_LIST_FILTER; + case 4: + return NUMERIC_FILTER; + case 5: + return BETWEEN_FILTER; + case 0: + return ONEFILTER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public static final int FIELD_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object fieldName_; + /** + * + * + *
+   * The dimension name or metric name. Must be a name defined in dimensions
+   * or metrics.
+   * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + @java.lang.Override + public java.lang.String getFieldName() { + java.lang.Object ref = fieldName_; + 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(); + fieldName_ = s; + return s; + } + } + /** + * + * + *
+   * The dimension name or metric name. Must be a name defined in dimensions
+   * or metrics.
+   * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFieldNameBytes() { + java.lang.Object ref = fieldName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STRING_FILTER_FIELD_NUMBER = 2; + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 2; + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (oneFilterCase_ == 2) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if (oneFilterCase_ == 2) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + + public static final int IN_LIST_FILTER_FIELD_NUMBER = 3; + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 3; + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (oneFilterCase_ == 3) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if (oneFilterCase_ == 3) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + + public static final int NUMERIC_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + + public static final int BETWEEN_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + + 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.GeneratedMessageV3.isStringEmpty(fieldName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, fieldName_); + } + if (oneFilterCase_ == 2) { + output.writeMessage(2, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 3) { + output.writeMessage(3, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(fieldName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, fieldName_); + } + if (oneFilterCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + size += unknownFields.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.analytics.data.v1alpha.Filter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.Filter other = (com.google.analytics.data.v1alpha.Filter) obj; + + if (!getFieldName().equals(other.getFieldName())) return false; + if (!getOneFilterCase().equals(other.getOneFilterCase())) return false; + switch (oneFilterCase_) { + case 2: + if (!getStringFilter().equals(other.getStringFilter())) return false; + break; + case 3: + if (!getInListFilter().equals(other.getInListFilter())) return false; + break; + case 4: + if (!getNumericFilter().equals(other.getNumericFilter())) return false; + break; + case 5: + if (!getBetweenFilter().equals(other.getBetweenFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + FIELD_NAME_FIELD_NUMBER; + hash = (53 * hash) + getFieldName().hashCode(); + switch (oneFilterCase_) { + case 2: + hash = (37 * hash) + STRING_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getStringFilter().hashCode(); + break; + case 3: + hash = (37 * hash) + IN_LIST_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getInListFilter().hashCode(); + break; + case 4: + hash = (37 * hash) + NUMERIC_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getNumericFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + BETWEEN_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getBetweenFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Filter 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.analytics.data.v1alpha.Filter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Filter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Filter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Filter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.Filter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * An expression to filter dimension or metric values.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Filter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.Filter) + com.google.analytics.data.v1alpha.FilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Filter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Filter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Filter.class, + com.google.analytics.data.v1alpha.Filter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.Filter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + fieldName_ = ""; + + oneFilterCase_ = 0; + oneFilter_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Filter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Filter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Filter build() { + com.google.analytics.data.v1alpha.Filter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Filter buildPartial() { + com.google.analytics.data.v1alpha.Filter result = + new com.google.analytics.data.v1alpha.Filter(this); + result.fieldName_ = fieldName_; + if (oneFilterCase_ == 2) { + if (stringFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = stringFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 3) { + if (inListFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = inListFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 4) { + if (numericFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = numericFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 5) { + if (betweenFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = betweenFilterBuilder_.build(); + } + } + result.oneFilterCase_ = oneFilterCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.Filter) { + return mergeFrom((com.google.analytics.data.v1alpha.Filter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.Filter other) { + if (other == com.google.analytics.data.v1alpha.Filter.getDefaultInstance()) return this; + if (!other.getFieldName().isEmpty()) { + fieldName_ = other.fieldName_; + onChanged(); + } + switch (other.getOneFilterCase()) { + case STRING_FILTER: + { + mergeStringFilter(other.getStringFilter()); + break; + } + case IN_LIST_FILTER: + { + mergeInListFilter(other.getInListFilter()); + break; + } + case NUMERIC_FILTER: + { + mergeNumericFilter(other.getNumericFilter()); + break; + } + case BETWEEN_FILTER: + { + mergeBetweenFilter(other.getBetweenFilter()); + break; + } + case ONEFILTER_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.Filter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.Filter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public Builder clearOneFilter() { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + return this; + } + + private java.lang.Object fieldName_ = ""; + /** + * + * + *
+     * The dimension name or metric name. Must be a name defined in dimensions
+     * or metrics.
+     * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + public java.lang.String getFieldName() { + java.lang.Object ref = fieldName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + fieldName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The dimension name or metric name. Must be a name defined in dimensions
+     * or metrics.
+     * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + public com.google.protobuf.ByteString getFieldNameBytes() { + java.lang.Object ref = fieldName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The dimension name or metric name. Must be a name defined in dimensions
+     * or metrics.
+     * 
+ * + * string field_name = 1; + * + * @param value The fieldName to set. + * @return This builder for chaining. + */ + public Builder setFieldName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + fieldName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension name or metric name. Must be a name defined in dimensions
+     * or metrics.
+     * 
+ * + * string field_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearFieldName() { + + fieldName_ = getDefaultInstance().getFieldName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension name or metric name. Must be a name defined in dimensions
+     * or metrics.
+     * 
+ * + * string field_name = 1; + * + * @param value The bytes for fieldName to set. + * @return This builder for chaining. + */ + public Builder setFieldNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + fieldName_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + stringFilterBuilder_; + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 2; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 2) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 2) { + return stringFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + public Builder setStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + stringFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 2; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + public Builder setStringFilter( + com.google.analytics.data.v1alpha.StringFilter.Builder builderForValue) { + if (stringFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + stringFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 2; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + public Builder mergeStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 2 + && oneFilter_ != com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.StringFilter.newBuilder( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 2) { + stringFilterBuilder_.mergeFrom(value); + } else { + stringFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 2; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + public Builder clearStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 2) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 2) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + stringFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + public com.google.analytics.data.v1alpha.StringFilter.Builder getStringFilterBuilder() { + return getStringFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if ((oneFilterCase_ == 2) && (stringFilterBuilder_ != null)) { + return stringFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 2) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + getStringFilterFieldBuilder() { + if (stringFilterBuilder_ == null) { + if (!(oneFilterCase_ == 2)) { + oneFilter_ = com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + stringFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder>( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 2; + onChanged(); + ; + return stringFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + inListFilterBuilder_; + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 3; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 3) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 3) { + return inListFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + public Builder setInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + inListFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 3; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + public Builder setInListFilter( + com.google.analytics.data.v1alpha.InListFilter.Builder builderForValue) { + if (inListFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + inListFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 3; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + public Builder mergeInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 3 + && oneFilter_ != com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.InListFilter.newBuilder( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 3) { + inListFilterBuilder_.mergeFrom(value); + } else { + inListFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 3; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + public Builder clearInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 3) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 3) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + inListFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + public com.google.analytics.data.v1alpha.InListFilter.Builder getInListFilterBuilder() { + return getInListFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if ((oneFilterCase_ == 3) && (inListFilterBuilder_ != null)) { + return inListFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 3) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + getInListFilterFieldBuilder() { + if (inListFilterBuilder_ == null) { + if (!(oneFilterCase_ == 3)) { + oneFilter_ = com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + inListFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder>( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 3; + onChanged(); + ; + return inListFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + numericFilterBuilder_; + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 4) { + return numericFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + public Builder setNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + numericFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + public Builder setNumericFilter( + com.google.analytics.data.v1alpha.NumericFilter.Builder builderForValue) { + if (numericFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + numericFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + public Builder mergeNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 4 + && oneFilter_ != com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.NumericFilter.newBuilder( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 4) { + numericFilterBuilder_.mergeFrom(value); + } else { + numericFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + public Builder clearNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + numericFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + public com.google.analytics.data.v1alpha.NumericFilter.Builder getNumericFilterBuilder() { + return getNumericFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if ((oneFilterCase_ == 4) && (numericFilterBuilder_ != null)) { + return numericFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + getNumericFilterFieldBuilder() { + if (numericFilterBuilder_ == null) { + if (!(oneFilterCase_ == 4)) { + oneFilter_ = com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + numericFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder>( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 4; + onChanged(); + ; + return numericFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + betweenFilterBuilder_; + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 5) { + return betweenFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + public Builder setBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + betweenFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + public Builder setBetweenFilter( + com.google.analytics.data.v1alpha.BetweenFilter.Builder builderForValue) { + if (betweenFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + betweenFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + public Builder mergeBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 5 + && oneFilter_ != com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.BetweenFilter.newBuilder( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 5) { + betweenFilterBuilder_.mergeFrom(value); + } else { + betweenFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + public Builder clearBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + betweenFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + public com.google.analytics.data.v1alpha.BetweenFilter.Builder getBetweenFilterBuilder() { + return getBetweenFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if ((oneFilterCase_ == 5) && (betweenFilterBuilder_ != null)) { + return betweenFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + getBetweenFilterFieldBuilder() { + if (betweenFilterBuilder_ == null) { + if (!(oneFilterCase_ == 5)) { + oneFilter_ = com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + betweenFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder>( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 5; + onChanged(); + ; + return betweenFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.Filter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.Filter) + private static final com.google.analytics.data.v1alpha.Filter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.Filter(); + } + + public static com.google.analytics.data.v1alpha.Filter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Filter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Filter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.Filter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpression.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpression.java new file mode 100644 index 00000000..07f68719 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpression.java @@ -0,0 +1,1782 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * To express dimension or metric filters. The fields in the same
+ * FilterExpression need to be either all dimensions or all metrics.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FilterExpression} + */ +public final class FilterExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FilterExpression) + FilterExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use FilterExpression.newBuilder() to construct. + private FilterExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FilterExpression() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FilterExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FilterExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.FilterExpressionList.Builder subBuilder = null; + if (exprCase_ == 1) { + subBuilder = + ((com.google.analytics.data.v1alpha.FilterExpressionList) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FilterExpressionList.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 1; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.FilterExpressionList.Builder subBuilder = null; + if (exprCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.FilterExpressionList) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FilterExpressionList.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.FilterExpression.Builder subBuilder = null; + if (exprCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.FilterExpression) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.FilterExpression) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.Filter.Builder subBuilder = null; + if (exprCase_ == 4) { + subBuilder = ((com.google.analytics.data.v1alpha.Filter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.Filter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.Filter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 4; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FilterExpression.class, + com.google.analytics.data.v1alpha.FilterExpression.Builder.class); + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public enum ExprCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AND_GROUP(1), + OR_GROUP(2), + NOT_EXPRESSION(3), + FILTER(4), + EXPR_NOT_SET(0); + private final int value; + + private ExprCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ExprCase valueOf(int value) { + return forNumber(value); + } + + public static ExprCase forNumber(int value) { + switch (value) { + case 1: + return AND_GROUP; + case 2: + return OR_GROUP; + case 3: + return NOT_EXPRESSION; + case 4: + return FILTER; + case 0: + return EXPR_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public static final int AND_GROUP_FIELD_NUMBER = 1; + /** + * + * + *
+   * The FilterExpressions in and_group have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+   * The FilterExpressions in and_group have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList getAndGroup() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + /** + * + * + *
+   * The FilterExpressions in and_group have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder getAndGroupOrBuilder() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + + public static final int OR_GROUP_FIELD_NUMBER = 2; + /** + * + * + *
+   * The FilterExpressions in or_group have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+   * The FilterExpressions in or_group have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList getOrGroup() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + /** + * + * + *
+   * The FilterExpressions in or_group have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder getOrGroupOrBuilder() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + + public static final int NOT_EXPRESSION_FIELD_NUMBER = 3; + /** + * + * + *
+   * The FilterExpression is NOT of not_expression.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+   * The FilterExpression is NOT of not_expression.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression getNotExpression() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } + /** + * + * + *
+   * The FilterExpression is NOT of not_expression.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getNotExpressionOrBuilder() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } + + public static final int FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * A primitive filter. In the same FilterExpression, all of the filter's
+   * field names need to be either all dimensions or all metrics.
+   * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + * + * @return Whether the filter field is set. + */ + @java.lang.Override + public boolean hasFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+   * A primitive filter. In the same FilterExpression, all of the filter's
+   * field names need to be either all dimensions or all metrics.
+   * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + * + * @return The filter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Filter getFilter() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.Filter) expr_; + } + return com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } + /** + * + * + *
+   * A primitive filter. In the same FilterExpression, all of the filter's
+   * field names need to be either all dimensions or all metrics.
+   * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterOrBuilder getFilterOrBuilder() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.Filter) expr_; + } + return com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } + + 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 (exprCase_ == 1) { + output.writeMessage(1, (com.google.analytics.data.v1alpha.FilterExpressionList) expr_); + } + if (exprCase_ == 2) { + output.writeMessage(2, (com.google.analytics.data.v1alpha.FilterExpressionList) expr_); + } + if (exprCase_ == 3) { + output.writeMessage(3, (com.google.analytics.data.v1alpha.FilterExpression) expr_); + } + if (exprCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.Filter) expr_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (exprCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.analytics.data.v1alpha.FilterExpressionList) expr_); + } + if (exprCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.FilterExpressionList) expr_); + } + if (exprCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.FilterExpression) expr_); + } + if (exprCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.Filter) expr_); + } + size += unknownFields.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.analytics.data.v1alpha.FilterExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FilterExpression other = + (com.google.analytics.data.v1alpha.FilterExpression) obj; + + if (!getExprCase().equals(other.getExprCase())) return false; + switch (exprCase_) { + case 1: + if (!getAndGroup().equals(other.getAndGroup())) return false; + break; + case 2: + if (!getOrGroup().equals(other.getOrGroup())) return false; + break; + case 3: + if (!getNotExpression().equals(other.getNotExpression())) return false; + break; + case 4: + if (!getFilter().equals(other.getFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (exprCase_) { + case 1: + hash = (37 * hash) + AND_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getAndGroup().hashCode(); + break; + case 2: + hash = (37 * hash) + OR_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getOrGroup().hashCode(); + break; + case 3: + hash = (37 * hash) + NOT_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getNotExpression().hashCode(); + break; + case 4: + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FilterExpression 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.analytics.data.v1alpha.FilterExpression parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FilterExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FilterExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * To express dimension or metric filters. The fields in the same
+   * FilterExpression need to be either all dimensions or all metrics.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FilterExpression} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FilterExpression) + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FilterExpression.class, + com.google.analytics.data.v1alpha.FilterExpression.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FilterExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + exprCase_ = 0; + expr_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression build() { + com.google.analytics.data.v1alpha.FilterExpression result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression buildPartial() { + com.google.analytics.data.v1alpha.FilterExpression result = + new com.google.analytics.data.v1alpha.FilterExpression(this); + if (exprCase_ == 1) { + if (andGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = andGroupBuilder_.build(); + } + } + if (exprCase_ == 2) { + if (orGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = orGroupBuilder_.build(); + } + } + if (exprCase_ == 3) { + if (notExpressionBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = notExpressionBuilder_.build(); + } + } + if (exprCase_ == 4) { + if (filterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = filterBuilder_.build(); + } + } + result.exprCase_ = exprCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FilterExpression) { + return mergeFrom((com.google.analytics.data.v1alpha.FilterExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FilterExpression other) { + if (other == com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance()) + return this; + switch (other.getExprCase()) { + case AND_GROUP: + { + mergeAndGroup(other.getAndGroup()); + break; + } + case OR_GROUP: + { + mergeOrGroup(other.getOrGroup()); + break; + } + case NOT_EXPRESSION: + { + mergeNotExpression(other.getNotExpression()); + break; + } + case FILTER: + { + mergeFilter(other.getFilter()); + break; + } + case EXPR_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FilterExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FilterExpression) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public Builder clearExpr() { + exprCase_ = 0; + expr_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpressionList, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder> + andGroupBuilder_; + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList getAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } else { + if (exprCase_ == 1) { + return andGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + public Builder setAndGroup(com.google.analytics.data.v1alpha.FilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + andGroupBuilder_.setMessage(value); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.FilterExpressionList.Builder builderForValue) { + if (andGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + andGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + public Builder mergeAndGroup(com.google.analytics.data.v1alpha.FilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1 + && expr_ + != com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.FilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 1) { + andGroupBuilder_.mergeFrom(value); + } else { + andGroupBuilder_.setMessage(value); + } + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + public Builder clearAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + } + andGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + public com.google.analytics.data.v1alpha.FilterExpressionList.Builder getAndGroupBuilder() { + return getAndGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder getAndGroupOrBuilder() { + if ((exprCase_ == 1) && (andGroupBuilder_ != null)) { + return andGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FilterExpressions in and_group have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpressionList, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder> + getAndGroupFieldBuilder() { + if (andGroupBuilder_ == null) { + if (!(exprCase_ == 1)) { + expr_ = com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + andGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpressionList, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.FilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 1; + onChanged(); + ; + return andGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpressionList, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder> + orGroupBuilder_; + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList getOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } else { + if (exprCase_ == 2) { + return orGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + public Builder setOrGroup(com.google.analytics.data.v1alpha.FilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + orGroupBuilder_.setMessage(value); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.FilterExpressionList.Builder builderForValue) { + if (orGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + orGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + public Builder mergeOrGroup(com.google.analytics.data.v1alpha.FilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2 + && expr_ + != com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.FilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 2) { + orGroupBuilder_.mergeFrom(value); + } else { + orGroupBuilder_.setMessage(value); + } + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + public Builder clearOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + } + orGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + public com.google.analytics.data.v1alpha.FilterExpressionList.Builder getOrGroupBuilder() { + return getOrGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder getOrGroupOrBuilder() { + if ((exprCase_ == 2) && (orGroupBuilder_ != null)) { + return orGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FilterExpressions in or_group have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpressionList, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder> + getOrGroupFieldBuilder() { + if (orGroupBuilder_ == null) { + if (!(exprCase_ == 2)) { + expr_ = com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + orGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpressionList, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.FilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 2; + onChanged(); + ; + return orGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder> + notExpressionBuilder_; + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression getNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } else { + if (exprCase_ == 3) { + return notExpressionBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + public Builder setNotExpression(com.google.analytics.data.v1alpha.FilterExpression value) { + if (notExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + notExpressionBuilder_.setMessage(value); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.FilterExpression.Builder builderForValue) { + if (notExpressionBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + notExpressionBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + public Builder mergeNotExpression(com.google.analytics.data.v1alpha.FilterExpression value) { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3 + && expr_ != com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FilterExpression.newBuilder( + (com.google.analytics.data.v1alpha.FilterExpression) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 3) { + notExpressionBuilder_.mergeFrom(value); + } else { + notExpressionBuilder_.setMessage(value); + } + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + public Builder clearNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + } + notExpressionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + public com.google.analytics.data.v1alpha.FilterExpression.Builder getNotExpressionBuilder() { + return getNotExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getNotExpressionOrBuilder() { + if ((exprCase_ == 3) && (notExpressionBuilder_ != null)) { + return notExpressionBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FilterExpression is NOT of not_expression.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder> + getNotExpressionFieldBuilder() { + if (notExpressionBuilder_ == null) { + if (!(exprCase_ == 3)) { + expr_ = com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance(); + } + notExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.FilterExpression) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 3; + onChanged(); + ; + return notExpressionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Filter, + com.google.analytics.data.v1alpha.Filter.Builder, + com.google.analytics.data.v1alpha.FilterOrBuilder> + filterBuilder_; + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + * + * @return Whether the filter field is set. + */ + @java.lang.Override + public boolean hasFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + * + * @return The filter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Filter getFilter() { + if (filterBuilder_ == null) { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.Filter) expr_; + } + return com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } else { + if (exprCase_ == 4) { + return filterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + public Builder setFilter(com.google.analytics.data.v1alpha.Filter value) { + if (filterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + filterBuilder_.setMessage(value); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + public Builder setFilter(com.google.analytics.data.v1alpha.Filter.Builder builderForValue) { + if (filterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + filterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + public Builder mergeFilter(com.google.analytics.data.v1alpha.Filter value) { + if (filterBuilder_ == null) { + if (exprCase_ == 4 + && expr_ != com.google.analytics.data.v1alpha.Filter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.Filter.newBuilder( + (com.google.analytics.data.v1alpha.Filter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 4) { + filterBuilder_.mergeFrom(value); + } else { + filterBuilder_.setMessage(value); + } + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + public Builder clearFilter() { + if (filterBuilder_ == null) { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + } + filterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + public com.google.analytics.data.v1alpha.Filter.Builder getFilterBuilder() { + return getFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterOrBuilder getFilterOrBuilder() { + if ((exprCase_ == 4) && (filterBuilder_ != null)) { + return filterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.Filter) expr_; + } + return com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive filter. In the same FilterExpression, all of the filter's
+     * field names need to be either all dimensions or all metrics.
+     * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Filter, + com.google.analytics.data.v1alpha.Filter.Builder, + com.google.analytics.data.v1alpha.FilterOrBuilder> + getFilterFieldBuilder() { + if (filterBuilder_ == null) { + if (!(exprCase_ == 4)) { + expr_ = com.google.analytics.data.v1alpha.Filter.getDefaultInstance(); + } + filterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Filter, + com.google.analytics.data.v1alpha.Filter.Builder, + com.google.analytics.data.v1alpha.FilterOrBuilder>( + (com.google.analytics.data.v1alpha.Filter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 4; + onChanged(); + ; + return filterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FilterExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FilterExpression) + private static final com.google.analytics.data.v1alpha.FilterExpression DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FilterExpression(); + } + + public static com.google.analytics.data.v1alpha.FilterExpression getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FilterExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FilterExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FilterExpression getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionList.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionList.java new file mode 100644 index 00000000..edb891d4 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionList.java @@ -0,0 +1,964 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A list of filter expressions.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FilterExpressionList} + */ +public final class FilterExpressionList extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FilterExpressionList) + FilterExpressionListOrBuilder { + private static final long serialVersionUID = 0L; + // Use FilterExpressionList.newBuilder() to construct. + private FilterExpressionList(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FilterExpressionList() { + expressions_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FilterExpressionList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FilterExpressionList( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + expressions_.add( + input.readMessage( + com.google.analytics.data.v1alpha.FilterExpression.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FilterExpressionList.class, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder.class); + } + + public static final int EXPRESSIONS_FIELD_NUMBER = 1; + private java.util.List expressions_; + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + @java.lang.Override + public java.util.List getExpressionsList() { + return expressions_; + } + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + @java.lang.Override + public java.util.List + getExpressionsOrBuilderList() { + return expressions_; + } + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + @java.lang.Override + public int getExpressionsCount() { + return expressions_.size(); + } + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression getExpressions(int index) { + return expressions_.get(index); + } + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getExpressionsOrBuilder( + int index) { + return expressions_.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 < expressions_.size(); i++) { + output.writeMessage(1, expressions_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < expressions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, expressions_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.FilterExpressionList)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FilterExpressionList other = + (com.google.analytics.data.v1alpha.FilterExpressionList) obj; + + if (!getExpressionsList().equals(other.getExpressionsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExpressionsCount() > 0) { + hash = (37 * hash) + EXPRESSIONS_FIELD_NUMBER; + hash = (53 * hash) + getExpressionsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList 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.analytics.data.v1alpha.FilterExpressionList parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FilterExpressionList 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FilterExpressionList} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FilterExpressionList) + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FilterExpressionList.class, + com.google.analytics.data.v1alpha.FilterExpressionList.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FilterExpressionList.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExpressionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + expressionsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FilterExpressionList_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList build() { + com.google.analytics.data.v1alpha.FilterExpressionList result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionList buildPartial() { + com.google.analytics.data.v1alpha.FilterExpressionList result = + new com.google.analytics.data.v1alpha.FilterExpressionList(this); + int from_bitField0_ = bitField0_; + if (expressionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.expressions_ = expressions_; + } else { + result.expressions_ = expressionsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FilterExpressionList) { + return mergeFrom((com.google.analytics.data.v1alpha.FilterExpressionList) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FilterExpressionList other) { + if (other == com.google.analytics.data.v1alpha.FilterExpressionList.getDefaultInstance()) + return this; + if (expressionsBuilder_ == null) { + if (!other.expressions_.isEmpty()) { + if (expressions_.isEmpty()) { + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExpressionsIsMutable(); + expressions_.addAll(other.expressions_); + } + onChanged(); + } + } else { + if (!other.expressions_.isEmpty()) { + if (expressionsBuilder_.isEmpty()) { + expressionsBuilder_.dispose(); + expressionsBuilder_ = null; + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + expressionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExpressionsFieldBuilder() + : null; + } else { + expressionsBuilder_.addAllMessages(other.expressions_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FilterExpressionList parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FilterExpressionList) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List expressions_ = + java.util.Collections.emptyList(); + + private void ensureExpressionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList( + expressions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder> + expressionsBuilder_; + + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public java.util.List getExpressionsList() { + if (expressionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(expressions_); + } else { + return expressionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public int getExpressionsCount() { + if (expressionsBuilder_ == null) { + return expressions_.size(); + } else { + return expressionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FilterExpression getExpressions(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder setExpressions( + int index, com.google.analytics.data.v1alpha.FilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.set(index, value); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder setExpressions( + int index, com.google.analytics.data.v1alpha.FilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.set(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder addExpressions(com.google.analytics.data.v1alpha.FilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(value); + onChanged(); + } else { + expressionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder addExpressions( + int index, com.google.analytics.data.v1alpha.FilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(index, value); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.FilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder addExpressions( + int index, com.google.analytics.data.v1alpha.FilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder addAllExpressions( + java.lang.Iterable values) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, expressions_); + onChanged(); + } else { + expressionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder clearExpressions() { + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + expressionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public Builder removeExpressions(int index) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.remove(index); + onChanged(); + } else { + expressionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FilterExpression.Builder getExpressionsBuilder( + int index) { + return getExpressionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getExpressionsOrBuilder( + int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public java.util.List + getExpressionsOrBuilderList() { + if (expressionsBuilder_ != null) { + return expressionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(expressions_); + } + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FilterExpression.Builder addExpressionsBuilder() { + return getExpressionsFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance()); + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FilterExpression.Builder addExpressionsBuilder( + int index) { + return getExpressionsFieldBuilder() + .addBuilder( + index, com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance()); + } + /** + * + * + *
+     * A list of filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + public java.util.List + getExpressionsBuilderList() { + return getExpressionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder> + getExpressionsFieldBuilder() { + if (expressionsBuilder_ == null) { + expressionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder>( + expressions_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + expressions_ = null; + } + return expressionsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FilterExpressionList) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FilterExpressionList) + private static final com.google.analytics.data.v1alpha.FilterExpressionList DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FilterExpressionList(); + } + + public static com.google.analytics.data.v1alpha.FilterExpressionList getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FilterExpressionList parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FilterExpressionList(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FilterExpressionList getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionListOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionListOrBuilder.java new file mode 100644 index 00000000..e8c0264e --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionListOrBuilder.java @@ -0,0 +1,77 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FilterExpressionListOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FilterExpressionList) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + java.util.List getExpressionsList(); + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + com.google.analytics.data.v1alpha.FilterExpression getExpressions(int index); + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + int getExpressionsCount(); + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + java.util.List + getExpressionsOrBuilderList(); + /** + * + * + *
+   * A list of filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getExpressionsOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionOrBuilder.java new file mode 100644 index 00000000..68ef0917 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterExpressionOrBuilder.java @@ -0,0 +1,170 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FilterExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FilterExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The FilterExpressions in and_group have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + boolean hasAndGroup(); + /** + * + * + *
+   * The FilterExpressions in and_group have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + com.google.analytics.data.v1alpha.FilterExpressionList getAndGroup(); + /** + * + * + *
+   * The FilterExpressions in and_group have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + */ + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder getAndGroupOrBuilder(); + + /** + * + * + *
+   * The FilterExpressions in or_group have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + boolean hasOrGroup(); + /** + * + * + *
+   * The FilterExpressions in or_group have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + com.google.analytics.data.v1alpha.FilterExpressionList getOrGroup(); + /** + * + * + *
+   * The FilterExpressions in or_group have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + */ + com.google.analytics.data.v1alpha.FilterExpressionListOrBuilder getOrGroupOrBuilder(); + + /** + * + * + *
+   * The FilterExpression is NOT of not_expression.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + boolean hasNotExpression(); + /** + * + * + *
+   * The FilterExpression is NOT of not_expression.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * + * @return The notExpression. + */ + com.google.analytics.data.v1alpha.FilterExpression getNotExpression(); + /** + * + * + *
+   * The FilterExpression is NOT of not_expression.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + */ + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getNotExpressionOrBuilder(); + + /** + * + * + *
+   * A primitive filter. In the same FilterExpression, all of the filter's
+   * field names need to be either all dimensions or all metrics.
+   * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + * + * @return Whether the filter field is set. + */ + boolean hasFilter(); + /** + * + * + *
+   * A primitive filter. In the same FilterExpression, all of the filter's
+   * field names need to be either all dimensions or all metrics.
+   * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + * + * @return The filter. + */ + com.google.analytics.data.v1alpha.Filter getFilter(); + /** + * + * + *
+   * A primitive filter. In the same FilterExpression, all of the filter's
+   * field names need to be either all dimensions or all metrics.
+   * 
+ * + * .google.analytics.data.v1alpha.Filter filter = 4; + */ + com.google.analytics.data.v1alpha.FilterOrBuilder getFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.FilterExpression.ExprCase getExprCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterOrBuilder.java new file mode 100644 index 00000000..769dabb5 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FilterOrBuilder.java @@ -0,0 +1,194 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.Filter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The dimension name or metric name. Must be a name defined in dimensions
+   * or metrics.
+   * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + java.lang.String getFieldName(); + /** + * + * + *
+   * The dimension name or metric name. Must be a name defined in dimensions
+   * or metrics.
+   * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + com.google.protobuf.ByteString getFieldNameBytes(); + + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * + * @return Whether the stringFilter field is set. + */ + boolean hasStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * + * @return The stringFilter. + */ + com.google.analytics.data.v1alpha.StringFilter getStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 2; + */ + com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder(); + + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * + * @return Whether the inListFilter field is set. + */ + boolean hasInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * + * @return The inListFilter. + */ + com.google.analytics.data.v1alpha.InListFilter getInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + */ + com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder(); + + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * + * @return Whether the numericFilter field is set. + */ + boolean hasNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * + * @return The numericFilter. + */ + com.google.analytics.data.v1alpha.NumericFilter getNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + */ + com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder(); + + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * + * @return Whether the betweenFilter field is set. + */ + boolean hasBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * + * @return The betweenFilter. + */ + com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + */ + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.Filter.OneFilterCase getOneFilterCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Funnel.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Funnel.java new file mode 100644 index 00000000..95c6463f --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Funnel.java @@ -0,0 +1,1058 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Configures the funnel in a funnel report request. A funnel reports on users
+ * as they pass through a sequence of steps.
+ * Funnel exploration lets you visualize the steps your users take to complete a
+ * task and quickly see how well they are succeeding or failing at each step.
+ * For example, how do prospects become shoppers and then become buyers? How do
+ * one time buyers become repeat buyers? With this information, you can improve
+ * inefficient or abandoned customer journeys.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Funnel} + */ +public final class Funnel extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.Funnel) + FunnelOrBuilder { + private static final long serialVersionUID = 0L; + // Use Funnel.newBuilder() to construct. + private Funnel(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Funnel() { + steps_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Funnel(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Funnel( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + isOpenFunnel_ = input.readBool(); + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + steps_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + steps_.add( + input.readMessage( + com.google.analytics.data.v1alpha.FunnelStep.parser(), extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + steps_ = java.util.Collections.unmodifiableList(steps_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Funnel_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Funnel_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Funnel.class, + com.google.analytics.data.v1alpha.Funnel.Builder.class); + } + + public static final int IS_OPEN_FUNNEL_FIELD_NUMBER = 1; + private boolean isOpenFunnel_; + /** + * + * + *
+   * In an open funnel, users can enter the funnel in any step, and in a closed
+   * funnel, users must enter the funnel in the first step. Optional. If
+   * unspecified, a closed funnel is used.
+   * 
+ * + * bool is_open_funnel = 1; + * + * @return The isOpenFunnel. + */ + @java.lang.Override + public boolean getIsOpenFunnel() { + return isOpenFunnel_; + } + + public static final int STEPS_FIELD_NUMBER = 2; + private java.util.List steps_; + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + @java.lang.Override + public java.util.List getStepsList() { + return steps_; + } + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + @java.lang.Override + public java.util.List + getStepsOrBuilderList() { + return steps_; + } + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + @java.lang.Override + public int getStepsCount() { + return steps_.size(); + } + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelStep getSteps(int index) { + return steps_.get(index); + } + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelStepOrBuilder getStepsOrBuilder(int index) { + return steps_.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 (isOpenFunnel_ != false) { + output.writeBool(1, isOpenFunnel_); + } + for (int i = 0; i < steps_.size(); i++) { + output.writeMessage(2, steps_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (isOpenFunnel_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, isOpenFunnel_); + } + for (int i = 0; i < steps_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, steps_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.Funnel)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.Funnel other = (com.google.analytics.data.v1alpha.Funnel) obj; + + if (getIsOpenFunnel() != other.getIsOpenFunnel()) return false; + if (!getStepsList().equals(other.getStepsList())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + IS_OPEN_FUNNEL_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIsOpenFunnel()); + if (getStepsCount() > 0) { + hash = (37 * hash) + STEPS_FIELD_NUMBER; + hash = (53 * hash) + getStepsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Funnel 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.analytics.data.v1alpha.Funnel parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Funnel parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Funnel parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Funnel parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.Funnel 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Configures the funnel in a funnel report request. A funnel reports on users
+   * as they pass through a sequence of steps.
+   * Funnel exploration lets you visualize the steps your users take to complete a
+   * task and quickly see how well they are succeeding or failing at each step.
+   * For example, how do prospects become shoppers and then become buyers? How do
+   * one time buyers become repeat buyers? With this information, you can improve
+   * inefficient or abandoned customer journeys.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Funnel} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.Funnel) + com.google.analytics.data.v1alpha.FunnelOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Funnel_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Funnel_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Funnel.class, + com.google.analytics.data.v1alpha.Funnel.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.Funnel.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getStepsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + isOpenFunnel_ = false; + + if (stepsBuilder_ == null) { + steps_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + stepsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Funnel_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Funnel getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.Funnel.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Funnel build() { + com.google.analytics.data.v1alpha.Funnel result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Funnel buildPartial() { + com.google.analytics.data.v1alpha.Funnel result = + new com.google.analytics.data.v1alpha.Funnel(this); + int from_bitField0_ = bitField0_; + result.isOpenFunnel_ = isOpenFunnel_; + if (stepsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + steps_ = java.util.Collections.unmodifiableList(steps_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.steps_ = steps_; + } else { + result.steps_ = stepsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.Funnel) { + return mergeFrom((com.google.analytics.data.v1alpha.Funnel) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.Funnel other) { + if (other == com.google.analytics.data.v1alpha.Funnel.getDefaultInstance()) return this; + if (other.getIsOpenFunnel() != false) { + setIsOpenFunnel(other.getIsOpenFunnel()); + } + if (stepsBuilder_ == null) { + if (!other.steps_.isEmpty()) { + if (steps_.isEmpty()) { + steps_ = other.steps_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureStepsIsMutable(); + steps_.addAll(other.steps_); + } + onChanged(); + } + } else { + if (!other.steps_.isEmpty()) { + if (stepsBuilder_.isEmpty()) { + stepsBuilder_.dispose(); + stepsBuilder_ = null; + steps_ = other.steps_; + bitField0_ = (bitField0_ & ~0x00000001); + stepsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getStepsFieldBuilder() + : null; + } else { + stepsBuilder_.addAllMessages(other.steps_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.Funnel parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.Funnel) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private boolean isOpenFunnel_; + /** + * + * + *
+     * In an open funnel, users can enter the funnel in any step, and in a closed
+     * funnel, users must enter the funnel in the first step. Optional. If
+     * unspecified, a closed funnel is used.
+     * 
+ * + * bool is_open_funnel = 1; + * + * @return The isOpenFunnel. + */ + @java.lang.Override + public boolean getIsOpenFunnel() { + return isOpenFunnel_; + } + /** + * + * + *
+     * In an open funnel, users can enter the funnel in any step, and in a closed
+     * funnel, users must enter the funnel in the first step. Optional. If
+     * unspecified, a closed funnel is used.
+     * 
+ * + * bool is_open_funnel = 1; + * + * @param value The isOpenFunnel to set. + * @return This builder for chaining. + */ + public Builder setIsOpenFunnel(boolean value) { + + isOpenFunnel_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * In an open funnel, users can enter the funnel in any step, and in a closed
+     * funnel, users must enter the funnel in the first step. Optional. If
+     * unspecified, a closed funnel is used.
+     * 
+ * + * bool is_open_funnel = 1; + * + * @return This builder for chaining. + */ + public Builder clearIsOpenFunnel() { + + isOpenFunnel_ = false; + onChanged(); + return this; + } + + private java.util.List steps_ = + java.util.Collections.emptyList(); + + private void ensureStepsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + steps_ = new java.util.ArrayList(steps_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelStep, + com.google.analytics.data.v1alpha.FunnelStep.Builder, + com.google.analytics.data.v1alpha.FunnelStepOrBuilder> + stepsBuilder_; + + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public java.util.List getStepsList() { + if (stepsBuilder_ == null) { + return java.util.Collections.unmodifiableList(steps_); + } else { + return stepsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public int getStepsCount() { + if (stepsBuilder_ == null) { + return steps_.size(); + } else { + return stepsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public com.google.analytics.data.v1alpha.FunnelStep getSteps(int index) { + if (stepsBuilder_ == null) { + return steps_.get(index); + } else { + return stepsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder setSteps(int index, com.google.analytics.data.v1alpha.FunnelStep value) { + if (stepsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureStepsIsMutable(); + steps_.set(index, value); + onChanged(); + } else { + stepsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder setSteps( + int index, com.google.analytics.data.v1alpha.FunnelStep.Builder builderForValue) { + if (stepsBuilder_ == null) { + ensureStepsIsMutable(); + steps_.set(index, builderForValue.build()); + onChanged(); + } else { + stepsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder addSteps(com.google.analytics.data.v1alpha.FunnelStep value) { + if (stepsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureStepsIsMutable(); + steps_.add(value); + onChanged(); + } else { + stepsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder addSteps(int index, com.google.analytics.data.v1alpha.FunnelStep value) { + if (stepsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureStepsIsMutable(); + steps_.add(index, value); + onChanged(); + } else { + stepsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder addSteps(com.google.analytics.data.v1alpha.FunnelStep.Builder builderForValue) { + if (stepsBuilder_ == null) { + ensureStepsIsMutable(); + steps_.add(builderForValue.build()); + onChanged(); + } else { + stepsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder addSteps( + int index, com.google.analytics.data.v1alpha.FunnelStep.Builder builderForValue) { + if (stepsBuilder_ == null) { + ensureStepsIsMutable(); + steps_.add(index, builderForValue.build()); + onChanged(); + } else { + stepsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder addAllSteps( + java.lang.Iterable values) { + if (stepsBuilder_ == null) { + ensureStepsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, steps_); + onChanged(); + } else { + stepsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder clearSteps() { + if (stepsBuilder_ == null) { + steps_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + stepsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public Builder removeSteps(int index) { + if (stepsBuilder_ == null) { + ensureStepsIsMutable(); + steps_.remove(index); + onChanged(); + } else { + stepsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public com.google.analytics.data.v1alpha.FunnelStep.Builder getStepsBuilder(int index) { + return getStepsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public com.google.analytics.data.v1alpha.FunnelStepOrBuilder getStepsOrBuilder(int index) { + if (stepsBuilder_ == null) { + return steps_.get(index); + } else { + return stepsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public java.util.List + getStepsOrBuilderList() { + if (stepsBuilder_ != null) { + return stepsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(steps_); + } + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public com.google.analytics.data.v1alpha.FunnelStep.Builder addStepsBuilder() { + return getStepsFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.FunnelStep.getDefaultInstance()); + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public com.google.analytics.data.v1alpha.FunnelStep.Builder addStepsBuilder(int index) { + return getStepsFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.FunnelStep.getDefaultInstance()); + } + /** + * + * + *
+     * The sequential steps of this funnel.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + public java.util.List + getStepsBuilderList() { + return getStepsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelStep, + com.google.analytics.data.v1alpha.FunnelStep.Builder, + com.google.analytics.data.v1alpha.FunnelStepOrBuilder> + getStepsFieldBuilder() { + if (stepsBuilder_ == null) { + stepsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelStep, + com.google.analytics.data.v1alpha.FunnelStep.Builder, + com.google.analytics.data.v1alpha.FunnelStepOrBuilder>( + steps_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + steps_ = null; + } + return stepsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.Funnel) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.Funnel) + private static final com.google.analytics.data.v1alpha.Funnel DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.Funnel(); + } + + public static com.google.analytics.data.v1alpha.Funnel getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Funnel parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Funnel(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.Funnel getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdown.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdown.java new file mode 100644 index 00000000..8c6651c5 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdown.java @@ -0,0 +1,908 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Breakdowns add a dimension to the funnel table sub report response.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelBreakdown} + */ +public final class FunnelBreakdown extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelBreakdown) + FunnelBreakdownOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelBreakdown.newBuilder() to construct. + private FunnelBreakdown(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelBreakdown() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelBreakdown(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelBreakdown( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.Dimension.Builder subBuilder = null; + if (breakdownDimension_ != null) { + subBuilder = breakdownDimension_.toBuilder(); + } + breakdownDimension_ = + input.readMessage( + com.google.analytics.data.v1alpha.Dimension.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(breakdownDimension_); + breakdownDimension_ = subBuilder.buildPartial(); + } + + break; + } + case 16: + { + bitField0_ |= 0x00000001; + limit_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelBreakdown_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelBreakdown_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelBreakdown.class, + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder.class); + } + + private int bitField0_; + public static final int BREAKDOWN_DIMENSION_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.Dimension breakdownDimension_; + /** + * + * + *
+   * The dimension column added to the funnel table sub report response. The
+   * breakdown dimension breaks down each funnel step. A valid
+   * `breakdownDimension` is required if `funnelBreakdown` is specified.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * + * @return Whether the breakdownDimension field is set. + */ + @java.lang.Override + public boolean hasBreakdownDimension() { + return breakdownDimension_ != null; + } + /** + * + * + *
+   * The dimension column added to the funnel table sub report response. The
+   * breakdown dimension breaks down each funnel step. A valid
+   * `breakdownDimension` is required if `funnelBreakdown` is specified.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * + * @return The breakdownDimension. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Dimension getBreakdownDimension() { + return breakdownDimension_ == null + ? com.google.analytics.data.v1alpha.Dimension.getDefaultInstance() + : breakdownDimension_; + } + /** + * + * + *
+   * The dimension column added to the funnel table sub report response. The
+   * breakdown dimension breaks down each funnel step. A valid
+   * `breakdownDimension` is required if `funnelBreakdown` is specified.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionOrBuilder getBreakdownDimensionOrBuilder() { + return getBreakdownDimension(); + } + + public static final int LIMIT_FIELD_NUMBER = 2; + private long limit_; + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 15.
+   * 
+ * + * optional int64 limit = 2; + * + * @return Whether the limit field is set. + */ + @java.lang.Override + public boolean hasLimit() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 15.
+   * 
+ * + * optional int64 limit = 2; + * + * @return The limit. + */ + @java.lang.Override + public long getLimit() { + return limit_; + } + + 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 (breakdownDimension_ != null) { + output.writeMessage(1, getBreakdownDimension()); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeInt64(2, limit_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (breakdownDimension_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getBreakdownDimension()); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, limit_); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelBreakdown)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelBreakdown other = + (com.google.analytics.data.v1alpha.FunnelBreakdown) obj; + + if (hasBreakdownDimension() != other.hasBreakdownDimension()) return false; + if (hasBreakdownDimension()) { + if (!getBreakdownDimension().equals(other.getBreakdownDimension())) return false; + } + if (hasLimit() != other.hasLimit()) return false; + if (hasLimit()) { + if (getLimit() != other.getLimit()) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasBreakdownDimension()) { + hash = (37 * hash) + BREAKDOWN_DIMENSION_FIELD_NUMBER; + hash = (53 * hash) + getBreakdownDimension().hashCode(); + } + if (hasLimit()) { + hash = (37 * hash) + LIMIT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getLimit()); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown 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.analytics.data.v1alpha.FunnelBreakdown parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelBreakdown 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Breakdowns add a dimension to the funnel table sub report response.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelBreakdown} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelBreakdown) + com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelBreakdown_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelBreakdown_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelBreakdown.class, + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelBreakdown.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (breakdownDimensionBuilder_ == null) { + breakdownDimension_ = null; + } else { + breakdownDimension_ = null; + breakdownDimensionBuilder_ = null; + } + limit_ = 0L; + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelBreakdown_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelBreakdown getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelBreakdown.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelBreakdown build() { + com.google.analytics.data.v1alpha.FunnelBreakdown result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelBreakdown buildPartial() { + com.google.analytics.data.v1alpha.FunnelBreakdown result = + new com.google.analytics.data.v1alpha.FunnelBreakdown(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (breakdownDimensionBuilder_ == null) { + result.breakdownDimension_ = breakdownDimension_; + } else { + result.breakdownDimension_ = breakdownDimensionBuilder_.build(); + } + if (((from_bitField0_ & 0x00000001) != 0)) { + result.limit_ = limit_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelBreakdown) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelBreakdown) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelBreakdown other) { + if (other == com.google.analytics.data.v1alpha.FunnelBreakdown.getDefaultInstance()) + return this; + if (other.hasBreakdownDimension()) { + mergeBreakdownDimension(other.getBreakdownDimension()); + } + if (other.hasLimit()) { + setLimit(other.getLimit()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelBreakdown parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelBreakdown) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.analytics.data.v1alpha.Dimension breakdownDimension_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Dimension, + com.google.analytics.data.v1alpha.Dimension.Builder, + com.google.analytics.data.v1alpha.DimensionOrBuilder> + breakdownDimensionBuilder_; + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * + * @return Whether the breakdownDimension field is set. + */ + public boolean hasBreakdownDimension() { + return breakdownDimensionBuilder_ != null || breakdownDimension_ != null; + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * + * @return The breakdownDimension. + */ + public com.google.analytics.data.v1alpha.Dimension getBreakdownDimension() { + if (breakdownDimensionBuilder_ == null) { + return breakdownDimension_ == null + ? com.google.analytics.data.v1alpha.Dimension.getDefaultInstance() + : breakdownDimension_; + } else { + return breakdownDimensionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + public Builder setBreakdownDimension(com.google.analytics.data.v1alpha.Dimension value) { + if (breakdownDimensionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + breakdownDimension_ = value; + onChanged(); + } else { + breakdownDimensionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + public Builder setBreakdownDimension( + com.google.analytics.data.v1alpha.Dimension.Builder builderForValue) { + if (breakdownDimensionBuilder_ == null) { + breakdownDimension_ = builderForValue.build(); + onChanged(); + } else { + breakdownDimensionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + public Builder mergeBreakdownDimension(com.google.analytics.data.v1alpha.Dimension value) { + if (breakdownDimensionBuilder_ == null) { + if (breakdownDimension_ != null) { + breakdownDimension_ = + com.google.analytics.data.v1alpha.Dimension.newBuilder(breakdownDimension_) + .mergeFrom(value) + .buildPartial(); + } else { + breakdownDimension_ = value; + } + onChanged(); + } else { + breakdownDimensionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + public Builder clearBreakdownDimension() { + if (breakdownDimensionBuilder_ == null) { + breakdownDimension_ = null; + onChanged(); + } else { + breakdownDimension_ = null; + breakdownDimensionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + public com.google.analytics.data.v1alpha.Dimension.Builder getBreakdownDimensionBuilder() { + + onChanged(); + return getBreakdownDimensionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + public com.google.analytics.data.v1alpha.DimensionOrBuilder getBreakdownDimensionOrBuilder() { + if (breakdownDimensionBuilder_ != null) { + return breakdownDimensionBuilder_.getMessageOrBuilder(); + } else { + return breakdownDimension_ == null + ? com.google.analytics.data.v1alpha.Dimension.getDefaultInstance() + : breakdownDimension_; + } + } + /** + * + * + *
+     * The dimension column added to the funnel table sub report response. The
+     * breakdown dimension breaks down each funnel step. A valid
+     * `breakdownDimension` is required if `funnelBreakdown` is specified.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Dimension, + com.google.analytics.data.v1alpha.Dimension.Builder, + com.google.analytics.data.v1alpha.DimensionOrBuilder> + getBreakdownDimensionFieldBuilder() { + if (breakdownDimensionBuilder_ == null) { + breakdownDimensionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Dimension, + com.google.analytics.data.v1alpha.Dimension.Builder, + com.google.analytics.data.v1alpha.DimensionOrBuilder>( + getBreakdownDimension(), getParentForChildren(), isClean()); + breakdownDimension_ = null; + } + return breakdownDimensionBuilder_; + } + + private long limit_; + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 15.
+     * 
+ * + * optional int64 limit = 2; + * + * @return Whether the limit field is set. + */ + @java.lang.Override + public boolean hasLimit() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 15.
+     * 
+ * + * optional int64 limit = 2; + * + * @return The limit. + */ + @java.lang.Override + public long getLimit() { + return limit_; + } + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 15.
+     * 
+ * + * optional int64 limit = 2; + * + * @param value The limit to set. + * @return This builder for chaining. + */ + public Builder setLimit(long value) { + bitField0_ |= 0x00000001; + limit_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 15.
+     * 
+ * + * optional int64 limit = 2; + * + * @return This builder for chaining. + */ + public Builder clearLimit() { + bitField0_ = (bitField0_ & ~0x00000001); + limit_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelBreakdown) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelBreakdown) + private static final com.google.analytics.data.v1alpha.FunnelBreakdown DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelBreakdown(); + } + + public static com.google.analytics.data.v1alpha.FunnelBreakdown getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelBreakdown parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelBreakdown(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelBreakdown getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdownOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdownOrBuilder.java new file mode 100644 index 00000000..23f2d19e --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelBreakdownOrBuilder.java @@ -0,0 +1,95 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelBreakdownOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelBreakdown) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The dimension column added to the funnel table sub report response. The
+   * breakdown dimension breaks down each funnel step. A valid
+   * `breakdownDimension` is required if `funnelBreakdown` is specified.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * + * @return Whether the breakdownDimension field is set. + */ + boolean hasBreakdownDimension(); + /** + * + * + *
+   * The dimension column added to the funnel table sub report response. The
+   * breakdown dimension breaks down each funnel step. A valid
+   * `breakdownDimension` is required if `funnelBreakdown` is specified.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * + * @return The breakdownDimension. + */ + com.google.analytics.data.v1alpha.Dimension getBreakdownDimension(); + /** + * + * + *
+   * The dimension column added to the funnel table sub report response. The
+   * breakdown dimension breaks down each funnel step. A valid
+   * `breakdownDimension` is required if `funnelBreakdown` is specified.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + com.google.analytics.data.v1alpha.DimensionOrBuilder getBreakdownDimensionOrBuilder(); + + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 15.
+   * 
+ * + * optional int64 limit = 2; + * + * @return Whether the limit field is set. + */ + boolean hasLimit(); + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 15.
+   * 
+ * + * optional int64 limit = 2; + * + * @return The limit. + */ + long getLimit(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilter.java new file mode 100644 index 00000000..f7453ba0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilter.java @@ -0,0 +1,1062 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Creates a filter that matches events of a single event name. If a parameter
+ * filter expression is specified, only the subset of events that match both the
+ * single event name and the parameter filter expressions match this event
+ * filter.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelEventFilter} + */ +public final class FunnelEventFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelEventFilter) + FunnelEventFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelEventFilter.newBuilder() to construct. + private FunnelEventFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelEventFilter() { + eventName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelEventFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelEventFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + bitField0_ |= 0x00000001; + eventName_ = s; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder subBuilder = + null; + if (((bitField0_ & 0x00000002) != 0)) { + subBuilder = funnelParameterFilterExpression_.toBuilder(); + } + funnelParameterFilterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(funnelParameterFilterExpression_); + funnelParameterFilterExpression_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000002; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelEventFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelEventFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelEventFilter.class, + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder.class); + } + + private int bitField0_; + public static final int EVENT_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object eventName_; + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return Whether the eventName field is set. + */ + @java.lang.Override + public boolean hasEventName() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The eventName. + */ + @java.lang.Override + public java.lang.String getEventName() { + java.lang.Object ref = eventName_; + 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(); + eventName_ = s; + return s; + } + } + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The bytes for eventName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEventNameBytes() { + java.lang.Object ref = eventName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + eventName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FUNNEL_PARAMETER_FILTER_EXPRESSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + funnelParameterFilterExpression_; + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + * + * @return Whether the funnelParameterFilterExpression field is set. + */ + @java.lang.Override + public boolean hasFunnelParameterFilterExpression() { + return ((bitField0_ & 0x00000002) != 0); + } + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + * + * @return The funnelParameterFilterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + getFunnelParameterFilterExpression() { + return funnelParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance() + : funnelParameterFilterExpression_; + } + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getFunnelParameterFilterExpressionOrBuilder() { + return funnelParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance() + : funnelParameterFilterExpression_; + } + + 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)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, eventName_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getFunnelParameterFilterExpression()); + } + unknownFields.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.GeneratedMessageV3.computeStringSize(1, eventName_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, getFunnelParameterFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelEventFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelEventFilter other = + (com.google.analytics.data.v1alpha.FunnelEventFilter) obj; + + if (hasEventName() != other.hasEventName()) return false; + if (hasEventName()) { + if (!getEventName().equals(other.getEventName())) return false; + } + if (hasFunnelParameterFilterExpression() != other.hasFunnelParameterFilterExpression()) + return false; + if (hasFunnelParameterFilterExpression()) { + if (!getFunnelParameterFilterExpression().equals(other.getFunnelParameterFilterExpression())) + return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasEventName()) { + hash = (37 * hash) + EVENT_NAME_FIELD_NUMBER; + hash = (53 * hash) + getEventName().hashCode(); + } + if (hasFunnelParameterFilterExpression()) { + hash = (37 * hash) + FUNNEL_PARAMETER_FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getFunnelParameterFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter 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.analytics.data.v1alpha.FunnelEventFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelEventFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a parameter
+   * filter expression is specified, only the subset of events that match both the
+   * single event name and the parameter filter expressions match this event
+   * filter.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelEventFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelEventFilter) + com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelEventFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelEventFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelEventFilter.class, + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelEventFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getFunnelParameterFilterExpressionFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + eventName_ = ""; + bitField0_ = (bitField0_ & ~0x00000001); + if (funnelParameterFilterExpressionBuilder_ == null) { + funnelParameterFilterExpression_ = null; + } else { + funnelParameterFilterExpressionBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelEventFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilter build() { + com.google.analytics.data.v1alpha.FunnelEventFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilter buildPartial() { + com.google.analytics.data.v1alpha.FunnelEventFilter result = + new com.google.analytics.data.v1alpha.FunnelEventFilter(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + to_bitField0_ |= 0x00000001; + } + result.eventName_ = eventName_; + if (((from_bitField0_ & 0x00000002) != 0)) { + if (funnelParameterFilterExpressionBuilder_ == null) { + result.funnelParameterFilterExpression_ = funnelParameterFilterExpression_; + } else { + result.funnelParameterFilterExpression_ = funnelParameterFilterExpressionBuilder_.build(); + } + to_bitField0_ |= 0x00000002; + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelEventFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelEventFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelEventFilter other) { + if (other == com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance()) + return this; + if (other.hasEventName()) { + bitField0_ |= 0x00000001; + eventName_ = other.eventName_; + onChanged(); + } + if (other.hasFunnelParameterFilterExpression()) { + mergeFunnelParameterFilterExpression(other.getFunnelParameterFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelEventFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelEventFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object eventName_ = ""; + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return Whether the eventName field is set. + */ + public boolean hasEventName() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return The eventName. + */ + public java.lang.String getEventName() { + java.lang.Object ref = eventName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + eventName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return The bytes for eventName. + */ + public com.google.protobuf.ByteString getEventNameBytes() { + java.lang.Object ref = eventName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + eventName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @param value The eventName to set. + * @return This builder for chaining. + */ + public Builder setEventName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + eventName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearEventName() { + bitField0_ = (bitField0_ & ~0x00000001); + eventName_ = getDefaultInstance().getEventName(); + onChanged(); + return this; + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @param value The bytes for eventName to set. + * @return This builder for chaining. + */ + public Builder setEventNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + bitField0_ |= 0x00000001; + eventName_ = value; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + funnelParameterFilterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + funnelParameterFilterExpressionBuilder_; + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + * + * @return Whether the funnelParameterFilterExpression field is set. + */ + public boolean hasFunnelParameterFilterExpression() { + return ((bitField0_ & 0x00000002) != 0); + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + * + * @return The funnelParameterFilterExpression. + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + getFunnelParameterFilterExpression() { + if (funnelParameterFilterExpressionBuilder_ == null) { + return funnelParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance() + : funnelParameterFilterExpression_; + } else { + return funnelParameterFilterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + public Builder setFunnelParameterFilterExpression( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (funnelParameterFilterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + funnelParameterFilterExpression_ = value; + onChanged(); + } else { + funnelParameterFilterExpressionBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + public Builder setFunnelParameterFilterExpression( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder builderForValue) { + if (funnelParameterFilterExpressionBuilder_ == null) { + funnelParameterFilterExpression_ = builderForValue.build(); + onChanged(); + } else { + funnelParameterFilterExpressionBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + public Builder mergeFunnelParameterFilterExpression( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (funnelParameterFilterExpressionBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && funnelParameterFilterExpression_ != null + && funnelParameterFilterExpression_ + != com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance()) { + funnelParameterFilterExpression_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.newBuilder( + funnelParameterFilterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + funnelParameterFilterExpression_ = value; + } + onChanged(); + } else { + funnelParameterFilterExpressionBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + public Builder clearFunnelParameterFilterExpression() { + if (funnelParameterFilterExpressionBuilder_ == null) { + funnelParameterFilterExpression_ = null; + onChanged(); + } else { + funnelParameterFilterExpressionBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder + getFunnelParameterFilterExpressionBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return getFunnelParameterFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getFunnelParameterFilterExpressionOrBuilder() { + if (funnelParameterFilterExpressionBuilder_ != null) { + return funnelParameterFilterExpressionBuilder_.getMessageOrBuilder(); + } else { + return funnelParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance() + : funnelParameterFilterExpression_; + } + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + getFunnelParameterFilterExpressionFieldBuilder() { + if (funnelParameterFilterExpressionBuilder_ == null) { + funnelParameterFilterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder>( + getFunnelParameterFilterExpression(), getParentForChildren(), isClean()); + funnelParameterFilterExpression_ = null; + } + return funnelParameterFilterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelEventFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelEventFilter) + private static final com.google.analytics.data.v1alpha.FunnelEventFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelEventFilter(); + } + + public static com.google.analytics.data.v1alpha.FunnelEventFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelEventFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelEventFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelEventFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilterOrBuilder.java new file mode 100644 index 00000000..962cfb0f --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelEventFilterOrBuilder.java @@ -0,0 +1,117 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelEventFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelEventFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return Whether the eventName field is set. + */ + boolean hasEventName(); + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The eventName. + */ + java.lang.String getEventName(); + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The bytes for eventName. + */ + com.google.protobuf.ByteString getEventNameBytes(); + + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + * + * @return Whether the funnelParameterFilterExpression field is set. + */ + boolean hasFunnelParameterFilterExpression(); + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + * + * @return The funnelParameterFilterExpression. + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + getFunnelParameterFilterExpression(); + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getFunnelParameterFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilter.java new file mode 100644 index 00000000..a5a228dd --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilter.java @@ -0,0 +1,1941 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * An expression to filter dimension or metric values.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelFilter} + */ +public final class FunnelFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelFilter) + FunnelFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelFilter.newBuilder() to construct. + private FunnelFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelFilter() { + fieldName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + fieldName_ = s; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.StringFilter.Builder subBuilder = null; + if (oneFilterCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.StringFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.StringFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.InListFilter.Builder subBuilder = null; + if (oneFilterCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.InListFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.InListFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 5; + break; + } + case 50: + { + com.google.analytics.data.v1alpha.NumericFilter.Builder subBuilder = null; + if (oneFilterCase_ == 6) { + subBuilder = + ((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 6; + break; + } + case 58: + { + com.google.analytics.data.v1alpha.BetweenFilter.Builder subBuilder = null; + if (oneFilterCase_ == 7) { + subBuilder = + ((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.BetweenFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 7; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelFilter.class, + com.google.analytics.data.v1alpha.FunnelFilter.Builder.class); + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public enum OneFilterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + STRING_FILTER(4), + IN_LIST_FILTER(5), + NUMERIC_FILTER(6), + BETWEEN_FILTER(7), + ONEFILTER_NOT_SET(0); + private final int value; + + private OneFilterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneFilterCase valueOf(int value) { + return forNumber(value); + } + + public static OneFilterCase forNumber(int value) { + switch (value) { + case 4: + return STRING_FILTER; + case 5: + return IN_LIST_FILTER; + case 6: + return NUMERIC_FILTER; + case 7: + return BETWEEN_FILTER; + case 0: + return ONEFILTER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public static final int FIELD_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object fieldName_; + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + @java.lang.Override + public java.lang.String getFieldName() { + java.lang.Object ref = fieldName_; + 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(); + fieldName_ = s; + return s; + } + } + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFieldNameBytes() { + java.lang.Object ref = fieldName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STRING_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + + public static final int IN_LIST_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + + public static final int NUMERIC_FILTER_FIELD_NUMBER = 6; + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + + public static final int BETWEEN_FILTER_FIELD_NUMBER = 7; + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + + 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.GeneratedMessageV3.isStringEmpty(fieldName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, fieldName_); + } + if (oneFilterCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + output.writeMessage(6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + output.writeMessage(7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(fieldName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, fieldName_); + } + if (oneFilterCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelFilter other = + (com.google.analytics.data.v1alpha.FunnelFilter) obj; + + if (!getFieldName().equals(other.getFieldName())) return false; + if (!getOneFilterCase().equals(other.getOneFilterCase())) return false; + switch (oneFilterCase_) { + case 4: + if (!getStringFilter().equals(other.getStringFilter())) return false; + break; + case 5: + if (!getInListFilter().equals(other.getInListFilter())) return false; + break; + case 6: + if (!getNumericFilter().equals(other.getNumericFilter())) return false; + break; + case 7: + if (!getBetweenFilter().equals(other.getBetweenFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + FIELD_NAME_FIELD_NUMBER; + hash = (53 * hash) + getFieldName().hashCode(); + switch (oneFilterCase_) { + case 4: + hash = (37 * hash) + STRING_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getStringFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + IN_LIST_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getInListFilter().hashCode(); + break; + case 6: + hash = (37 * hash) + NUMERIC_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getNumericFilter().hashCode(); + break; + case 7: + hash = (37 * hash) + BETWEEN_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getBetweenFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter 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.analytics.data.v1alpha.FunnelFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * An expression to filter dimension or metric values.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelFilter) + com.google.analytics.data.v1alpha.FunnelFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelFilter.class, + com.google.analytics.data.v1alpha.FunnelFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + fieldName_ = ""; + + oneFilterCase_ = 0; + oneFilter_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilter build() { + com.google.analytics.data.v1alpha.FunnelFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilter buildPartial() { + com.google.analytics.data.v1alpha.FunnelFilter result = + new com.google.analytics.data.v1alpha.FunnelFilter(this); + result.fieldName_ = fieldName_; + if (oneFilterCase_ == 4) { + if (stringFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = stringFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 5) { + if (inListFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = inListFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 6) { + if (numericFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = numericFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 7) { + if (betweenFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = betweenFilterBuilder_.build(); + } + } + result.oneFilterCase_ = oneFilterCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelFilter other) { + if (other == com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance()) return this; + if (!other.getFieldName().isEmpty()) { + fieldName_ = other.fieldName_; + onChanged(); + } + switch (other.getOneFilterCase()) { + case STRING_FILTER: + { + mergeStringFilter(other.getStringFilter()); + break; + } + case IN_LIST_FILTER: + { + mergeInListFilter(other.getInListFilter()); + break; + } + case NUMERIC_FILTER: + { + mergeNumericFilter(other.getNumericFilter()); + break; + } + case BETWEEN_FILTER: + { + mergeBetweenFilter(other.getBetweenFilter()); + break; + } + case ONEFILTER_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.FunnelFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public Builder clearOneFilter() { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + return this; + } + + private java.lang.Object fieldName_ = ""; + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + public java.lang.String getFieldName() { + java.lang.Object ref = fieldName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + fieldName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + public com.google.protobuf.ByteString getFieldNameBytes() { + java.lang.Object ref = fieldName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @param value The fieldName to set. + * @return This builder for chaining. + */ + public Builder setFieldName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + fieldName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearFieldName() { + + fieldName_ = getDefaultInstance().getFieldName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @param value The bytes for fieldName to set. + * @return This builder for chaining. + */ + public Builder setFieldNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + fieldName_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + stringFilterBuilder_; + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 4) { + return stringFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + stringFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter( + com.google.analytics.data.v1alpha.StringFilter.Builder builderForValue) { + if (stringFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + stringFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder mergeStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4 + && oneFilter_ != com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.StringFilter.newBuilder( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 4) { + stringFilterBuilder_.mergeFrom(value); + } else { + stringFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder clearStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + stringFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public com.google.analytics.data.v1alpha.StringFilter.Builder getStringFilterBuilder() { + return getStringFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if ((oneFilterCase_ == 4) && (stringFilterBuilder_ != null)) { + return stringFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + getStringFilterFieldBuilder() { + if (stringFilterBuilder_ == null) { + if (!(oneFilterCase_ == 4)) { + oneFilter_ = com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + stringFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder>( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 4; + onChanged(); + ; + return stringFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + inListFilterBuilder_; + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 5) { + return inListFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + inListFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter( + com.google.analytics.data.v1alpha.InListFilter.Builder builderForValue) { + if (inListFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + inListFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder mergeInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5 + && oneFilter_ != com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.InListFilter.newBuilder( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 5) { + inListFilterBuilder_.mergeFrom(value); + } else { + inListFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder clearInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + inListFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public com.google.analytics.data.v1alpha.InListFilter.Builder getInListFilterBuilder() { + return getInListFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if ((oneFilterCase_ == 5) && (inListFilterBuilder_ != null)) { + return inListFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + getInListFilterFieldBuilder() { + if (inListFilterBuilder_ == null) { + if (!(oneFilterCase_ == 5)) { + oneFilter_ = com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + inListFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder>( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 5; + onChanged(); + ; + return inListFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + numericFilterBuilder_; + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 6) { + return numericFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + numericFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter( + com.google.analytics.data.v1alpha.NumericFilter.Builder builderForValue) { + if (numericFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + numericFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder mergeNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6 + && oneFilter_ != com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.NumericFilter.newBuilder( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 6) { + numericFilterBuilder_.mergeFrom(value); + } else { + numericFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder clearNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + numericFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public com.google.analytics.data.v1alpha.NumericFilter.Builder getNumericFilterBuilder() { + return getNumericFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if ((oneFilterCase_ == 6) && (numericFilterBuilder_ != null)) { + return numericFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + getNumericFilterFieldBuilder() { + if (numericFilterBuilder_ == null) { + if (!(oneFilterCase_ == 6)) { + oneFilter_ = com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + numericFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder>( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 6; + onChanged(); + ; + return numericFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + betweenFilterBuilder_; + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 7) { + return betweenFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + betweenFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter( + com.google.analytics.data.v1alpha.BetweenFilter.Builder builderForValue) { + if (betweenFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + betweenFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder mergeBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7 + && oneFilter_ != com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.BetweenFilter.newBuilder( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 7) { + betweenFilterBuilder_.mergeFrom(value); + } else { + betweenFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder clearBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + betweenFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public com.google.analytics.data.v1alpha.BetweenFilter.Builder getBetweenFilterBuilder() { + return getBetweenFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if ((oneFilterCase_ == 7) && (betweenFilterBuilder_ != null)) { + return betweenFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + getBetweenFilterFieldBuilder() { + if (betweenFilterBuilder_ == null) { + if (!(oneFilterCase_ == 7)) { + oneFilter_ = com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + betweenFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder>( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 7; + onChanged(); + ; + return betweenFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelFilter) + private static final com.google.analytics.data.v1alpha.FunnelFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelFilter(); + } + + public static com.google.analytics.data.v1alpha.FunnelFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpression.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpression.java new file mode 100644 index 00000000..db112542 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpression.java @@ -0,0 +1,2140 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Expresses combinations of funnel filters.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelFilterExpression} + */ +public final class FunnelFilterExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelFilterExpression) + FunnelFilterExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelFilterExpression.newBuilder() to construct. + private FunnelFilterExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelFilterExpression() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelFilterExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelFilterExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder subBuilder = + null; + if (exprCase_ == 1) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 1; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder subBuilder = + null; + if (exprCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder subBuilder = null; + if (exprCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.FunnelFilter.Builder subBuilder = null; + if (exprCase_ == 4) { + subBuilder = ((com.google.analytics.data.v1alpha.FunnelFilter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.FunnelFilter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder subBuilder = null; + if (exprCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelEventFilter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelEventFilter.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.FunnelEventFilter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 5; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelFilterExpression.class, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder.class); + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public enum ExprCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AND_GROUP(1), + OR_GROUP(2), + NOT_EXPRESSION(3), + FUNNEL_FILTER(4), + FUNNEL_EVENT_FILTER(5), + EXPR_NOT_SET(0); + private final int value; + + private ExprCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ExprCase valueOf(int value) { + return forNumber(value); + } + + public static ExprCase forNumber(int value) { + switch (value) { + case 1: + return AND_GROUP; + case 2: + return OR_GROUP; + case 3: + return NOT_EXPRESSION; + case 4: + return FUNNEL_FILTER; + case 5: + return FUNNEL_EVENT_FILTER; + case 0: + return EXPR_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public static final int AND_GROUP_FIELD_NUMBER = 1; + /** + * + * + *
+   * The FunnelFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+   * The FunnelFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList getAndGroup() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + /** + * + * + *
+   * The FunnelFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + + public static final int OR_GROUP_FIELD_NUMBER = 2; + /** + * + * + *
+   * The FunnelFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+   * The FunnelFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList getOrGroup() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + /** + * + * + *
+   * The FunnelFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + + public static final int NOT_EXPRESSION_FIELD_NUMBER = 3; + /** + * + * + *
+   * The FunnelFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+   * The FunnelFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression getNotExpression() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } + /** + * + * + *
+   * The FunnelFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } + + public static final int FUNNEL_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * A primitive funnel filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + * + * @return Whether the funnelFilter field is set. + */ + @java.lang.Override + public boolean hasFunnelFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+   * A primitive funnel filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + * + * @return The funnelFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilter getFunnelFilter() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A primitive funnel filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterOrBuilder getFunnelFilterOrBuilder() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } + + public static final int FUNNEL_EVENT_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * + * @return Whether the funnelEventFilter field is set. + */ + @java.lang.Override + public boolean hasFunnelEventFilter() { + return exprCase_ == 5; + } + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * + * @return The funnelEventFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilter getFunnelEventFilter() { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder + getFunnelEventFilterOrBuilder() { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } + + 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 (exprCase_ == 1) { + output.writeMessage(1, (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + output.writeMessage(2, (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + output.writeMessage(3, (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_); + } + if (exprCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.FunnelFilter) expr_); + } + if (exprCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (exprCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_); + } + if (exprCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.FunnelFilter) expr_); + } + if (exprCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelFilterExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelFilterExpression other = + (com.google.analytics.data.v1alpha.FunnelFilterExpression) obj; + + if (!getExprCase().equals(other.getExprCase())) return false; + switch (exprCase_) { + case 1: + if (!getAndGroup().equals(other.getAndGroup())) return false; + break; + case 2: + if (!getOrGroup().equals(other.getOrGroup())) return false; + break; + case 3: + if (!getNotExpression().equals(other.getNotExpression())) return false; + break; + case 4: + if (!getFunnelFilter().equals(other.getFunnelFilter())) return false; + break; + case 5: + if (!getFunnelEventFilter().equals(other.getFunnelEventFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (exprCase_) { + case 1: + hash = (37 * hash) + AND_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getAndGroup().hashCode(); + break; + case 2: + hash = (37 * hash) + OR_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getOrGroup().hashCode(); + break; + case 3: + hash = (37 * hash) + NOT_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getNotExpression().hashCode(); + break; + case 4: + hash = (37 * hash) + FUNNEL_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFunnelFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + FUNNEL_EVENT_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFunnelEventFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression 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.analytics.data.v1alpha.FunnelFilterExpression parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelFilterExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Expresses combinations of funnel filters.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelFilterExpression} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelFilterExpression) + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelFilterExpression.class, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelFilterExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + exprCase_ = 0; + expr_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression build() { + com.google.analytics.data.v1alpha.FunnelFilterExpression result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression buildPartial() { + com.google.analytics.data.v1alpha.FunnelFilterExpression result = + new com.google.analytics.data.v1alpha.FunnelFilterExpression(this); + if (exprCase_ == 1) { + if (andGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = andGroupBuilder_.build(); + } + } + if (exprCase_ == 2) { + if (orGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = orGroupBuilder_.build(); + } + } + if (exprCase_ == 3) { + if (notExpressionBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = notExpressionBuilder_.build(); + } + } + if (exprCase_ == 4) { + if (funnelFilterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = funnelFilterBuilder_.build(); + } + } + if (exprCase_ == 5) { + if (funnelEventFilterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = funnelEventFilterBuilder_.build(); + } + } + result.exprCase_ = exprCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelFilterExpression) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelFilterExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelFilterExpression other) { + if (other == com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance()) + return this; + switch (other.getExprCase()) { + case AND_GROUP: + { + mergeAndGroup(other.getAndGroup()); + break; + } + case OR_GROUP: + { + mergeOrGroup(other.getOrGroup()); + break; + } + case NOT_EXPRESSION: + { + mergeNotExpression(other.getNotExpression()); + break; + } + case FUNNEL_FILTER: + { + mergeFunnelFilter(other.getFunnelFilter()); + break; + } + case FUNNEL_EVENT_FILTER: + { + mergeFunnelEventFilter(other.getFunnelEventFilter()); + break; + } + case EXPR_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelFilterExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelFilterExpression) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public Builder clearExpr() { + exprCase_ = 0; + expr_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder> + andGroupBuilder_; + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList getAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } else { + if (exprCase_ == 1) { + return andGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + public Builder setAndGroup(com.google.analytics.data.v1alpha.FunnelFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + andGroupBuilder_.setMessage(value); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder builderForValue) { + if (andGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + andGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + public Builder mergeAndGroup( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1 + && expr_ + != com.google.analytics.data.v1alpha.FunnelFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 1) { + andGroupBuilder_.mergeFrom(value); + } else { + andGroupBuilder_.setMessage(value); + } + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + public Builder clearAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + } + andGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder + getAndGroupBuilder() { + return getAndGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if ((exprCase_ == 1) && (andGroupBuilder_ != null)) { + return andGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder> + getAndGroupFieldBuilder() { + if (andGroupBuilder_ == null) { + if (!(exprCase_ == 1)) { + expr_ = com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + andGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 1; + onChanged(); + ; + return andGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder> + orGroupBuilder_; + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList getOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } else { + if (exprCase_ == 2) { + return orGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + public Builder setOrGroup(com.google.analytics.data.v1alpha.FunnelFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + orGroupBuilder_.setMessage(value); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder builderForValue) { + if (orGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + orGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + public Builder mergeOrGroup( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2 + && expr_ + != com.google.analytics.data.v1alpha.FunnelFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 2) { + orGroupBuilder_.mergeFrom(value); + } else { + orGroupBuilder_.setMessage(value); + } + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + public Builder clearOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + } + orGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder + getOrGroupBuilder() { + return getOrGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if ((exprCase_ == 2) && (orGroupBuilder_ != null)) { + return orGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder> + getOrGroupFieldBuilder() { + if (orGroupBuilder_ == null) { + if (!(exprCase_ == 2)) { + expr_ = com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + orGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 2; + onChanged(); + ; + return orGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + notExpressionBuilder_; + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression getNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } else { + if (exprCase_ == 3) { + return notExpressionBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + notExpressionBuilder_.setMessage(value); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder builderForValue) { + if (notExpressionBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + notExpressionBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + public Builder mergeNotExpression( + com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3 + && expr_ + != com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelFilterExpression.newBuilder( + (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 3) { + notExpressionBuilder_.mergeFrom(value); + } else { + notExpressionBuilder_.setMessage(value); + } + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + public Builder clearNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + } + notExpressionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder + getNotExpressionBuilder() { + return getNotExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if ((exprCase_ == 3) && (notExpressionBuilder_ != null)) { + return notExpressionBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + getNotExpressionFieldBuilder() { + if (notExpressionBuilder_ == null) { + if (!(exprCase_ == 3)) { + expr_ = com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance(); + } + notExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelFilterExpression) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 3; + onChanged(); + ; + return notExpressionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilter, + com.google.analytics.data.v1alpha.FunnelFilter.Builder, + com.google.analytics.data.v1alpha.FunnelFilterOrBuilder> + funnelFilterBuilder_; + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + * + * @return Whether the funnelFilter field is set. + */ + @java.lang.Override + public boolean hasFunnelFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + * + * @return The funnelFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilter getFunnelFilter() { + if (funnelFilterBuilder_ == null) { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } else { + if (exprCase_ == 4) { + return funnelFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + public Builder setFunnelFilter(com.google.analytics.data.v1alpha.FunnelFilter value) { + if (funnelFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + funnelFilterBuilder_.setMessage(value); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + public Builder setFunnelFilter( + com.google.analytics.data.v1alpha.FunnelFilter.Builder builderForValue) { + if (funnelFilterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + funnelFilterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + public Builder mergeFunnelFilter(com.google.analytics.data.v1alpha.FunnelFilter value) { + if (funnelFilterBuilder_ == null) { + if (exprCase_ == 4 + && expr_ != com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelFilter.newBuilder( + (com.google.analytics.data.v1alpha.FunnelFilter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 4) { + funnelFilterBuilder_.mergeFrom(value); + } else { + funnelFilterBuilder_.setMessage(value); + } + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + public Builder clearFunnelFilter() { + if (funnelFilterBuilder_ == null) { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + } + funnelFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + public com.google.analytics.data.v1alpha.FunnelFilter.Builder getFunnelFilterBuilder() { + return getFunnelFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterOrBuilder getFunnelFilterOrBuilder() { + if ((exprCase_ == 4) && (funnelFilterBuilder_ != null)) { + return funnelFilterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive funnel filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilter, + com.google.analytics.data.v1alpha.FunnelFilter.Builder, + com.google.analytics.data.v1alpha.FunnelFilterOrBuilder> + getFunnelFilterFieldBuilder() { + if (funnelFilterBuilder_ == null) { + if (!(exprCase_ == 4)) { + expr_ = com.google.analytics.data.v1alpha.FunnelFilter.getDefaultInstance(); + } + funnelFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilter, + com.google.analytics.data.v1alpha.FunnelFilter.Builder, + com.google.analytics.data.v1alpha.FunnelFilterOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelFilter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 4; + onChanged(); + ; + return funnelFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelEventFilter, + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder, + com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder> + funnelEventFilterBuilder_; + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * + * @return Whether the funnelEventFilter field is set. + */ + @java.lang.Override + public boolean hasFunnelEventFilter() { + return exprCase_ == 5; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * + * @return The funnelEventFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilter getFunnelEventFilter() { + if (funnelEventFilterBuilder_ == null) { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } else { + if (exprCase_ == 5) { + return funnelEventFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + public Builder setFunnelEventFilter(com.google.analytics.data.v1alpha.FunnelEventFilter value) { + if (funnelEventFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + funnelEventFilterBuilder_.setMessage(value); + } + exprCase_ = 5; + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + public Builder setFunnelEventFilter( + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder builderForValue) { + if (funnelEventFilterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + funnelEventFilterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 5; + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + public Builder mergeFunnelEventFilter( + com.google.analytics.data.v1alpha.FunnelEventFilter value) { + if (funnelEventFilterBuilder_ == null) { + if (exprCase_ == 5 + && expr_ != com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelEventFilter.newBuilder( + (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 5) { + funnelEventFilterBuilder_.mergeFrom(value); + } else { + funnelEventFilterBuilder_.setMessage(value); + } + } + exprCase_ = 5; + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + public Builder clearFunnelEventFilter() { + if (funnelEventFilterBuilder_ == null) { + if (exprCase_ == 5) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 5) { + exprCase_ = 0; + expr_ = null; + } + funnelEventFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + public com.google.analytics.data.v1alpha.FunnelEventFilter.Builder + getFunnelEventFilterBuilder() { + return getFunnelEventFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder + getFunnelEventFilterOrBuilder() { + if ((exprCase_ == 5) && (funnelEventFilterBuilder_ != null)) { + return funnelEventFilterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelEventFilter, + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder, + com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder> + getFunnelEventFilterFieldBuilder() { + if (funnelEventFilterBuilder_ == null) { + if (!(exprCase_ == 5)) { + expr_ = com.google.analytics.data.v1alpha.FunnelEventFilter.getDefaultInstance(); + } + funnelEventFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelEventFilter, + com.google.analytics.data.v1alpha.FunnelEventFilter.Builder, + com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelEventFilter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 5; + onChanged(); + ; + return funnelEventFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelFilterExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelFilterExpression) + private static final com.google.analytics.data.v1alpha.FunnelFilterExpression DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelFilterExpression(); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpression getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelFilterExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelFilterExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelFilterExpression getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionList.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionList.java new file mode 100644 index 00000000..7f953c6e --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionList.java @@ -0,0 +1,976 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A list of funnel filter expressions.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelFilterExpressionList} + */ +public final class FunnelFilterExpressionList extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelFilterExpressionList) + FunnelFilterExpressionListOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelFilterExpressionList.newBuilder() to construct. + private FunnelFilterExpressionList(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelFilterExpressionList() { + expressions_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelFilterExpressionList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelFilterExpressionList( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.FunnelFilterExpression>(); + mutable_bitField0_ |= 0x00000001; + } + expressions_.add( + input.readMessage( + com.google.analytics.data.v1alpha.FunnelFilterExpression.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.class, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder.class); + } + + public static final int EXPRESSIONS_FIELD_NUMBER = 1; + private java.util.List expressions_; + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + @java.lang.Override + public java.util.List + getExpressionsList() { + return expressions_; + } + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + @java.lang.Override + public java.util.List + getExpressionsOrBuilderList() { + return expressions_; + } + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + @java.lang.Override + public int getExpressionsCount() { + return expressions_.size(); + } + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression getExpressions(int index) { + return expressions_.get(index); + } + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder getExpressionsOrBuilder( + int index) { + return expressions_.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 < expressions_.size(); i++) { + output.writeMessage(1, expressions_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < expressions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, expressions_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelFilterExpressionList)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelFilterExpressionList other = + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) obj; + + if (!getExpressionsList().equals(other.getExpressionsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExpressionsCount() > 0) { + hash = (37 * hash) + EXPRESSIONS_FIELD_NUMBER; + hash = (53 * hash) + getExpressionsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList 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.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelFilterExpressionList 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A list of funnel filter expressions.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelFilterExpressionList} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelFilterExpressionList) + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.class, + com.google.analytics.data.v1alpha.FunnelFilterExpressionList.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelFilterExpressionList.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExpressionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + expressionsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList build() { + com.google.analytics.data.v1alpha.FunnelFilterExpressionList result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionList buildPartial() { + com.google.analytics.data.v1alpha.FunnelFilterExpressionList result = + new com.google.analytics.data.v1alpha.FunnelFilterExpressionList(this); + int from_bitField0_ = bitField0_; + if (expressionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.expressions_ = expressions_; + } else { + result.expressions_ = expressionsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelFilterExpressionList) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelFilterExpressionList) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelFilterExpressionList other) { + if (other + == com.google.analytics.data.v1alpha.FunnelFilterExpressionList.getDefaultInstance()) + return this; + if (expressionsBuilder_ == null) { + if (!other.expressions_.isEmpty()) { + if (expressions_.isEmpty()) { + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExpressionsIsMutable(); + expressions_.addAll(other.expressions_); + } + onChanged(); + } + } else { + if (!other.expressions_.isEmpty()) { + if (expressionsBuilder_.isEmpty()) { + expressionsBuilder_.dispose(); + expressionsBuilder_ = null; + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + expressionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExpressionsFieldBuilder() + : null; + } else { + expressionsBuilder_.addAllMessages(other.expressions_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelFilterExpressionList parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelFilterExpressionList) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List expressions_ = + java.util.Collections.emptyList(); + + private void ensureExpressionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList( + expressions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + expressionsBuilder_; + + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public java.util.List + getExpressionsList() { + if (expressionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(expressions_); + } else { + return expressionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public int getExpressionsCount() { + if (expressionsBuilder_ == null) { + return expressions_.size(); + } else { + return expressionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression getExpressions(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder setExpressions( + int index, com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.set(index, value); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder setExpressions( + int index, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.set(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder addExpressions(com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(value); + onChanged(); + } else { + expressionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder addExpressions( + int index, com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(index, value); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder addExpressions( + int index, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder addAllExpressions( + java.lang.Iterable + values) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, expressions_); + onChanged(); + } else { + expressionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder clearExpressions() { + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + expressionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public Builder removeExpressions(int index) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.remove(index); + onChanged(); + } else { + expressionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder getExpressionsBuilder( + int index) { + return getExpressionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder + getExpressionsOrBuilder(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + if (expressionsBuilder_ != null) { + return expressionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(expressions_); + } + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder + addExpressionsBuilder() { + return getExpressionsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance()); + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder addExpressionsBuilder( + int index) { + return getExpressionsFieldBuilder() + .addBuilder( + index, com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance()); + } + /** + * + * + *
+     * The list of funnel filter expressions.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + public java.util.List + getExpressionsBuilderList() { + return getExpressionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + getExpressionsFieldBuilder() { + if (expressionsBuilder_ == null) { + expressionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder>( + expressions_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + expressions_ = null; + } + return expressionsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelFilterExpressionList) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelFilterExpressionList) + private static final com.google.analytics.data.v1alpha.FunnelFilterExpressionList + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelFilterExpressionList(); + } + + public static com.google.analytics.data.v1alpha.FunnelFilterExpressionList getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelFilterExpressionList parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelFilterExpressionList(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelFilterExpressionList getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionListOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionListOrBuilder.java new file mode 100644 index 00000000..d3a24d6d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionListOrBuilder.java @@ -0,0 +1,78 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelFilterExpressionListOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelFilterExpressionList) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + java.util.List getExpressionsList(); + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + com.google.analytics.data.v1alpha.FunnelFilterExpression getExpressions(int index); + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + int getExpressionsCount(); + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + java.util.List + getExpressionsOrBuilderList(); + /** + * + * + *
+   * The list of funnel filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder getExpressionsOrBuilder( + int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionOrBuilder.java new file mode 100644 index 00000000..b731f681 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterExpressionOrBuilder.java @@ -0,0 +1,211 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelFilterExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelFilterExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The FunnelFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + boolean hasAndGroup(); + /** + * + * + *
+   * The FunnelFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionList getAndGroup(); + /** + * + * + *
+   * The FunnelFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder getAndGroupOrBuilder(); + + /** + * + * + *
+   * The FunnelFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + boolean hasOrGroup(); + /** + * + * + *
+   * The FunnelFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionList getOrGroup(); + /** + * + * + *
+   * The FunnelFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionListOrBuilder getOrGroupOrBuilder(); + + /** + * + * + *
+   * The FunnelFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + boolean hasNotExpression(); + /** + * + * + *
+   * The FunnelFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + com.google.analytics.data.v1alpha.FunnelFilterExpression getNotExpression(); + /** + * + * + *
+   * The FunnelFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder getNotExpressionOrBuilder(); + + /** + * + * + *
+   * A primitive funnel filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + * + * @return Whether the funnelFilter field is set. + */ + boolean hasFunnelFilter(); + /** + * + * + *
+   * A primitive funnel filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + * + * @return The funnelFilter. + */ + com.google.analytics.data.v1alpha.FunnelFilter getFunnelFilter(); + /** + * + * + *
+   * A primitive funnel filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilter funnel_filter = 4; + */ + com.google.analytics.data.v1alpha.FunnelFilterOrBuilder getFunnelFilterOrBuilder(); + + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * + * @return Whether the funnelEventFilter field is set. + */ + boolean hasFunnelEventFilter(); + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * + * @return The funnelEventFilter. + */ + com.google.analytics.data.v1alpha.FunnelEventFilter getFunnelEventFilter(); + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + */ + com.google.analytics.data.v1alpha.FunnelEventFilterOrBuilder getFunnelEventFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.FunnelFilterExpression.ExprCase getExprCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterOrBuilder.java new file mode 100644 index 00000000..003dbe0c --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelFilterOrBuilder.java @@ -0,0 +1,192 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + java.lang.String getFieldName(); + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + com.google.protobuf.ByteString getFieldNameBytes(); + + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + boolean hasStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + com.google.analytics.data.v1alpha.StringFilter getStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder(); + + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + boolean hasInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + com.google.analytics.data.v1alpha.InListFilter getInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder(); + + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + boolean hasNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + com.google.analytics.data.v1alpha.NumericFilter getNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder(); + + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + boolean hasBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.FunnelFilter.OneFilterCase getOneFilterCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextAction.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextAction.java new file mode 100644 index 00000000..75f16313 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextAction.java @@ -0,0 +1,930 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Next actions state the value for a dimension after the user has achieved
+ * a step but before the same user has achieved the next step. For example if
+ * the `nextActionDimension` is `eventName`, then `nextActionDimension` in the
+ * `i`th funnel step row will return first event after the event that qualified
+ * the user into the `i`th funnel step but before the user achieved the `i+1`th
+ * funnel step.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelNextAction} + */ +public final class FunnelNextAction extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelNextAction) + FunnelNextActionOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelNextAction.newBuilder() to construct. + private FunnelNextAction(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelNextAction() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelNextAction(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelNextAction( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.Dimension.Builder subBuilder = null; + if (nextActionDimension_ != null) { + subBuilder = nextActionDimension_.toBuilder(); + } + nextActionDimension_ = + input.readMessage( + com.google.analytics.data.v1alpha.Dimension.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(nextActionDimension_); + nextActionDimension_ = subBuilder.buildPartial(); + } + + break; + } + case 16: + { + bitField0_ |= 0x00000001; + limit_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelNextAction_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelNextAction_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelNextAction.class, + com.google.analytics.data.v1alpha.FunnelNextAction.Builder.class); + } + + private int bitField0_; + public static final int NEXT_ACTION_DIMENSION_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.Dimension nextActionDimension_; + /** + * + * + *
+   * The dimension column added to the funnel visualization sub report response.
+   * The next action dimension returns the next dimension value of this
+   * dimension after the user has attained the `i`th funnel step.
+   * `nextActionDimension` currently only supports the `eventName` dimension.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * + * @return Whether the nextActionDimension field is set. + */ + @java.lang.Override + public boolean hasNextActionDimension() { + return nextActionDimension_ != null; + } + /** + * + * + *
+   * The dimension column added to the funnel visualization sub report response.
+   * The next action dimension returns the next dimension value of this
+   * dimension after the user has attained the `i`th funnel step.
+   * `nextActionDimension` currently only supports the `eventName` dimension.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * + * @return The nextActionDimension. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Dimension getNextActionDimension() { + return nextActionDimension_ == null + ? com.google.analytics.data.v1alpha.Dimension.getDefaultInstance() + : nextActionDimension_; + } + /** + * + * + *
+   * The dimension column added to the funnel visualization sub report response.
+   * The next action dimension returns the next dimension value of this
+   * dimension after the user has attained the `i`th funnel step.
+   * `nextActionDimension` currently only supports the `eventName` dimension.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionOrBuilder getNextActionDimensionOrBuilder() { + return getNextActionDimension(); + } + + public static final int LIMIT_FIELD_NUMBER = 2; + private long limit_; + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 5.
+   * 
+ * + * optional int64 limit = 2; + * + * @return Whether the limit field is set. + */ + @java.lang.Override + public boolean hasLimit() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 5.
+   * 
+ * + * optional int64 limit = 2; + * + * @return The limit. + */ + @java.lang.Override + public long getLimit() { + return limit_; + } + + 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 (nextActionDimension_ != null) { + output.writeMessage(1, getNextActionDimension()); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeInt64(2, limit_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (nextActionDimension_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getNextActionDimension()); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, limit_); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelNextAction)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelNextAction other = + (com.google.analytics.data.v1alpha.FunnelNextAction) obj; + + if (hasNextActionDimension() != other.hasNextActionDimension()) return false; + if (hasNextActionDimension()) { + if (!getNextActionDimension().equals(other.getNextActionDimension())) return false; + } + if (hasLimit() != other.hasLimit()) return false; + if (hasLimit()) { + if (getLimit() != other.getLimit()) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasNextActionDimension()) { + hash = (37 * hash) + NEXT_ACTION_DIMENSION_FIELD_NUMBER; + hash = (53 * hash) + getNextActionDimension().hashCode(); + } + if (hasLimit()) { + hash = (37 * hash) + LIMIT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getLimit()); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction 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.analytics.data.v1alpha.FunnelNextAction parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelNextAction 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Next actions state the value for a dimension after the user has achieved
+   * a step but before the same user has achieved the next step. For example if
+   * the `nextActionDimension` is `eventName`, then `nextActionDimension` in the
+   * `i`th funnel step row will return first event after the event that qualified
+   * the user into the `i`th funnel step but before the user achieved the `i+1`th
+   * funnel step.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelNextAction} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelNextAction) + com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelNextAction_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelNextAction_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelNextAction.class, + com.google.analytics.data.v1alpha.FunnelNextAction.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelNextAction.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (nextActionDimensionBuilder_ == null) { + nextActionDimension_ = null; + } else { + nextActionDimension_ = null; + nextActionDimensionBuilder_ = null; + } + limit_ = 0L; + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelNextAction_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelNextAction getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelNextAction.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelNextAction build() { + com.google.analytics.data.v1alpha.FunnelNextAction result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelNextAction buildPartial() { + com.google.analytics.data.v1alpha.FunnelNextAction result = + new com.google.analytics.data.v1alpha.FunnelNextAction(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (nextActionDimensionBuilder_ == null) { + result.nextActionDimension_ = nextActionDimension_; + } else { + result.nextActionDimension_ = nextActionDimensionBuilder_.build(); + } + if (((from_bitField0_ & 0x00000001) != 0)) { + result.limit_ = limit_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelNextAction) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelNextAction) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelNextAction other) { + if (other == com.google.analytics.data.v1alpha.FunnelNextAction.getDefaultInstance()) + return this; + if (other.hasNextActionDimension()) { + mergeNextActionDimension(other.getNextActionDimension()); + } + if (other.hasLimit()) { + setLimit(other.getLimit()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelNextAction parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelNextAction) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.analytics.data.v1alpha.Dimension nextActionDimension_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Dimension, + com.google.analytics.data.v1alpha.Dimension.Builder, + com.google.analytics.data.v1alpha.DimensionOrBuilder> + nextActionDimensionBuilder_; + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * + * @return Whether the nextActionDimension field is set. + */ + public boolean hasNextActionDimension() { + return nextActionDimensionBuilder_ != null || nextActionDimension_ != null; + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * + * @return The nextActionDimension. + */ + public com.google.analytics.data.v1alpha.Dimension getNextActionDimension() { + if (nextActionDimensionBuilder_ == null) { + return nextActionDimension_ == null + ? com.google.analytics.data.v1alpha.Dimension.getDefaultInstance() + : nextActionDimension_; + } else { + return nextActionDimensionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + public Builder setNextActionDimension(com.google.analytics.data.v1alpha.Dimension value) { + if (nextActionDimensionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + nextActionDimension_ = value; + onChanged(); + } else { + nextActionDimensionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + public Builder setNextActionDimension( + com.google.analytics.data.v1alpha.Dimension.Builder builderForValue) { + if (nextActionDimensionBuilder_ == null) { + nextActionDimension_ = builderForValue.build(); + onChanged(); + } else { + nextActionDimensionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + public Builder mergeNextActionDimension(com.google.analytics.data.v1alpha.Dimension value) { + if (nextActionDimensionBuilder_ == null) { + if (nextActionDimension_ != null) { + nextActionDimension_ = + com.google.analytics.data.v1alpha.Dimension.newBuilder(nextActionDimension_) + .mergeFrom(value) + .buildPartial(); + } else { + nextActionDimension_ = value; + } + onChanged(); + } else { + nextActionDimensionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + public Builder clearNextActionDimension() { + if (nextActionDimensionBuilder_ == null) { + nextActionDimension_ = null; + onChanged(); + } else { + nextActionDimension_ = null; + nextActionDimensionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + public com.google.analytics.data.v1alpha.Dimension.Builder getNextActionDimensionBuilder() { + + onChanged(); + return getNextActionDimensionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + public com.google.analytics.data.v1alpha.DimensionOrBuilder getNextActionDimensionOrBuilder() { + if (nextActionDimensionBuilder_ != null) { + return nextActionDimensionBuilder_.getMessageOrBuilder(); + } else { + return nextActionDimension_ == null + ? com.google.analytics.data.v1alpha.Dimension.getDefaultInstance() + : nextActionDimension_; + } + } + /** + * + * + *
+     * The dimension column added to the funnel visualization sub report response.
+     * The next action dimension returns the next dimension value of this
+     * dimension after the user has attained the `i`th funnel step.
+     * `nextActionDimension` currently only supports the `eventName` dimension.
+     * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Dimension, + com.google.analytics.data.v1alpha.Dimension.Builder, + com.google.analytics.data.v1alpha.DimensionOrBuilder> + getNextActionDimensionFieldBuilder() { + if (nextActionDimensionBuilder_ == null) { + nextActionDimensionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Dimension, + com.google.analytics.data.v1alpha.Dimension.Builder, + com.google.analytics.data.v1alpha.DimensionOrBuilder>( + getNextActionDimension(), getParentForChildren(), isClean()); + nextActionDimension_ = null; + } + return nextActionDimensionBuilder_; + } + + private long limit_; + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 5.
+     * 
+ * + * optional int64 limit = 2; + * + * @return Whether the limit field is set. + */ + @java.lang.Override + public boolean hasLimit() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 5.
+     * 
+ * + * optional int64 limit = 2; + * + * @return The limit. + */ + @java.lang.Override + public long getLimit() { + return limit_; + } + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 5.
+     * 
+ * + * optional int64 limit = 2; + * + * @param value The limit to set. + * @return This builder for chaining. + */ + public Builder setLimit(long value) { + bitField0_ |= 0x00000001; + limit_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of distinct values of the breakdown dimension to return
+     * in the response. A `limit` of `5` is used if limit is not specified. Limit
+     * must exceed zero and cannot exceed 5.
+     * 
+ * + * optional int64 limit = 2; + * + * @return This builder for chaining. + */ + public Builder clearLimit() { + bitField0_ = (bitField0_ & ~0x00000001); + limit_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelNextAction) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelNextAction) + private static final com.google.analytics.data.v1alpha.FunnelNextAction DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelNextAction(); + } + + public static com.google.analytics.data.v1alpha.FunnelNextAction getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelNextAction parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelNextAction(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelNextAction getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextActionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextActionOrBuilder.java new file mode 100644 index 00000000..398dd665 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelNextActionOrBuilder.java @@ -0,0 +1,98 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelNextActionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelNextAction) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The dimension column added to the funnel visualization sub report response.
+   * The next action dimension returns the next dimension value of this
+   * dimension after the user has attained the `i`th funnel step.
+   * `nextActionDimension` currently only supports the `eventName` dimension.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * + * @return Whether the nextActionDimension field is set. + */ + boolean hasNextActionDimension(); + /** + * + * + *
+   * The dimension column added to the funnel visualization sub report response.
+   * The next action dimension returns the next dimension value of this
+   * dimension after the user has attained the `i`th funnel step.
+   * `nextActionDimension` currently only supports the `eventName` dimension.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * + * @return The nextActionDimension. + */ + com.google.analytics.data.v1alpha.Dimension getNextActionDimension(); + /** + * + * + *
+   * The dimension column added to the funnel visualization sub report response.
+   * The next action dimension returns the next dimension value of this
+   * dimension after the user has attained the `i`th funnel step.
+   * `nextActionDimension` currently only supports the `eventName` dimension.
+   * 
+ * + * .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + com.google.analytics.data.v1alpha.DimensionOrBuilder getNextActionDimensionOrBuilder(); + + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 5.
+   * 
+ * + * optional int64 limit = 2; + * + * @return Whether the limit field is set. + */ + boolean hasLimit(); + /** + * + * + *
+   * The maximum number of distinct values of the breakdown dimension to return
+   * in the response. A `limit` of `5` is used if limit is not specified. Limit
+   * must exceed zero and cannot exceed 5.
+   * 
+ * + * optional int64 limit = 2; + * + * @return The limit. + */ + long getLimit(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelOrBuilder.java new file mode 100644 index 00000000..5cc16096 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelOrBuilder.java @@ -0,0 +1,92 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.Funnel) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * In an open funnel, users can enter the funnel in any step, and in a closed
+   * funnel, users must enter the funnel in the first step. Optional. If
+   * unspecified, a closed funnel is used.
+   * 
+ * + * bool is_open_funnel = 1; + * + * @return The isOpenFunnel. + */ + boolean getIsOpenFunnel(); + + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + java.util.List getStepsList(); + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + com.google.analytics.data.v1alpha.FunnelStep getSteps(int index); + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + int getStepsCount(); + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + java.util.List + getStepsOrBuilderList(); + /** + * + * + *
+   * The sequential steps of this funnel.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + com.google.analytics.data.v1alpha.FunnelStepOrBuilder getStepsOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilter.java new file mode 100644 index 00000000..51fc8320 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilter.java @@ -0,0 +1,2437 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * An expression to filter parameter values in a funnel.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelParameterFilter} + */ +public final class FunnelParameterFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelParameterFilter) + FunnelParameterFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelParameterFilter.newBuilder() to construct. + private FunnelParameterFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelParameterFilter() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelParameterFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelParameterFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + oneParameterCase_ = 1; + oneParameter_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + oneParameterCase_ = 2; + oneParameter_ = s; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.StringFilter.Builder subBuilder = null; + if (oneFilterCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.StringFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.StringFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.InListFilter.Builder subBuilder = null; + if (oneFilterCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.InListFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.InListFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 5; + break; + } + case 50: + { + com.google.analytics.data.v1alpha.NumericFilter.Builder subBuilder = null; + if (oneFilterCase_ == 6) { + subBuilder = + ((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 6; + break; + } + case 58: + { + com.google.analytics.data.v1alpha.BetweenFilter.Builder subBuilder = null; + if (oneFilterCase_ == 7) { + subBuilder = + ((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.BetweenFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 7; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelParameterFilter.class, + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder.class); + } + + private int oneParameterCase_ = 0; + private java.lang.Object oneParameter_; + + public enum OneParameterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + EVENT_PARAMETER_NAME(1), + ITEM_PARAMETER_NAME(2), + ONEPARAMETER_NOT_SET(0); + private final int value; + + private OneParameterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneParameterCase valueOf(int value) { + return forNumber(value); + } + + public static OneParameterCase forNumber(int value) { + switch (value) { + case 1: + return EVENT_PARAMETER_NAME; + case 2: + return ITEM_PARAMETER_NAME; + case 0: + return ONEPARAMETER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneParameterCase getOneParameterCase() { + return OneParameterCase.forNumber(oneParameterCase_); + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public enum OneFilterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + STRING_FILTER(4), + IN_LIST_FILTER(5), + NUMERIC_FILTER(6), + BETWEEN_FILTER(7), + ONEFILTER_NOT_SET(0); + private final int value; + + private OneFilterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneFilterCase valueOf(int value) { + return forNumber(value); + } + + public static OneFilterCase forNumber(int value) { + switch (value) { + case 4: + return STRING_FILTER; + case 5: + return IN_LIST_FILTER; + case 6: + return NUMERIC_FILTER; + case 7: + return BETWEEN_FILTER; + case 0: + return ONEFILTER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public static final int EVENT_PARAMETER_NAME_FIELD_NUMBER = 1; + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return Whether the eventParameterName field is set. + */ + public boolean hasEventParameterName() { + return oneParameterCase_ == 1; + } + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The eventParameterName. + */ + public java.lang.String getEventParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + 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(); + if (oneParameterCase_ == 1) { + oneParameter_ = s; + } + return s; + } + } + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The bytes for eventParameterName. + */ + public com.google.protobuf.ByteString getEventParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 1) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ITEM_PARAMETER_NAME_FIELD_NUMBER = 2; + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return Whether the itemParameterName field is set. + */ + public boolean hasItemParameterName() { + return oneParameterCase_ == 2; + } + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The itemParameterName. + */ + public java.lang.String getItemParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + 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(); + if (oneParameterCase_ == 2) { + oneParameter_ = s; + } + return s; + } + } + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The bytes for itemParameterName. + */ + public com.google.protobuf.ByteString getItemParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 2) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STRING_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + + public static final int IN_LIST_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + + public static final int NUMERIC_FILTER_FIELD_NUMBER = 6; + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + + public static final int BETWEEN_FILTER_FIELD_NUMBER = 7; + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + + 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 (oneParameterCase_ == 1) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, oneParameter_); + } + if (oneParameterCase_ == 2) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, oneParameter_); + } + if (oneFilterCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + output.writeMessage(6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + output.writeMessage(7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (oneParameterCase_ == 1) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, oneParameter_); + } + if (oneParameterCase_ == 2) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, oneParameter_); + } + if (oneFilterCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelParameterFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelParameterFilter other = + (com.google.analytics.data.v1alpha.FunnelParameterFilter) obj; + + if (!getOneParameterCase().equals(other.getOneParameterCase())) return false; + switch (oneParameterCase_) { + case 1: + if (!getEventParameterName().equals(other.getEventParameterName())) return false; + break; + case 2: + if (!getItemParameterName().equals(other.getItemParameterName())) return false; + break; + case 0: + default: + } + if (!getOneFilterCase().equals(other.getOneFilterCase())) return false; + switch (oneFilterCase_) { + case 4: + if (!getStringFilter().equals(other.getStringFilter())) return false; + break; + case 5: + if (!getInListFilter().equals(other.getInListFilter())) return false; + break; + case 6: + if (!getNumericFilter().equals(other.getNumericFilter())) return false; + break; + case 7: + if (!getBetweenFilter().equals(other.getBetweenFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (oneParameterCase_) { + case 1: + hash = (37 * hash) + EVENT_PARAMETER_NAME_FIELD_NUMBER; + hash = (53 * hash) + getEventParameterName().hashCode(); + break; + case 2: + hash = (37 * hash) + ITEM_PARAMETER_NAME_FIELD_NUMBER; + hash = (53 * hash) + getItemParameterName().hashCode(); + break; + case 0: + default: + } + switch (oneFilterCase_) { + case 4: + hash = (37 * hash) + STRING_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getStringFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + IN_LIST_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getInListFilter().hashCode(); + break; + case 6: + hash = (37 * hash) + NUMERIC_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getNumericFilter().hashCode(); + break; + case 7: + hash = (37 * hash) + BETWEEN_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getBetweenFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter 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.analytics.data.v1alpha.FunnelParameterFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelParameterFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * An expression to filter parameter values in a funnel.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelParameterFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelParameterFilter) + com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelParameterFilter.class, + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelParameterFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + oneParameterCase_ = 0; + oneParameter_ = null; + oneFilterCase_ = 0; + oneFilter_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilter build() { + com.google.analytics.data.v1alpha.FunnelParameterFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilter buildPartial() { + com.google.analytics.data.v1alpha.FunnelParameterFilter result = + new com.google.analytics.data.v1alpha.FunnelParameterFilter(this); + if (oneParameterCase_ == 1) { + result.oneParameter_ = oneParameter_; + } + if (oneParameterCase_ == 2) { + result.oneParameter_ = oneParameter_; + } + if (oneFilterCase_ == 4) { + if (stringFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = stringFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 5) { + if (inListFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = inListFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 6) { + if (numericFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = numericFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 7) { + if (betweenFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = betweenFilterBuilder_.build(); + } + } + result.oneParameterCase_ = oneParameterCase_; + result.oneFilterCase_ = oneFilterCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelParameterFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelParameterFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelParameterFilter other) { + if (other == com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance()) + return this; + switch (other.getOneParameterCase()) { + case EVENT_PARAMETER_NAME: + { + oneParameterCase_ = 1; + oneParameter_ = other.oneParameter_; + onChanged(); + break; + } + case ITEM_PARAMETER_NAME: + { + oneParameterCase_ = 2; + oneParameter_ = other.oneParameter_; + onChanged(); + break; + } + case ONEPARAMETER_NOT_SET: + { + break; + } + } + switch (other.getOneFilterCase()) { + case STRING_FILTER: + { + mergeStringFilter(other.getStringFilter()); + break; + } + case IN_LIST_FILTER: + { + mergeInListFilter(other.getInListFilter()); + break; + } + case NUMERIC_FILTER: + { + mergeNumericFilter(other.getNumericFilter()); + break; + } + case BETWEEN_FILTER: + { + mergeBetweenFilter(other.getBetweenFilter()); + break; + } + case ONEFILTER_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelParameterFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelParameterFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneParameterCase_ = 0; + private java.lang.Object oneParameter_; + + public OneParameterCase getOneParameterCase() { + return OneParameterCase.forNumber(oneParameterCase_); + } + + public Builder clearOneParameter() { + oneParameterCase_ = 0; + oneParameter_ = null; + onChanged(); + return this; + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public Builder clearOneFilter() { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + return this; + } + + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return Whether the eventParameterName field is set. + */ + @java.lang.Override + public boolean hasEventParameterName() { + return oneParameterCase_ == 1; + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return The eventParameterName. + */ + @java.lang.Override + public java.lang.String getEventParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (oneParameterCase_ == 1) { + oneParameter_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return The bytes for eventParameterName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEventParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 1) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @param value The eventParameterName to set. + * @return This builder for chaining. + */ + public Builder setEventParameterName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + oneParameterCase_ = 1; + oneParameter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearEventParameterName() { + if (oneParameterCase_ == 1) { + oneParameterCase_ = 0; + oneParameter_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @param value The bytes for eventParameterName to set. + * @return This builder for chaining. + */ + public Builder setEventParameterNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + oneParameterCase_ = 1; + oneParameter_ = value; + onChanged(); + return this; + } + + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return Whether the itemParameterName field is set. + */ + @java.lang.Override + public boolean hasItemParameterName() { + return oneParameterCase_ == 2; + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return The itemParameterName. + */ + @java.lang.Override + public java.lang.String getItemParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (oneParameterCase_ == 2) { + oneParameter_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return The bytes for itemParameterName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getItemParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 2) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @param value The itemParameterName to set. + * @return This builder for chaining. + */ + public Builder setItemParameterName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + oneParameterCase_ = 2; + oneParameter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearItemParameterName() { + if (oneParameterCase_ == 2) { + oneParameterCase_ = 0; + oneParameter_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @param value The bytes for itemParameterName to set. + * @return This builder for chaining. + */ + public Builder setItemParameterNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + oneParameterCase_ = 2; + oneParameter_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + stringFilterBuilder_; + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 4) { + return stringFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + stringFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter( + com.google.analytics.data.v1alpha.StringFilter.Builder builderForValue) { + if (stringFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + stringFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder mergeStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4 + && oneFilter_ != com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.StringFilter.newBuilder( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 4) { + stringFilterBuilder_.mergeFrom(value); + } else { + stringFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder clearStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + stringFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public com.google.analytics.data.v1alpha.StringFilter.Builder getStringFilterBuilder() { + return getStringFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if ((oneFilterCase_ == 4) && (stringFilterBuilder_ != null)) { + return stringFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + getStringFilterFieldBuilder() { + if (stringFilterBuilder_ == null) { + if (!(oneFilterCase_ == 4)) { + oneFilter_ = com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + stringFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder>( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 4; + onChanged(); + ; + return stringFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + inListFilterBuilder_; + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 5) { + return inListFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + inListFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter( + com.google.analytics.data.v1alpha.InListFilter.Builder builderForValue) { + if (inListFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + inListFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder mergeInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5 + && oneFilter_ != com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.InListFilter.newBuilder( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 5) { + inListFilterBuilder_.mergeFrom(value); + } else { + inListFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder clearInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + inListFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public com.google.analytics.data.v1alpha.InListFilter.Builder getInListFilterBuilder() { + return getInListFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if ((oneFilterCase_ == 5) && (inListFilterBuilder_ != null)) { + return inListFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + getInListFilterFieldBuilder() { + if (inListFilterBuilder_ == null) { + if (!(oneFilterCase_ == 5)) { + oneFilter_ = com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + inListFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder>( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 5; + onChanged(); + ; + return inListFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + numericFilterBuilder_; + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 6) { + return numericFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + numericFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter( + com.google.analytics.data.v1alpha.NumericFilter.Builder builderForValue) { + if (numericFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + numericFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder mergeNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6 + && oneFilter_ != com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.NumericFilter.newBuilder( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 6) { + numericFilterBuilder_.mergeFrom(value); + } else { + numericFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder clearNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + numericFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public com.google.analytics.data.v1alpha.NumericFilter.Builder getNumericFilterBuilder() { + return getNumericFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if ((oneFilterCase_ == 6) && (numericFilterBuilder_ != null)) { + return numericFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + getNumericFilterFieldBuilder() { + if (numericFilterBuilder_ == null) { + if (!(oneFilterCase_ == 6)) { + oneFilter_ = com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + numericFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder>( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 6; + onChanged(); + ; + return numericFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + betweenFilterBuilder_; + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 7) { + return betweenFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + betweenFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter( + com.google.analytics.data.v1alpha.BetweenFilter.Builder builderForValue) { + if (betweenFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + betweenFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder mergeBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7 + && oneFilter_ != com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.BetweenFilter.newBuilder( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 7) { + betweenFilterBuilder_.mergeFrom(value); + } else { + betweenFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder clearBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + betweenFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public com.google.analytics.data.v1alpha.BetweenFilter.Builder getBetweenFilterBuilder() { + return getBetweenFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if ((oneFilterCase_ == 7) && (betweenFilterBuilder_ != null)) { + return betweenFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + getBetweenFilterFieldBuilder() { + if (betweenFilterBuilder_ == null) { + if (!(oneFilterCase_ == 7)) { + oneFilter_ = com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + betweenFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder>( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 7; + onChanged(); + ; + return betweenFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelParameterFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelParameterFilter) + private static final com.google.analytics.data.v1alpha.FunnelParameterFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelParameterFilter(); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelParameterFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelParameterFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelParameterFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpression.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpression.java new file mode 100644 index 00000000..8ac838fb --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpression.java @@ -0,0 +1,1892 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Expresses combinations of funnel filters on parameters.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelParameterFilterExpression} + */ +public final class FunnelParameterFilterExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelParameterFilterExpression) + FunnelParameterFilterExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelParameterFilterExpression.newBuilder() to construct. + private FunnelParameterFilterExpression( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelParameterFilterExpression() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelParameterFilterExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelParameterFilterExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder + subBuilder = null; + if (exprCase_ == 1) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 1; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder + subBuilder = null; + if (exprCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder subBuilder = + null; + if (exprCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder subBuilder = null; + if (exprCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelParameterFilter.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 4; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.class, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder.class); + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public enum ExprCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AND_GROUP(1), + OR_GROUP(2), + NOT_EXPRESSION(3), + FUNNEL_PARAMETER_FILTER(4), + EXPR_NOT_SET(0); + private final int value; + + private ExprCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ExprCase valueOf(int value) { + return forNumber(value); + } + + public static ExprCase forNumber(int value) { + switch (value) { + case 1: + return AND_GROUP; + case 2: + return OR_GROUP; + case 3: + return NOT_EXPRESSION; + case 4: + return FUNNEL_PARAMETER_FILTER; + case 0: + return EXPR_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public static final int AND_GROUP_FIELD_NUMBER = 1; + /** + * + * + *
+   * The FunnelParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+   * The FunnelParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList getAndGroup() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + /** + * + * + *
+   * The FunnelParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + + public static final int OR_GROUP_FIELD_NUMBER = 2; + /** + * + * + *
+   * The FunnelParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+   * The FunnelParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList getOrGroup() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + /** + * + * + *
+   * The FunnelParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + + public static final int NOT_EXPRESSION_FIELD_NUMBER = 3; + /** + * + * + *
+   * The FunnelParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+   * The FunnelParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression getNotExpression() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance(); + } + /** + * + * + *
+   * The FunnelParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance(); + } + + public static final int FUNNEL_PARAMETER_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * A primitive funnel parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + * @return Whether the funnelParameterFilter field is set. + */ + @java.lang.Override + public boolean hasFunnelParameterFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+   * A primitive funnel parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + * @return The funnelParameterFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilter getFunnelParameterFilter() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A primitive funnel parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder + getFunnelParameterFilterOrBuilder() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } + + 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 (exprCase_ == 1) { + output.writeMessage( + 1, (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + output.writeMessage( + 2, (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + output.writeMessage( + 3, (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_); + } + if (exprCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (exprCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_); + } + if (exprCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelParameterFilterExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression other = + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) obj; + + if (!getExprCase().equals(other.getExprCase())) return false; + switch (exprCase_) { + case 1: + if (!getAndGroup().equals(other.getAndGroup())) return false; + break; + case 2: + if (!getOrGroup().equals(other.getOrGroup())) return false; + break; + case 3: + if (!getNotExpression().equals(other.getNotExpression())) return false; + break; + case 4: + if (!getFunnelParameterFilter().equals(other.getFunnelParameterFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (exprCase_) { + case 1: + hash = (37 * hash) + AND_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getAndGroup().hashCode(); + break; + case 2: + hash = (37 * hash) + OR_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getOrGroup().hashCode(); + break; + case 3: + hash = (37 * hash) + NOT_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getNotExpression().hashCode(); + break; + case 4: + hash = (37 * hash) + FUNNEL_PARAMETER_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFunnelParameterFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression 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.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelParameterFilterExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Expresses combinations of funnel filters on parameters.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelParameterFilterExpression} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelParameterFilterExpression) + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.class, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder.class); + } + + // Construct using + // com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + exprCase_ = 0; + expr_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression build() { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression buildPartial() { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression result = + new com.google.analytics.data.v1alpha.FunnelParameterFilterExpression(this); + if (exprCase_ == 1) { + if (andGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = andGroupBuilder_.build(); + } + } + if (exprCase_ == 2) { + if (orGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = orGroupBuilder_.build(); + } + } + if (exprCase_ == 3) { + if (notExpressionBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = notExpressionBuilder_.build(); + } + } + if (exprCase_ == 4) { + if (funnelParameterFilterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = funnelParameterFilterBuilder_.build(); + } + } + result.exprCase_ = exprCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression other) { + if (other + == com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.getDefaultInstance()) + return this; + switch (other.getExprCase()) { + case AND_GROUP: + { + mergeAndGroup(other.getAndGroup()); + break; + } + case OR_GROUP: + { + mergeOrGroup(other.getOrGroup()); + break; + } + case NOT_EXPRESSION: + { + mergeNotExpression(other.getNotExpression()); + break; + } + case FUNNEL_PARAMETER_FILTER: + { + mergeFunnelParameterFilter(other.getFunnelParameterFilter()); + break; + } + case EXPR_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public Builder clearExpr() { + exprCase_ = 0; + expr_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder> + andGroupBuilder_; + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList getAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } else { + if (exprCase_ == 1) { + return andGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + andGroupBuilder_.setMessage(value); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder + builderForValue) { + if (andGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + andGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + public Builder mergeAndGroup( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1 + && expr_ + != com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 1) { + andGroupBuilder_.mergeFrom(value); + } else { + andGroupBuilder_.setMessage(value); + } + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + public Builder clearAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + } + andGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder + getAndGroupBuilder() { + return getAndGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if ((exprCase_ == 1) && (andGroupBuilder_ != null)) { + return andGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder> + getAndGroupFieldBuilder() { + if (andGroupBuilder_ == null) { + if (!(exprCase_ == 1)) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + andGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 1; + onChanged(); + ; + return andGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder> + orGroupBuilder_; + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList getOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } else { + if (exprCase_ == 2) { + return orGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + orGroupBuilder_.setMessage(value); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder + builderForValue) { + if (orGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + orGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + public Builder mergeOrGroup( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2 + && expr_ + != com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 2) { + orGroupBuilder_.mergeFrom(value); + } else { + orGroupBuilder_.setMessage(value); + } + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + public Builder clearOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + } + orGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder + getOrGroupBuilder() { + return getOrGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if ((exprCase_ == 2) && (orGroupBuilder_ != null)) { + return orGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder> + getOrGroupFieldBuilder() { + if (orGroupBuilder_ == null) { + if (!(exprCase_ == 2)) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + orGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 2; + onChanged(); + ; + return orGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + notExpressionBuilder_; + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression getNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance(); + } else { + if (exprCase_ == 3) { + return notExpressionBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + notExpressionBuilder_.setMessage(value); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder builderForValue) { + if (notExpressionBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + notExpressionBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + public Builder mergeNotExpression( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3 + && expr_ + != com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.newBuilder( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 3) { + notExpressionBuilder_.mergeFrom(value); + } else { + notExpressionBuilder_.setMessage(value); + } + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + public Builder clearNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + } + notExpressionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder + getNotExpressionBuilder() { + return getNotExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if ((exprCase_ == 3) && (notExpressionBuilder_ != null)) { + return notExpressionBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The FunnelParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + getNotExpressionFieldBuilder() { + if (notExpressionBuilder_ == null) { + if (!(exprCase_ == 3)) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance(); + } + notExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpression) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 3; + onChanged(); + ; + return notExpressionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilter, + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder> + funnelParameterFilterBuilder_; + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + * + * @return Whether the funnelParameterFilter field is set. + */ + @java.lang.Override + public boolean hasFunnelParameterFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + * + * @return The funnelParameterFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilter getFunnelParameterFilter() { + if (funnelParameterFilterBuilder_ == null) { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } else { + if (exprCase_ == 4) { + return funnelParameterFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + public Builder setFunnelParameterFilter( + com.google.analytics.data.v1alpha.FunnelParameterFilter value) { + if (funnelParameterFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + funnelParameterFilterBuilder_.setMessage(value); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + public Builder setFunnelParameterFilter( + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder builderForValue) { + if (funnelParameterFilterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + funnelParameterFilterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + public Builder mergeFunnelParameterFilter( + com.google.analytics.data.v1alpha.FunnelParameterFilter value) { + if (funnelParameterFilterBuilder_ == null) { + if (exprCase_ == 4 + && expr_ + != com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.FunnelParameterFilter.newBuilder( + (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 4) { + funnelParameterFilterBuilder_.mergeFrom(value); + } else { + funnelParameterFilterBuilder_.setMessage(value); + } + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + public Builder clearFunnelParameterFilter() { + if (funnelParameterFilterBuilder_ == null) { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + } + funnelParameterFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder + getFunnelParameterFilterBuilder() { + return getFunnelParameterFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder + getFunnelParameterFilterOrBuilder() { + if ((exprCase_ == 4) && (funnelParameterFilterBuilder_ != null)) { + return funnelParameterFilterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive funnel parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilter, + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder> + getFunnelParameterFilterFieldBuilder() { + if (funnelParameterFilterBuilder_ == null) { + if (!(exprCase_ == 4)) { + expr_ = com.google.analytics.data.v1alpha.FunnelParameterFilter.getDefaultInstance(); + } + funnelParameterFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilter, + com.google.analytics.data.v1alpha.FunnelParameterFilter.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder>( + (com.google.analytics.data.v1alpha.FunnelParameterFilter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 4; + onChanged(); + ; + return funnelParameterFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelParameterFilterExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelParameterFilterExpression) + private static final com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelParameterFilterExpression(); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelParameterFilterExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelParameterFilterExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelParameterFilterExpression + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionList.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionList.java new file mode 100644 index 00000000..87989ee0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionList.java @@ -0,0 +1,1036 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A list of funnel parameter filter expressions.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelParameterFilterExpressionList} + */ +public final class FunnelParameterFilterExpressionList + extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) + FunnelParameterFilterExpressionListOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelParameterFilterExpressionList.newBuilder() to construct. + private FunnelParameterFilterExpressionList( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelParameterFilterExpressionList() { + expressions_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelParameterFilterExpressionList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelParameterFilterExpressionList( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression>(); + mutable_bitField0_ |= 0x00000001; + } + expressions_.add( + input.readMessage( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.class, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder.class); + } + + public static final int EXPRESSIONS_FIELD_NUMBER = 1; + private java.util.List + expressions_; + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public java.util.List + getExpressionsList() { + return expressions_; + } + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + return expressions_; + } + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public int getExpressionsCount() { + return expressions_.size(); + } + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression getExpressions( + int index) { + return expressions_.get(index); + } + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getExpressionsOrBuilder(int index) { + return expressions_.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 < expressions_.size(); i++) { + output.writeMessage(1, expressions_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < expressions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, expressions_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelParameterFilterExpressionList)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList other = + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) obj; + + if (!getExpressionsList().equals(other.getExpressionsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExpressionsCount() > 0) { + hash = (37 * hash) + EXPRESSIONS_FIELD_NUMBER; + hash = (53 * hash) + getExpressionsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList 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.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelParameterFilterExpressionList 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A list of funnel parameter filter expressions.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelParameterFilterExpressionList} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.class, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.Builder.class); + } + + // Construct using + // com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExpressionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + expressionsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList build() { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList buildPartial() { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList result = + new com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList(this); + int from_bitField0_ = bitField0_; + if (expressionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.expressions_ = expressions_; + } else { + result.expressions_ = expressionsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) { + return mergeFrom( + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList other) { + if (other + == com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + .getDefaultInstance()) return this; + if (expressionsBuilder_ == null) { + if (!other.expressions_.isEmpty()) { + if (expressions_.isEmpty()) { + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExpressionsIsMutable(); + expressions_.addAll(other.expressions_); + } + onChanged(); + } + } else { + if (!other.expressions_.isEmpty()) { + if (expressionsBuilder_.isEmpty()) { + expressionsBuilder_.dispose(); + expressionsBuilder_ = null; + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + expressionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExpressionsFieldBuilder() + : null; + } else { + expressionsBuilder_.addAllMessages(other.expressions_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + expressions_ = java.util.Collections.emptyList(); + + private void ensureExpressionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression>(expressions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + expressionsBuilder_; + + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public java.util.List + getExpressionsList() { + if (expressionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(expressions_); + } else { + return expressionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public int getExpressionsCount() { + if (expressionsBuilder_ == null) { + return expressions_.size(); + } else { + return expressionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression getExpressions( + int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder setExpressions( + int index, com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.set(index, value); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder setExpressions( + int index, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.set(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(value); + onChanged(); + } else { + expressionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + int index, com.google.analytics.data.v1alpha.FunnelParameterFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(index, value); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + int index, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder addAllExpressions( + java.lang.Iterable< + ? extends com.google.analytics.data.v1alpha.FunnelParameterFilterExpression> + values) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, expressions_); + onChanged(); + } else { + expressionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder clearExpressions() { + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + expressionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public Builder removeExpressions(int index) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.remove(index); + onChanged(); + } else { + expressionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder + getExpressionsBuilder(int index) { + return getExpressionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getExpressionsOrBuilder(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + if (expressionsBuilder_ != null) { + return expressionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(expressions_); + } + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder + addExpressionsBuilder() { + return getExpressionsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance()); + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder + addExpressionsBuilder(int index) { + return getExpressionsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression + .getDefaultInstance()); + } + /** + * + * + *
+     * The list of funnel parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + public java.util.List + getExpressionsBuilderList() { + return getExpressionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + getExpressionsFieldBuilder() { + if (expressionsBuilder_ == null) { + expressionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder>( + expressions_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + expressions_ = null; + } + return expressionsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) + private static final com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList(); + } + + public static com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelParameterFilterExpressionList parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelParameterFilterExpressionList(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelParameterFilterExpressionList + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionListOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionListOrBuilder.java new file mode 100644 index 00000000..483f0c53 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionListOrBuilder.java @@ -0,0 +1,85 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelParameterFilterExpressionListOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelParameterFilterExpressionList) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + java.util.List + getExpressionsList(); + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression getExpressions(int index); + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + int getExpressionsCount(); + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + java.util.List< + ? extends com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder> + getExpressionsOrBuilderList(); + /** + * + * + *
+   * The list of funnel parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getExpressionsOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionOrBuilder.java new file mode 100644 index 00000000..a60e54a6 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterExpressionOrBuilder.java @@ -0,0 +1,177 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelParameterFilterExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelParameterFilterExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The FunnelParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + boolean hasAndGroup(); + /** + * + * + *
+   * The FunnelParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList getAndGroup(); + /** + * + * + *
+   * The FunnelParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder + getAndGroupOrBuilder(); + + /** + * + * + *
+   * The FunnelParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + boolean hasOrGroup(); + /** + * + * + *
+   * The FunnelParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionList getOrGroup(); + /** + * + * + *
+   * The FunnelParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionListOrBuilder + getOrGroupOrBuilder(); + + /** + * + * + *
+   * The FunnelParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + boolean hasNotExpression(); + /** + * + * + *
+   * The FunnelParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpression getNotExpression(); + /** + * + * + *
+   * The FunnelParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterExpressionOrBuilder + getNotExpressionOrBuilder(); + + /** + * + * + *
+   * A primitive funnel parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + * @return Whether the funnelParameterFilter field is set. + */ + boolean hasFunnelParameterFilter(); + /** + * + * + *
+   * A primitive funnel parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * + * @return The funnelParameterFilter. + */ + com.google.analytics.data.v1alpha.FunnelParameterFilter getFunnelParameterFilter(); + /** + * + * + *
+   * A primitive funnel parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + */ + com.google.analytics.data.v1alpha.FunnelParameterFilterOrBuilder + getFunnelParameterFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.FunnelParameterFilterExpression.ExprCase getExprCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterOrBuilder.java new file mode 100644 index 00000000..9b09f780 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelParameterFilterOrBuilder.java @@ -0,0 +1,286 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelParameterFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelParameterFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return Whether the eventParameterName field is set. + */ + boolean hasEventParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The eventParameterName. + */ + java.lang.String getEventParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The bytes for eventParameterName. + */ + com.google.protobuf.ByteString getEventParameterNameBytes(); + + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return Whether the itemParameterName field is set. + */ + boolean hasItemParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The itemParameterName. + */ + java.lang.String getItemParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The bytes for itemParameterName. + */ + com.google.protobuf.ByteString getItemParameterNameBytes(); + + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + boolean hasStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + com.google.analytics.data.v1alpha.StringFilter getStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder(); + + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + boolean hasInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + com.google.analytics.data.v1alpha.InListFilter getInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder(); + + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + boolean hasNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + com.google.analytics.data.v1alpha.NumericFilter getNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder(); + + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + boolean hasBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.FunnelParameterFilter.OneParameterCase + getOneParameterCase(); + + public com.google.analytics.data.v1alpha.FunnelParameterFilter.OneFilterCase getOneFilterCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadata.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadata.java new file mode 100644 index 00000000..716b8362 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadata.java @@ -0,0 +1,1111 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The funnel report's response metadata carries additional information about
+ * the funnel report.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelResponseMetadata} + */ +public final class FunnelResponseMetadata extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelResponseMetadata) + FunnelResponseMetadataOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelResponseMetadata.newBuilder() to construct. + private FunnelResponseMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelResponseMetadata() { + samplingMetadatas_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelResponseMetadata(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelResponseMetadata( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + samplingMetadatas_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + samplingMetadatas_.add( + input.readMessage( + com.google.analytics.data.v1alpha.SamplingMetadata.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + samplingMetadatas_ = java.util.Collections.unmodifiableList(samplingMetadatas_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelResponseMetadata.class, + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder.class); + } + + public static final int SAMPLING_METADATAS_FIELD_NUMBER = 1; + private java.util.List samplingMetadatas_; + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + @java.lang.Override + public java.util.List + getSamplingMetadatasList() { + return samplingMetadatas_; + } + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + @java.lang.Override + public java.util.List + getSamplingMetadatasOrBuilderList() { + return samplingMetadatas_; + } + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + @java.lang.Override + public int getSamplingMetadatasCount() { + return samplingMetadatas_.size(); + } + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SamplingMetadata getSamplingMetadatas(int index) { + return samplingMetadatas_.get(index); + } + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder getSamplingMetadatasOrBuilder( + int index) { + return samplingMetadatas_.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 < samplingMetadatas_.size(); i++) { + output.writeMessage(1, samplingMetadatas_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < samplingMetadatas_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, samplingMetadatas_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelResponseMetadata)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelResponseMetadata other = + (com.google.analytics.data.v1alpha.FunnelResponseMetadata) obj; + + if (!getSamplingMetadatasList().equals(other.getSamplingMetadatasList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSamplingMetadatasCount() > 0) { + hash = (37 * hash) + SAMPLING_METADATAS_FIELD_NUMBER; + hash = (53 * hash) + getSamplingMetadatasList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata 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.analytics.data.v1alpha.FunnelResponseMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelResponseMetadata 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The funnel report's response metadata carries additional information about
+   * the funnel report.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelResponseMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelResponseMetadata) + com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelResponseMetadata.class, + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelResponseMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getSamplingMetadatasFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (samplingMetadatasBuilder_ == null) { + samplingMetadatas_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + samplingMetadatasBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelResponseMetadata getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelResponseMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelResponseMetadata build() { + com.google.analytics.data.v1alpha.FunnelResponseMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelResponseMetadata buildPartial() { + com.google.analytics.data.v1alpha.FunnelResponseMetadata result = + new com.google.analytics.data.v1alpha.FunnelResponseMetadata(this); + int from_bitField0_ = bitField0_; + if (samplingMetadatasBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + samplingMetadatas_ = java.util.Collections.unmodifiableList(samplingMetadatas_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.samplingMetadatas_ = samplingMetadatas_; + } else { + result.samplingMetadatas_ = samplingMetadatasBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelResponseMetadata) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelResponseMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelResponseMetadata other) { + if (other == com.google.analytics.data.v1alpha.FunnelResponseMetadata.getDefaultInstance()) + return this; + if (samplingMetadatasBuilder_ == null) { + if (!other.samplingMetadatas_.isEmpty()) { + if (samplingMetadatas_.isEmpty()) { + samplingMetadatas_ = other.samplingMetadatas_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.addAll(other.samplingMetadatas_); + } + onChanged(); + } + } else { + if (!other.samplingMetadatas_.isEmpty()) { + if (samplingMetadatasBuilder_.isEmpty()) { + samplingMetadatasBuilder_.dispose(); + samplingMetadatasBuilder_ = null; + samplingMetadatas_ = other.samplingMetadatas_; + bitField0_ = (bitField0_ & ~0x00000001); + samplingMetadatasBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getSamplingMetadatasFieldBuilder() + : null; + } else { + samplingMetadatasBuilder_.addAllMessages(other.samplingMetadatas_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelResponseMetadata parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelResponseMetadata) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List samplingMetadatas_ = + java.util.Collections.emptyList(); + + private void ensureSamplingMetadatasIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + samplingMetadatas_ = + new java.util.ArrayList( + samplingMetadatas_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SamplingMetadata, + com.google.analytics.data.v1alpha.SamplingMetadata.Builder, + com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder> + samplingMetadatasBuilder_; + + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public java.util.List + getSamplingMetadatasList() { + if (samplingMetadatasBuilder_ == null) { + return java.util.Collections.unmodifiableList(samplingMetadatas_); + } else { + return samplingMetadatasBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public int getSamplingMetadatasCount() { + if (samplingMetadatasBuilder_ == null) { + return samplingMetadatas_.size(); + } else { + return samplingMetadatasBuilder_.getCount(); + } + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public com.google.analytics.data.v1alpha.SamplingMetadata getSamplingMetadatas(int index) { + if (samplingMetadatasBuilder_ == null) { + return samplingMetadatas_.get(index); + } else { + return samplingMetadatasBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder setSamplingMetadatas( + int index, com.google.analytics.data.v1alpha.SamplingMetadata value) { + if (samplingMetadatasBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.set(index, value); + onChanged(); + } else { + samplingMetadatasBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder setSamplingMetadatas( + int index, com.google.analytics.data.v1alpha.SamplingMetadata.Builder builderForValue) { + if (samplingMetadatasBuilder_ == null) { + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.set(index, builderForValue.build()); + onChanged(); + } else { + samplingMetadatasBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder addSamplingMetadatas(com.google.analytics.data.v1alpha.SamplingMetadata value) { + if (samplingMetadatasBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.add(value); + onChanged(); + } else { + samplingMetadatasBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder addSamplingMetadatas( + int index, com.google.analytics.data.v1alpha.SamplingMetadata value) { + if (samplingMetadatasBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.add(index, value); + onChanged(); + } else { + samplingMetadatasBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder addSamplingMetadatas( + com.google.analytics.data.v1alpha.SamplingMetadata.Builder builderForValue) { + if (samplingMetadatasBuilder_ == null) { + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.add(builderForValue.build()); + onChanged(); + } else { + samplingMetadatasBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder addSamplingMetadatas( + int index, com.google.analytics.data.v1alpha.SamplingMetadata.Builder builderForValue) { + if (samplingMetadatasBuilder_ == null) { + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.add(index, builderForValue.build()); + onChanged(); + } else { + samplingMetadatasBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder addAllSamplingMetadatas( + java.lang.Iterable values) { + if (samplingMetadatasBuilder_ == null) { + ensureSamplingMetadatasIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, samplingMetadatas_); + onChanged(); + } else { + samplingMetadatasBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder clearSamplingMetadatas() { + if (samplingMetadatasBuilder_ == null) { + samplingMetadatas_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + samplingMetadatasBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public Builder removeSamplingMetadatas(int index) { + if (samplingMetadatasBuilder_ == null) { + ensureSamplingMetadatasIsMutable(); + samplingMetadatas_.remove(index); + onChanged(); + } else { + samplingMetadatasBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public com.google.analytics.data.v1alpha.SamplingMetadata.Builder getSamplingMetadatasBuilder( + int index) { + return getSamplingMetadatasFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder + getSamplingMetadatasOrBuilder(int index) { + if (samplingMetadatasBuilder_ == null) { + return samplingMetadatas_.get(index); + } else { + return samplingMetadatasBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public java.util.List + getSamplingMetadatasOrBuilderList() { + if (samplingMetadatasBuilder_ != null) { + return samplingMetadatasBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(samplingMetadatas_); + } + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public com.google.analytics.data.v1alpha.SamplingMetadata.Builder + addSamplingMetadatasBuilder() { + return getSamplingMetadatasFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.SamplingMetadata.getDefaultInstance()); + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public com.google.analytics.data.v1alpha.SamplingMetadata.Builder addSamplingMetadatasBuilder( + int index) { + return getSamplingMetadatasFieldBuilder() + .addBuilder( + index, com.google.analytics.data.v1alpha.SamplingMetadata.getDefaultInstance()); + } + /** + * + * + *
+     * If funnel report results are
+     * [sampled](https://support.google.com/analytics/answer/2637192), this
+     * describes what percentage of events were used in this funnel report. One
+     * `samplingMetadatas` is populated for each date range. Each
+     * `samplingMetadatas` corresponds to a date range in order that date ranges
+     * were specified in the request.
+     * However if the results are not sampled, this field will not be defined.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + public java.util.List + getSamplingMetadatasBuilderList() { + return getSamplingMetadatasFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SamplingMetadata, + com.google.analytics.data.v1alpha.SamplingMetadata.Builder, + com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder> + getSamplingMetadatasFieldBuilder() { + if (samplingMetadatasBuilder_ == null) { + samplingMetadatasBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SamplingMetadata, + com.google.analytics.data.v1alpha.SamplingMetadata.Builder, + com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder>( + samplingMetadatas_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + samplingMetadatas_ = null; + } + return samplingMetadatasBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelResponseMetadata) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelResponseMetadata) + private static final com.google.analytics.data.v1alpha.FunnelResponseMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelResponseMetadata(); + } + + public static com.google.analytics.data.v1alpha.FunnelResponseMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelResponseMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelResponseMetadata(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelResponseMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadataOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadataOrBuilder.java new file mode 100644 index 00000000..6c7319b0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelResponseMetadataOrBuilder.java @@ -0,0 +1,108 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelResponseMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelResponseMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + java.util.List getSamplingMetadatasList(); + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + com.google.analytics.data.v1alpha.SamplingMetadata getSamplingMetadatas(int index); + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + int getSamplingMetadatasCount(); + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + java.util.List + getSamplingMetadatasOrBuilderList(); + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * describes what percentage of events were used in this funnel report. One
+   * `samplingMetadatas` is populated for each date range. Each
+   * `samplingMetadatas` corresponds to a date range in order that date ranges
+   * were specified in the request.
+   * However if the results are not sampled, this field will not be defined.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder getSamplingMetadatasOrBuilder( + int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStep.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStep.java new file mode 100644 index 00000000..e55b7100 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStep.java @@ -0,0 +1,1429 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Steps define the user journey you want to measure. Steps contain one or
+ * more conditions that your users must meet to be included in that step of
+ * the funnel journey.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelStep} + */ +public final class FunnelStep extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelStep) + FunnelStepOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelStep.newBuilder() to construct. + private FunnelStep(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelStep() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelStep(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelStep( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + name_ = s; + break; + } + case 16: + { + isDirectlyFollowedBy_ = input.readBool(); + break; + } + case 26: + { + com.google.protobuf.Duration.Builder subBuilder = null; + if (((bitField0_ & 0x00000001) != 0)) { + subBuilder = withinDurationFromPriorStep_.toBuilder(); + } + withinDurationFromPriorStep_ = + input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(withinDurationFromPriorStep_); + withinDurationFromPriorStep_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000001; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder subBuilder = null; + if (filterExpression_ != null) { + subBuilder = filterExpression_.toBuilder(); + } + filterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(filterExpression_); + filterExpression_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelStep_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelStep_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelStep.class, + com.google.analytics.data.v1alpha.FunnelStep.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The distinctive name for this step. If unspecified, steps will be named
+   * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+   * string value returned by the `funnelStepName` dimension. For example,
+   * specifying `name = Purchase` in the request's third funnel step will
+   * produce `3. Purchase` in the funnel report response.
+   * 
+ * + * 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 distinctive name for this step. If unspecified, steps will be named
+   * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+   * string value returned by the `funnelStepName` dimension. For example,
+   * specifying `name = Purchase` in the request's third funnel step will
+   * produce `3. Purchase` in the funnel report response.
+   * 
+ * + * 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 IS_DIRECTLY_FOLLOWED_BY_FIELD_NUMBER = 2; + private boolean isDirectlyFollowedBy_; + /** + * + * + *
+   * If true, this step must directly follow the previous step. If false,
+   * there can be events between the previous step and this step. If
+   * unspecified, `isDirectlyFollowedBy` is treated as false.
+   * 
+ * + * bool is_directly_followed_by = 2; + * + * @return The isDirectlyFollowedBy. + */ + @java.lang.Override + public boolean getIsDirectlyFollowedBy() { + return isDirectlyFollowedBy_; + } + + public static final int WITHIN_DURATION_FROM_PRIOR_STEP_FIELD_NUMBER = 3; + private com.google.protobuf.Duration withinDurationFromPriorStep_; + /** + * + * + *
+   * If specified, this step must complete within this duration of the
+   * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+   * of the endpoint at the microsecond granularity. For example a duration of
+   * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+   * microsecond.
+   * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+   * be separated by any time duration.
+   * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * + * @return Whether the withinDurationFromPriorStep field is set. + */ + @java.lang.Override + public boolean hasWithinDurationFromPriorStep() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * If specified, this step must complete within this duration of the
+   * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+   * of the endpoint at the microsecond granularity. For example a duration of
+   * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+   * microsecond.
+   * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+   * be separated by any time duration.
+   * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * + * @return The withinDurationFromPriorStep. + */ + @java.lang.Override + public com.google.protobuf.Duration getWithinDurationFromPriorStep() { + return withinDurationFromPriorStep_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : withinDurationFromPriorStep_; + } + /** + * + * + *
+   * If specified, this step must complete within this duration of the
+   * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+   * of the endpoint at the microsecond granularity. For example a duration of
+   * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+   * microsecond.
+   * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+   * be separated by any time duration.
+   * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getWithinDurationFromPriorStepOrBuilder() { + return withinDurationFromPriorStep_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : withinDurationFromPriorStep_; + } + + public static final int FILTER_EXPRESSION_FIELD_NUMBER = 4; + private com.google.analytics.data.v1alpha.FunnelFilterExpression filterExpression_; + /** + * + * + *
+   * The condition that your users must meet to be included in this step of
+   * the funnel journey.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * + * @return Whether the filterExpression field is set. + */ + @java.lang.Override + public boolean hasFilterExpression() { + return filterExpression_ != null; + } + /** + * + * + *
+   * The condition that your users must meet to be included in this step of
+   * the funnel journey.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * + * @return The filterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpression getFilterExpression() { + return filterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance() + : filterExpression_; + } + /** + * + * + *
+   * The condition that your users must meet to be included in this step of
+   * the funnel journey.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder + getFilterExpressionOrBuilder() { + return getFilterExpression(); + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (isDirectlyFollowedBy_ != false) { + output.writeBool(2, isDirectlyFollowedBy_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getWithinDurationFromPriorStep()); + } + if (filterExpression_ != null) { + output.writeMessage(4, getFilterExpression()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (isDirectlyFollowedBy_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, isDirectlyFollowedBy_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, getWithinDurationFromPriorStep()); + } + if (filterExpression_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelStep)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelStep other = + (com.google.analytics.data.v1alpha.FunnelStep) obj; + + if (!getName().equals(other.getName())) return false; + if (getIsDirectlyFollowedBy() != other.getIsDirectlyFollowedBy()) return false; + if (hasWithinDurationFromPriorStep() != other.hasWithinDurationFromPriorStep()) return false; + if (hasWithinDurationFromPriorStep()) { + if (!getWithinDurationFromPriorStep().equals(other.getWithinDurationFromPriorStep())) + return false; + } + if (hasFilterExpression() != other.hasFilterExpression()) return false; + if (hasFilterExpression()) { + if (!getFilterExpression().equals(other.getFilterExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + IS_DIRECTLY_FOLLOWED_BY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIsDirectlyFollowedBy()); + if (hasWithinDurationFromPriorStep()) { + hash = (37 * hash) + WITHIN_DURATION_FROM_PRIOR_STEP_FIELD_NUMBER; + hash = (53 * hash) + getWithinDurationFromPriorStep().hashCode(); + } + if (hasFilterExpression()) { + hash = (37 * hash) + FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelStep 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.analytics.data.v1alpha.FunnelStep parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelStep parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelStep 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Steps define the user journey you want to measure. Steps contain one or
+   * more conditions that your users must meet to be included in that step of
+   * the funnel journey.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelStep} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelStep) + com.google.analytics.data.v1alpha.FunnelStepOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelStep_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelStep_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelStep.class, + com.google.analytics.data.v1alpha.FunnelStep.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelStep.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getWithinDurationFromPriorStepFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + isDirectlyFollowedBy_ = false; + + if (withinDurationFromPriorStepBuilder_ == null) { + withinDurationFromPriorStep_ = null; + } else { + withinDurationFromPriorStepBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + if (filterExpressionBuilder_ == null) { + filterExpression_ = null; + } else { + filterExpression_ = null; + filterExpressionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelStep_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelStep getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelStep.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelStep build() { + com.google.analytics.data.v1alpha.FunnelStep result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelStep buildPartial() { + com.google.analytics.data.v1alpha.FunnelStep result = + new com.google.analytics.data.v1alpha.FunnelStep(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + result.name_ = name_; + result.isDirectlyFollowedBy_ = isDirectlyFollowedBy_; + if (((from_bitField0_ & 0x00000001) != 0)) { + if (withinDurationFromPriorStepBuilder_ == null) { + result.withinDurationFromPriorStep_ = withinDurationFromPriorStep_; + } else { + result.withinDurationFromPriorStep_ = withinDurationFromPriorStepBuilder_.build(); + } + to_bitField0_ |= 0x00000001; + } + if (filterExpressionBuilder_ == null) { + result.filterExpression_ = filterExpression_; + } else { + result.filterExpression_ = filterExpressionBuilder_.build(); + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelStep) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelStep) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelStep other) { + if (other == com.google.analytics.data.v1alpha.FunnelStep.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.getIsDirectlyFollowedBy() != false) { + setIsDirectlyFollowedBy(other.getIsDirectlyFollowedBy()); + } + if (other.hasWithinDurationFromPriorStep()) { + mergeWithinDurationFromPriorStep(other.getWithinDurationFromPriorStep()); + } + if (other.hasFilterExpression()) { + mergeFilterExpression(other.getFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelStep parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.FunnelStep) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The distinctive name for this step. If unspecified, steps will be named
+     * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+     * string value returned by the `funnelStepName` dimension. For example,
+     * specifying `name = Purchase` in the request's third funnel step will
+     * produce `3. Purchase` in the funnel report response.
+     * 
+ * + * 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 distinctive name for this step. If unspecified, steps will be named
+     * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+     * string value returned by the `funnelStepName` dimension. For example,
+     * specifying `name = Purchase` in the request's third funnel step will
+     * produce `3. Purchase` in the funnel report response.
+     * 
+ * + * 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 distinctive name for this step. If unspecified, steps will be named
+     * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+     * string value returned by the `funnelStepName` dimension. For example,
+     * specifying `name = Purchase` in the request's third funnel step will
+     * produce `3. Purchase` in the funnel report response.
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The distinctive name for this step. If unspecified, steps will be named
+     * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+     * string value returned by the `funnelStepName` dimension. For example,
+     * specifying `name = Purchase` in the request's third funnel step will
+     * produce `3. Purchase` in the funnel report response.
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The distinctive name for this step. If unspecified, steps will be named
+     * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+     * string value returned by the `funnelStepName` dimension. For example,
+     * specifying `name = Purchase` in the request's third funnel step will
+     * produce `3. Purchase` in the funnel report response.
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private boolean isDirectlyFollowedBy_; + /** + * + * + *
+     * If true, this step must directly follow the previous step. If false,
+     * there can be events between the previous step and this step. If
+     * unspecified, `isDirectlyFollowedBy` is treated as false.
+     * 
+ * + * bool is_directly_followed_by = 2; + * + * @return The isDirectlyFollowedBy. + */ + @java.lang.Override + public boolean getIsDirectlyFollowedBy() { + return isDirectlyFollowedBy_; + } + /** + * + * + *
+     * If true, this step must directly follow the previous step. If false,
+     * there can be events between the previous step and this step. If
+     * unspecified, `isDirectlyFollowedBy` is treated as false.
+     * 
+ * + * bool is_directly_followed_by = 2; + * + * @param value The isDirectlyFollowedBy to set. + * @return This builder for chaining. + */ + public Builder setIsDirectlyFollowedBy(boolean value) { + + isDirectlyFollowedBy_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If true, this step must directly follow the previous step. If false,
+     * there can be events between the previous step and this step. If
+     * unspecified, `isDirectlyFollowedBy` is treated as false.
+     * 
+ * + * bool is_directly_followed_by = 2; + * + * @return This builder for chaining. + */ + public Builder clearIsDirectlyFollowedBy() { + + isDirectlyFollowedBy_ = false; + onChanged(); + return this; + } + + private com.google.protobuf.Duration withinDurationFromPriorStep_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + withinDurationFromPriorStepBuilder_; + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * + * @return Whether the withinDurationFromPriorStep field is set. + */ + public boolean hasWithinDurationFromPriorStep() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * + * @return The withinDurationFromPriorStep. + */ + public com.google.protobuf.Duration getWithinDurationFromPriorStep() { + if (withinDurationFromPriorStepBuilder_ == null) { + return withinDurationFromPriorStep_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : withinDurationFromPriorStep_; + } else { + return withinDurationFromPriorStepBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + public Builder setWithinDurationFromPriorStep(com.google.protobuf.Duration value) { + if (withinDurationFromPriorStepBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + withinDurationFromPriorStep_ = value; + onChanged(); + } else { + withinDurationFromPriorStepBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + public Builder setWithinDurationFromPriorStep( + com.google.protobuf.Duration.Builder builderForValue) { + if (withinDurationFromPriorStepBuilder_ == null) { + withinDurationFromPriorStep_ = builderForValue.build(); + onChanged(); + } else { + withinDurationFromPriorStepBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + public Builder mergeWithinDurationFromPriorStep(com.google.protobuf.Duration value) { + if (withinDurationFromPriorStepBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && withinDurationFromPriorStep_ != null + && withinDurationFromPriorStep_ != com.google.protobuf.Duration.getDefaultInstance()) { + withinDurationFromPriorStep_ = + com.google.protobuf.Duration.newBuilder(withinDurationFromPriorStep_) + .mergeFrom(value) + .buildPartial(); + } else { + withinDurationFromPriorStep_ = value; + } + onChanged(); + } else { + withinDurationFromPriorStepBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + public Builder clearWithinDurationFromPriorStep() { + if (withinDurationFromPriorStepBuilder_ == null) { + withinDurationFromPriorStep_ = null; + onChanged(); + } else { + withinDurationFromPriorStepBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + public com.google.protobuf.Duration.Builder getWithinDurationFromPriorStepBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return getWithinDurationFromPriorStepFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + public com.google.protobuf.DurationOrBuilder getWithinDurationFromPriorStepOrBuilder() { + if (withinDurationFromPriorStepBuilder_ != null) { + return withinDurationFromPriorStepBuilder_.getMessageOrBuilder(); + } else { + return withinDurationFromPriorStep_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : withinDurationFromPriorStep_; + } + } + /** + * + * + *
+     * If specified, this step must complete within this duration of the
+     * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+     * of the endpoint at the microsecond granularity. For example a duration of
+     * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+     * microsecond.
+     * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+     * be separated by any time duration.
+     * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + getWithinDurationFromPriorStepFieldBuilder() { + if (withinDurationFromPriorStepBuilder_ == null) { + withinDurationFromPriorStepBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getWithinDurationFromPriorStep(), getParentForChildren(), isClean()); + withinDurationFromPriorStep_ = null; + } + return withinDurationFromPriorStepBuilder_; + } + + private com.google.analytics.data.v1alpha.FunnelFilterExpression filterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + filterExpressionBuilder_; + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * + * @return Whether the filterExpression field is set. + */ + public boolean hasFilterExpression() { + return filterExpressionBuilder_ != null || filterExpression_ != null; + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * + * @return The filterExpression. + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression getFilterExpression() { + if (filterExpressionBuilder_ == null) { + return filterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance() + : filterExpression_; + } else { + return filterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + public Builder setFilterExpression( + com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (filterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + filterExpression_ = value; + onChanged(); + } else { + filterExpressionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + public Builder setFilterExpression( + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder builderForValue) { + if (filterExpressionBuilder_ == null) { + filterExpression_ = builderForValue.build(); + onChanged(); + } else { + filterExpressionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + public Builder mergeFilterExpression( + com.google.analytics.data.v1alpha.FunnelFilterExpression value) { + if (filterExpressionBuilder_ == null) { + if (filterExpression_ != null) { + filterExpression_ = + com.google.analytics.data.v1alpha.FunnelFilterExpression.newBuilder(filterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + filterExpression_ = value; + } + onChanged(); + } else { + filterExpressionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + public Builder clearFilterExpression() { + if (filterExpressionBuilder_ == null) { + filterExpression_ = null; + onChanged(); + } else { + filterExpression_ = null; + filterExpressionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder + getFilterExpressionBuilder() { + + onChanged(); + return getFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + public com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder + getFilterExpressionOrBuilder() { + if (filterExpressionBuilder_ != null) { + return filterExpressionBuilder_.getMessageOrBuilder(); + } else { + return filterExpression_ == null + ? com.google.analytics.data.v1alpha.FunnelFilterExpression.getDefaultInstance() + : filterExpression_; + } + } + /** + * + * + *
+     * The condition that your users must meet to be included in this step of
+     * the funnel journey.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder> + getFilterExpressionFieldBuilder() { + if (filterExpressionBuilder_ == null) { + filterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelFilterExpression, + com.google.analytics.data.v1alpha.FunnelFilterExpression.Builder, + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder>( + getFilterExpression(), getParentForChildren(), isClean()); + filterExpression_ = null; + } + return filterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelStep) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelStep) + private static final com.google.analytics.data.v1alpha.FunnelStep DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelStep(); + } + + public static com.google.analytics.data.v1alpha.FunnelStep getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelStep parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelStep(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelStep getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStepOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStepOrBuilder.java new file mode 100644 index 00000000..88c76d17 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelStepOrBuilder.java @@ -0,0 +1,164 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelStepOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelStep) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The distinctive name for this step. If unspecified, steps will be named
+   * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+   * string value returned by the `funnelStepName` dimension. For example,
+   * specifying `name = Purchase` in the request's third funnel step will
+   * produce `3. Purchase` in the funnel report response.
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The distinctive name for this step. If unspecified, steps will be named
+   * by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines
+   * string value returned by the `funnelStepName` dimension. For example,
+   * specifying `name = Purchase` in the request's third funnel step will
+   * produce `3. Purchase` in the funnel report response.
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * If true, this step must directly follow the previous step. If false,
+   * there can be events between the previous step and this step. If
+   * unspecified, `isDirectlyFollowedBy` is treated as false.
+   * 
+ * + * bool is_directly_followed_by = 2; + * + * @return The isDirectlyFollowedBy. + */ + boolean getIsDirectlyFollowedBy(); + + /** + * + * + *
+   * If specified, this step must complete within this duration of the
+   * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+   * of the endpoint at the microsecond granularity. For example a duration of
+   * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+   * microsecond.
+   * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+   * be separated by any time duration.
+   * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * + * @return Whether the withinDurationFromPriorStep field is set. + */ + boolean hasWithinDurationFromPriorStep(); + /** + * + * + *
+   * If specified, this step must complete within this duration of the
+   * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+   * of the endpoint at the microsecond granularity. For example a duration of
+   * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+   * microsecond.
+   * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+   * be separated by any time duration.
+   * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * + * @return The withinDurationFromPriorStep. + */ + com.google.protobuf.Duration getWithinDurationFromPriorStep(); + /** + * + * + *
+   * If specified, this step must complete within this duration of the
+   * completion of the prior step. `withinDurationFromPriorStep` is inclusive
+   * of the endpoint at the microsecond granularity. For example a duration of
+   * 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1
+   * microsecond.
+   * `withinDurationFromPriorStep` is optional, and if unspecified, steps may
+   * be separated by any time duration.
+   * 
+ * + * optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + com.google.protobuf.DurationOrBuilder getWithinDurationFromPriorStepOrBuilder(); + + /** + * + * + *
+   * The condition that your users must meet to be included in this step of
+   * the funnel journey.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * + * @return Whether the filterExpression field is set. + */ + boolean hasFilterExpression(); + /** + * + * + *
+   * The condition that your users must meet to be included in this step of
+   * the funnel journey.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * + * @return The filterExpression. + */ + com.google.analytics.data.v1alpha.FunnelFilterExpression getFilterExpression(); + /** + * + * + *
+   * The condition that your users must meet to be included in this step of
+   * the funnel journey.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + com.google.analytics.data.v1alpha.FunnelFilterExpressionOrBuilder getFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReport.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReport.java new file mode 100644 index 00000000..f7d89e9b --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReport.java @@ -0,0 +1,2327 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Funnel sub reports contain the dimension and metric data values. For example,
+ * 12 users reached the second step of the funnel.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelSubReport} + */ +public final class FunnelSubReport extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.FunnelSubReport) + FunnelSubReportOrBuilder { + private static final long serialVersionUID = 0L; + // Use FunnelSubReport.newBuilder() to construct. + private FunnelSubReport(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FunnelSubReport() { + dimensionHeaders_ = java.util.Collections.emptyList(); + metricHeaders_ = java.util.Collections.emptyList(); + rows_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FunnelSubReport(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private FunnelSubReport( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + dimensionHeaders_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + dimensionHeaders_.add( + input.readMessage( + com.google.analytics.data.v1alpha.DimensionHeader.parser(), + extensionRegistry)); + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + metricHeaders_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + metricHeaders_.add( + input.readMessage( + com.google.analytics.data.v1alpha.MetricHeader.parser(), extensionRegistry)); + break; + } + case 26: + { + if (!((mutable_bitField0_ & 0x00000004) != 0)) { + rows_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000004; + } + rows_.add( + input.readMessage( + com.google.analytics.data.v1alpha.Row.parser(), extensionRegistry)); + break; + } + case 34: + { + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder subBuilder = null; + if (metadata_ != null) { + subBuilder = metadata_.toBuilder(); + } + metadata_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelResponseMetadata.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(metadata_); + metadata_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + dimensionHeaders_ = java.util.Collections.unmodifiableList(dimensionHeaders_); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + metricHeaders_ = java.util.Collections.unmodifiableList(metricHeaders_); + } + if (((mutable_bitField0_ & 0x00000004) != 0)) { + rows_ = java.util.Collections.unmodifiableList(rows_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelSubReport_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelSubReport_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelSubReport.class, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder.class); + } + + public static final int DIMENSION_HEADERS_FIELD_NUMBER = 1; + private java.util.List dimensionHeaders_; + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + @java.lang.Override + public java.util.List + getDimensionHeadersList() { + return dimensionHeaders_; + } + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + @java.lang.Override + public java.util.List + getDimensionHeadersOrBuilderList() { + return dimensionHeaders_; + } + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + @java.lang.Override + public int getDimensionHeadersCount() { + return dimensionHeaders_.size(); + } + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionHeader getDimensionHeaders(int index) { + return dimensionHeaders_.get(index); + } + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder getDimensionHeadersOrBuilder( + int index) { + return dimensionHeaders_.get(index); + } + + public static final int METRIC_HEADERS_FIELD_NUMBER = 2; + private java.util.List metricHeaders_; + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + @java.lang.Override + public java.util.List getMetricHeadersList() { + return metricHeaders_; + } + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + @java.lang.Override + public java.util.List + getMetricHeadersOrBuilderList() { + return metricHeaders_; + } + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + @java.lang.Override + public int getMetricHeadersCount() { + return metricHeaders_.size(); + } + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricHeader getMetricHeaders(int index) { + return metricHeaders_.get(index); + } + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricHeaderOrBuilder getMetricHeadersOrBuilder( + int index) { + return metricHeaders_.get(index); + } + + public static final int ROWS_FIELD_NUMBER = 3; + private java.util.List rows_; + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + @java.lang.Override + public java.util.List getRowsList() { + return rows_; + } + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + @java.lang.Override + public java.util.List + getRowsOrBuilderList() { + return rows_; + } + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + @java.lang.Override + public int getRowsCount() { + return rows_.size(); + } + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Row getRows(int index) { + return rows_.get(index); + } + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.RowOrBuilder getRowsOrBuilder(int index) { + return rows_.get(index); + } + + public static final int METADATA_FIELD_NUMBER = 4; + private com.google.analytics.data.v1alpha.FunnelResponseMetadata metadata_; + /** + * + * + *
+   * Metadata for the funnel report.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * + * @return Whether the metadata field is set. + */ + @java.lang.Override + public boolean hasMetadata() { + return metadata_ != null; + } + /** + * + * + *
+   * Metadata for the funnel report.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * + * @return The metadata. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelResponseMetadata getMetadata() { + return metadata_ == null + ? com.google.analytics.data.v1alpha.FunnelResponseMetadata.getDefaultInstance() + : metadata_; + } + /** + * + * + *
+   * Metadata for the funnel report.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder getMetadataOrBuilder() { + return getMetadata(); + } + + 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 < dimensionHeaders_.size(); i++) { + output.writeMessage(1, dimensionHeaders_.get(i)); + } + for (int i = 0; i < metricHeaders_.size(); i++) { + output.writeMessage(2, metricHeaders_.get(i)); + } + for (int i = 0; i < rows_.size(); i++) { + output.writeMessage(3, rows_.get(i)); + } + if (metadata_ != null) { + output.writeMessage(4, getMetadata()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < dimensionHeaders_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, dimensionHeaders_.get(i)); + } + for (int i = 0; i < metricHeaders_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, metricHeaders_.get(i)); + } + for (int i = 0; i < rows_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, rows_.get(i)); + } + if (metadata_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getMetadata()); + } + size += unknownFields.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.analytics.data.v1alpha.FunnelSubReport)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.FunnelSubReport other = + (com.google.analytics.data.v1alpha.FunnelSubReport) obj; + + if (!getDimensionHeadersList().equals(other.getDimensionHeadersList())) return false; + if (!getMetricHeadersList().equals(other.getMetricHeadersList())) return false; + if (!getRowsList().equals(other.getRowsList())) return false; + if (hasMetadata() != other.hasMetadata()) return false; + if (hasMetadata()) { + if (!getMetadata().equals(other.getMetadata())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getDimensionHeadersCount() > 0) { + hash = (37 * hash) + DIMENSION_HEADERS_FIELD_NUMBER; + hash = (53 * hash) + getDimensionHeadersList().hashCode(); + } + if (getMetricHeadersCount() > 0) { + hash = (37 * hash) + METRIC_HEADERS_FIELD_NUMBER; + hash = (53 * hash) + getMetricHeadersList().hashCode(); + } + if (getRowsCount() > 0) { + hash = (37 * hash) + ROWS_FIELD_NUMBER; + hash = (53 * hash) + getRowsList().hashCode(); + } + if (hasMetadata()) { + hash = (37 * hash) + METADATA_FIELD_NUMBER; + hash = (53 * hash) + getMetadata().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport 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.analytics.data.v1alpha.FunnelSubReport parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.FunnelSubReport 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Funnel sub reports contain the dimension and metric data values. For example,
+   * 12 users reached the second step of the funnel.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.FunnelSubReport} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.FunnelSubReport) + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelSubReport_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelSubReport_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.FunnelSubReport.class, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.FunnelSubReport.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getDimensionHeadersFieldBuilder(); + getMetricHeadersFieldBuilder(); + getRowsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (dimensionHeadersBuilder_ == null) { + dimensionHeaders_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + dimensionHeadersBuilder_.clear(); + } + if (metricHeadersBuilder_ == null) { + metricHeaders_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + metricHeadersBuilder_.clear(); + } + if (rowsBuilder_ == null) { + rows_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + } else { + rowsBuilder_.clear(); + } + if (metadataBuilder_ == null) { + metadata_ = null; + } else { + metadata_ = null; + metadataBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_FunnelSubReport_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReport getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReport build() { + com.google.analytics.data.v1alpha.FunnelSubReport result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReport buildPartial() { + com.google.analytics.data.v1alpha.FunnelSubReport result = + new com.google.analytics.data.v1alpha.FunnelSubReport(this); + int from_bitField0_ = bitField0_; + if (dimensionHeadersBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + dimensionHeaders_ = java.util.Collections.unmodifiableList(dimensionHeaders_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.dimensionHeaders_ = dimensionHeaders_; + } else { + result.dimensionHeaders_ = dimensionHeadersBuilder_.build(); + } + if (metricHeadersBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + metricHeaders_ = java.util.Collections.unmodifiableList(metricHeaders_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.metricHeaders_ = metricHeaders_; + } else { + result.metricHeaders_ = metricHeadersBuilder_.build(); + } + if (rowsBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0)) { + rows_ = java.util.Collections.unmodifiableList(rows_); + bitField0_ = (bitField0_ & ~0x00000004); + } + result.rows_ = rows_; + } else { + result.rows_ = rowsBuilder_.build(); + } + if (metadataBuilder_ == null) { + result.metadata_ = metadata_; + } else { + result.metadata_ = metadataBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.FunnelSubReport) { + return mergeFrom((com.google.analytics.data.v1alpha.FunnelSubReport) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.FunnelSubReport other) { + if (other == com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance()) + return this; + if (dimensionHeadersBuilder_ == null) { + if (!other.dimensionHeaders_.isEmpty()) { + if (dimensionHeaders_.isEmpty()) { + dimensionHeaders_ = other.dimensionHeaders_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.addAll(other.dimensionHeaders_); + } + onChanged(); + } + } else { + if (!other.dimensionHeaders_.isEmpty()) { + if (dimensionHeadersBuilder_.isEmpty()) { + dimensionHeadersBuilder_.dispose(); + dimensionHeadersBuilder_ = null; + dimensionHeaders_ = other.dimensionHeaders_; + bitField0_ = (bitField0_ & ~0x00000001); + dimensionHeadersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getDimensionHeadersFieldBuilder() + : null; + } else { + dimensionHeadersBuilder_.addAllMessages(other.dimensionHeaders_); + } + } + } + if (metricHeadersBuilder_ == null) { + if (!other.metricHeaders_.isEmpty()) { + if (metricHeaders_.isEmpty()) { + metricHeaders_ = other.metricHeaders_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureMetricHeadersIsMutable(); + metricHeaders_.addAll(other.metricHeaders_); + } + onChanged(); + } + } else { + if (!other.metricHeaders_.isEmpty()) { + if (metricHeadersBuilder_.isEmpty()) { + metricHeadersBuilder_.dispose(); + metricHeadersBuilder_ = null; + metricHeaders_ = other.metricHeaders_; + bitField0_ = (bitField0_ & ~0x00000002); + metricHeadersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getMetricHeadersFieldBuilder() + : null; + } else { + metricHeadersBuilder_.addAllMessages(other.metricHeaders_); + } + } + } + if (rowsBuilder_ == null) { + if (!other.rows_.isEmpty()) { + if (rows_.isEmpty()) { + rows_ = other.rows_; + bitField0_ = (bitField0_ & ~0x00000004); + } else { + ensureRowsIsMutable(); + rows_.addAll(other.rows_); + } + onChanged(); + } + } else { + if (!other.rows_.isEmpty()) { + if (rowsBuilder_.isEmpty()) { + rowsBuilder_.dispose(); + rowsBuilder_ = null; + rows_ = other.rows_; + bitField0_ = (bitField0_ & ~0x00000004); + rowsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getRowsFieldBuilder() + : null; + } else { + rowsBuilder_.addAllMessages(other.rows_); + } + } + } + if (other.hasMetadata()) { + mergeMetadata(other.getMetadata()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.FunnelSubReport parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.FunnelSubReport) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List dimensionHeaders_ = + java.util.Collections.emptyList(); + + private void ensureDimensionHeadersIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + dimensionHeaders_ = + new java.util.ArrayList( + dimensionHeaders_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionHeader, + com.google.analytics.data.v1alpha.DimensionHeader.Builder, + com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder> + dimensionHeadersBuilder_; + + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public java.util.List + getDimensionHeadersList() { + if (dimensionHeadersBuilder_ == null) { + return java.util.Collections.unmodifiableList(dimensionHeaders_); + } else { + return dimensionHeadersBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public int getDimensionHeadersCount() { + if (dimensionHeadersBuilder_ == null) { + return dimensionHeaders_.size(); + } else { + return dimensionHeadersBuilder_.getCount(); + } + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public com.google.analytics.data.v1alpha.DimensionHeader getDimensionHeaders(int index) { + if (dimensionHeadersBuilder_ == null) { + return dimensionHeaders_.get(index); + } else { + return dimensionHeadersBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder setDimensionHeaders( + int index, com.google.analytics.data.v1alpha.DimensionHeader value) { + if (dimensionHeadersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.set(index, value); + onChanged(); + } else { + dimensionHeadersBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder setDimensionHeaders( + int index, com.google.analytics.data.v1alpha.DimensionHeader.Builder builderForValue) { + if (dimensionHeadersBuilder_ == null) { + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.set(index, builderForValue.build()); + onChanged(); + } else { + dimensionHeadersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder addDimensionHeaders(com.google.analytics.data.v1alpha.DimensionHeader value) { + if (dimensionHeadersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.add(value); + onChanged(); + } else { + dimensionHeadersBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder addDimensionHeaders( + int index, com.google.analytics.data.v1alpha.DimensionHeader value) { + if (dimensionHeadersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.add(index, value); + onChanged(); + } else { + dimensionHeadersBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder addDimensionHeaders( + com.google.analytics.data.v1alpha.DimensionHeader.Builder builderForValue) { + if (dimensionHeadersBuilder_ == null) { + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.add(builderForValue.build()); + onChanged(); + } else { + dimensionHeadersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder addDimensionHeaders( + int index, com.google.analytics.data.v1alpha.DimensionHeader.Builder builderForValue) { + if (dimensionHeadersBuilder_ == null) { + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.add(index, builderForValue.build()); + onChanged(); + } else { + dimensionHeadersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder addAllDimensionHeaders( + java.lang.Iterable values) { + if (dimensionHeadersBuilder_ == null) { + ensureDimensionHeadersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, dimensionHeaders_); + onChanged(); + } else { + dimensionHeadersBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder clearDimensionHeaders() { + if (dimensionHeadersBuilder_ == null) { + dimensionHeaders_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + dimensionHeadersBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public Builder removeDimensionHeaders(int index) { + if (dimensionHeadersBuilder_ == null) { + ensureDimensionHeadersIsMutable(); + dimensionHeaders_.remove(index); + onChanged(); + } else { + dimensionHeadersBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public com.google.analytics.data.v1alpha.DimensionHeader.Builder getDimensionHeadersBuilder( + int index) { + return getDimensionHeadersFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder getDimensionHeadersOrBuilder( + int index) { + if (dimensionHeadersBuilder_ == null) { + return dimensionHeaders_.get(index); + } else { + return dimensionHeadersBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public java.util.List + getDimensionHeadersOrBuilderList() { + if (dimensionHeadersBuilder_ != null) { + return dimensionHeadersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(dimensionHeaders_); + } + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public com.google.analytics.data.v1alpha.DimensionHeader.Builder addDimensionHeadersBuilder() { + return getDimensionHeadersFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.DimensionHeader.getDefaultInstance()); + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public com.google.analytics.data.v1alpha.DimensionHeader.Builder addDimensionHeadersBuilder( + int index) { + return getDimensionHeadersFieldBuilder() + .addBuilder( + index, com.google.analytics.data.v1alpha.DimensionHeader.getDefaultInstance()); + } + /** + * + * + *
+     * Describes dimension columns. Funnel reports always include the funnel step
+     * dimension in sub report responses. Additional dimensions like breakdowns,
+     * dates, and next actions may be present in the response if requested.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + public java.util.List + getDimensionHeadersBuilderList() { + return getDimensionHeadersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionHeader, + com.google.analytics.data.v1alpha.DimensionHeader.Builder, + com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder> + getDimensionHeadersFieldBuilder() { + if (dimensionHeadersBuilder_ == null) { + dimensionHeadersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionHeader, + com.google.analytics.data.v1alpha.DimensionHeader.Builder, + com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder>( + dimensionHeaders_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + dimensionHeaders_ = null; + } + return dimensionHeadersBuilder_; + } + + private java.util.List metricHeaders_ = + java.util.Collections.emptyList(); + + private void ensureMetricHeadersIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + metricHeaders_ = + new java.util.ArrayList(metricHeaders_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.MetricHeader, + com.google.analytics.data.v1alpha.MetricHeader.Builder, + com.google.analytics.data.v1alpha.MetricHeaderOrBuilder> + metricHeadersBuilder_; + + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public java.util.List getMetricHeadersList() { + if (metricHeadersBuilder_ == null) { + return java.util.Collections.unmodifiableList(metricHeaders_); + } else { + return metricHeadersBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public int getMetricHeadersCount() { + if (metricHeadersBuilder_ == null) { + return metricHeaders_.size(); + } else { + return metricHeadersBuilder_.getCount(); + } + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public com.google.analytics.data.v1alpha.MetricHeader getMetricHeaders(int index) { + if (metricHeadersBuilder_ == null) { + return metricHeaders_.get(index); + } else { + return metricHeadersBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder setMetricHeaders( + int index, com.google.analytics.data.v1alpha.MetricHeader value) { + if (metricHeadersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricHeadersIsMutable(); + metricHeaders_.set(index, value); + onChanged(); + } else { + metricHeadersBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder setMetricHeaders( + int index, com.google.analytics.data.v1alpha.MetricHeader.Builder builderForValue) { + if (metricHeadersBuilder_ == null) { + ensureMetricHeadersIsMutable(); + metricHeaders_.set(index, builderForValue.build()); + onChanged(); + } else { + metricHeadersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder addMetricHeaders(com.google.analytics.data.v1alpha.MetricHeader value) { + if (metricHeadersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricHeadersIsMutable(); + metricHeaders_.add(value); + onChanged(); + } else { + metricHeadersBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder addMetricHeaders( + int index, com.google.analytics.data.v1alpha.MetricHeader value) { + if (metricHeadersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricHeadersIsMutable(); + metricHeaders_.add(index, value); + onChanged(); + } else { + metricHeadersBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder addMetricHeaders( + com.google.analytics.data.v1alpha.MetricHeader.Builder builderForValue) { + if (metricHeadersBuilder_ == null) { + ensureMetricHeadersIsMutable(); + metricHeaders_.add(builderForValue.build()); + onChanged(); + } else { + metricHeadersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder addMetricHeaders( + int index, com.google.analytics.data.v1alpha.MetricHeader.Builder builderForValue) { + if (metricHeadersBuilder_ == null) { + ensureMetricHeadersIsMutable(); + metricHeaders_.add(index, builderForValue.build()); + onChanged(); + } else { + metricHeadersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder addAllMetricHeaders( + java.lang.Iterable values) { + if (metricHeadersBuilder_ == null) { + ensureMetricHeadersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, metricHeaders_); + onChanged(); + } else { + metricHeadersBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder clearMetricHeaders() { + if (metricHeadersBuilder_ == null) { + metricHeaders_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + metricHeadersBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public Builder removeMetricHeaders(int index) { + if (metricHeadersBuilder_ == null) { + ensureMetricHeadersIsMutable(); + metricHeaders_.remove(index); + onChanged(); + } else { + metricHeadersBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public com.google.analytics.data.v1alpha.MetricHeader.Builder getMetricHeadersBuilder( + int index) { + return getMetricHeadersFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public com.google.analytics.data.v1alpha.MetricHeaderOrBuilder getMetricHeadersOrBuilder( + int index) { + if (metricHeadersBuilder_ == null) { + return metricHeaders_.get(index); + } else { + return metricHeadersBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public java.util.List + getMetricHeadersOrBuilderList() { + if (metricHeadersBuilder_ != null) { + return metricHeadersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(metricHeaders_); + } + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public com.google.analytics.data.v1alpha.MetricHeader.Builder addMetricHeadersBuilder() { + return getMetricHeadersFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.MetricHeader.getDefaultInstance()); + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public com.google.analytics.data.v1alpha.MetricHeader.Builder addMetricHeadersBuilder( + int index) { + return getMetricHeadersFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.MetricHeader.getDefaultInstance()); + } + /** + * + * + *
+     * Describes metric columns. Funnel reports always include active users in sub
+     * report responses. The funnel table includes additional metrics like
+     * completion rate, abandonments, and abandonments rate.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + public java.util.List + getMetricHeadersBuilderList() { + return getMetricHeadersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.MetricHeader, + com.google.analytics.data.v1alpha.MetricHeader.Builder, + com.google.analytics.data.v1alpha.MetricHeaderOrBuilder> + getMetricHeadersFieldBuilder() { + if (metricHeadersBuilder_ == null) { + metricHeadersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.MetricHeader, + com.google.analytics.data.v1alpha.MetricHeader.Builder, + com.google.analytics.data.v1alpha.MetricHeaderOrBuilder>( + metricHeaders_, + ((bitField0_ & 0x00000002) != 0), + getParentForChildren(), + isClean()); + metricHeaders_ = null; + } + return metricHeadersBuilder_; + } + + private java.util.List rows_ = + java.util.Collections.emptyList(); + + private void ensureRowsIsMutable() { + if (!((bitField0_ & 0x00000004) != 0)) { + rows_ = new java.util.ArrayList(rows_); + bitField0_ |= 0x00000004; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.Row, + com.google.analytics.data.v1alpha.Row.Builder, + com.google.analytics.data.v1alpha.RowOrBuilder> + rowsBuilder_; + + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public java.util.List getRowsList() { + if (rowsBuilder_ == null) { + return java.util.Collections.unmodifiableList(rows_); + } else { + return rowsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public int getRowsCount() { + if (rowsBuilder_ == null) { + return rows_.size(); + } else { + return rowsBuilder_.getCount(); + } + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public com.google.analytics.data.v1alpha.Row getRows(int index) { + if (rowsBuilder_ == null) { + return rows_.get(index); + } else { + return rowsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder setRows(int index, com.google.analytics.data.v1alpha.Row value) { + if (rowsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRowsIsMutable(); + rows_.set(index, value); + onChanged(); + } else { + rowsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder setRows( + int index, com.google.analytics.data.v1alpha.Row.Builder builderForValue) { + if (rowsBuilder_ == null) { + ensureRowsIsMutable(); + rows_.set(index, builderForValue.build()); + onChanged(); + } else { + rowsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder addRows(com.google.analytics.data.v1alpha.Row value) { + if (rowsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRowsIsMutable(); + rows_.add(value); + onChanged(); + } else { + rowsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder addRows(int index, com.google.analytics.data.v1alpha.Row value) { + if (rowsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRowsIsMutable(); + rows_.add(index, value); + onChanged(); + } else { + rowsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder addRows(com.google.analytics.data.v1alpha.Row.Builder builderForValue) { + if (rowsBuilder_ == null) { + ensureRowsIsMutable(); + rows_.add(builderForValue.build()); + onChanged(); + } else { + rowsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder addRows( + int index, com.google.analytics.data.v1alpha.Row.Builder builderForValue) { + if (rowsBuilder_ == null) { + ensureRowsIsMutable(); + rows_.add(index, builderForValue.build()); + onChanged(); + } else { + rowsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder addAllRows( + java.lang.Iterable values) { + if (rowsBuilder_ == null) { + ensureRowsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, rows_); + onChanged(); + } else { + rowsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder clearRows() { + if (rowsBuilder_ == null) { + rows_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + } else { + rowsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public Builder removeRows(int index) { + if (rowsBuilder_ == null) { + ensureRowsIsMutable(); + rows_.remove(index); + onChanged(); + } else { + rowsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public com.google.analytics.data.v1alpha.Row.Builder getRowsBuilder(int index) { + return getRowsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public com.google.analytics.data.v1alpha.RowOrBuilder getRowsOrBuilder(int index) { + if (rowsBuilder_ == null) { + return rows_.get(index); + } else { + return rowsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public java.util.List + getRowsOrBuilderList() { + if (rowsBuilder_ != null) { + return rowsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(rows_); + } + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public com.google.analytics.data.v1alpha.Row.Builder addRowsBuilder() { + return getRowsFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.Row.getDefaultInstance()); + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public com.google.analytics.data.v1alpha.Row.Builder addRowsBuilder(int index) { + return getRowsFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.Row.getDefaultInstance()); + } + /** + * + * + *
+     * Rows of dimension value combinations and metric values in the report.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + public java.util.List getRowsBuilderList() { + return getRowsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.Row, + com.google.analytics.data.v1alpha.Row.Builder, + com.google.analytics.data.v1alpha.RowOrBuilder> + getRowsFieldBuilder() { + if (rowsBuilder_ == null) { + rowsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.Row, + com.google.analytics.data.v1alpha.Row.Builder, + com.google.analytics.data.v1alpha.RowOrBuilder>( + rows_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); + rows_ = null; + } + return rowsBuilder_; + } + + private com.google.analytics.data.v1alpha.FunnelResponseMetadata metadata_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelResponseMetadata, + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder, + com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder> + metadataBuilder_; + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * + * @return Whether the metadata field is set. + */ + public boolean hasMetadata() { + return metadataBuilder_ != null || metadata_ != null; + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * + * @return The metadata. + */ + public com.google.analytics.data.v1alpha.FunnelResponseMetadata getMetadata() { + if (metadataBuilder_ == null) { + return metadata_ == null + ? com.google.analytics.data.v1alpha.FunnelResponseMetadata.getDefaultInstance() + : metadata_; + } else { + return metadataBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + public Builder setMetadata(com.google.analytics.data.v1alpha.FunnelResponseMetadata value) { + if (metadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + metadata_ = value; + onChanged(); + } else { + metadataBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + public Builder setMetadata( + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder builderForValue) { + if (metadataBuilder_ == null) { + metadata_ = builderForValue.build(); + onChanged(); + } else { + metadataBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + public Builder mergeMetadata(com.google.analytics.data.v1alpha.FunnelResponseMetadata value) { + if (metadataBuilder_ == null) { + if (metadata_ != null) { + metadata_ = + com.google.analytics.data.v1alpha.FunnelResponseMetadata.newBuilder(metadata_) + .mergeFrom(value) + .buildPartial(); + } else { + metadata_ = value; + } + onChanged(); + } else { + metadataBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + public Builder clearMetadata() { + if (metadataBuilder_ == null) { + metadata_ = null; + onChanged(); + } else { + metadata_ = null; + metadataBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + public com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder getMetadataBuilder() { + + onChanged(); + return getMetadataFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + public com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder + getMetadataOrBuilder() { + if (metadataBuilder_ != null) { + return metadataBuilder_.getMessageOrBuilder(); + } else { + return metadata_ == null + ? com.google.analytics.data.v1alpha.FunnelResponseMetadata.getDefaultInstance() + : metadata_; + } + } + /** + * + * + *
+     * Metadata for the funnel report.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelResponseMetadata, + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder, + com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder> + getMetadataFieldBuilder() { + if (metadataBuilder_ == null) { + metadataBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelResponseMetadata, + com.google.analytics.data.v1alpha.FunnelResponseMetadata.Builder, + com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder>( + getMetadata(), getParentForChildren(), isClean()); + metadata_ = null; + } + return metadataBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.FunnelSubReport) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.FunnelSubReport) + private static final com.google.analytics.data.v1alpha.FunnelSubReport DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.FunnelSubReport(); + } + + public static com.google.analytics.data.v1alpha.FunnelSubReport getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FunnelSubReport parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new FunnelSubReport(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.FunnelSubReport getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReportOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReportOrBuilder.java new file mode 100644 index 00000000..086a14da --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/FunnelSubReportOrBuilder.java @@ -0,0 +1,236 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface FunnelSubReportOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.FunnelSubReport) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + java.util.List getDimensionHeadersList(); + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + com.google.analytics.data.v1alpha.DimensionHeader getDimensionHeaders(int index); + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + int getDimensionHeadersCount(); + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + java.util.List + getDimensionHeadersOrBuilderList(); + /** + * + * + *
+   * Describes dimension columns. Funnel reports always include the funnel step
+   * dimension in sub report responses. Additional dimensions like breakdowns,
+   * dates, and next actions may be present in the response if requested.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + com.google.analytics.data.v1alpha.DimensionHeaderOrBuilder getDimensionHeadersOrBuilder( + int index); + + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + java.util.List getMetricHeadersList(); + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + com.google.analytics.data.v1alpha.MetricHeader getMetricHeaders(int index); + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + int getMetricHeadersCount(); + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + java.util.List + getMetricHeadersOrBuilderList(); + /** + * + * + *
+   * Describes metric columns. Funnel reports always include active users in sub
+   * report responses. The funnel table includes additional metrics like
+   * completion rate, abandonments, and abandonments rate.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + com.google.analytics.data.v1alpha.MetricHeaderOrBuilder getMetricHeadersOrBuilder(int index); + + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + java.util.List getRowsList(); + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + com.google.analytics.data.v1alpha.Row getRows(int index); + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + int getRowsCount(); + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + java.util.List getRowsOrBuilderList(); + /** + * + * + *
+   * Rows of dimension value combinations and metric values in the report.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + com.google.analytics.data.v1alpha.RowOrBuilder getRowsOrBuilder(int index); + + /** + * + * + *
+   * Metadata for the funnel report.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * + * @return Whether the metadata field is set. + */ + boolean hasMetadata(); + /** + * + * + *
+   * Metadata for the funnel report.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * + * @return The metadata. + */ + com.google.analytics.data.v1alpha.FunnelResponseMetadata getMetadata(); + /** + * + * + *
+   * Metadata for the funnel report.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + com.google.analytics.data.v1alpha.FunnelResponseMetadataOrBuilder getMetadataOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilter.java new file mode 100644 index 00000000..b25649d5 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilter.java @@ -0,0 +1,840 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The result needs to be in a list of string values.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.InListFilter} + */ +public final class InListFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.InListFilter) + InListFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use InListFilter.newBuilder() to construct. + private InListFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private InListFilter() { + values_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new InListFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private InListFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + values_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + values_.add(s); + break; + } + case 16: + { + caseSensitive_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + values_ = values_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_InListFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_InListFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.InListFilter.class, + com.google.analytics.data.v1alpha.InListFilter.Builder.class); + } + + public static final int VALUES_FIELD_NUMBER = 1; + private com.google.protobuf.LazyStringList values_; + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @return A list containing the values. + */ + public com.google.protobuf.ProtocolStringList getValuesList() { + return values_; + } + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @return The count of values. + */ + public int getValuesCount() { + return values_.size(); + } + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @param index The index of the element to return. + * @return The values at the given index. + */ + public java.lang.String getValues(int index) { + return values_.get(index); + } + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @param index The index of the value to return. + * @return The bytes of the values at the given index. + */ + public com.google.protobuf.ByteString getValuesBytes(int index) { + return values_.getByteString(index); + } + + public static final int CASE_SENSITIVE_FIELD_NUMBER = 2; + private boolean caseSensitive_; + /** + * + * + *
+   * If true, the string value is case sensitive.
+   * 
+ * + * bool case_sensitive = 2; + * + * @return The caseSensitive. + */ + @java.lang.Override + public boolean getCaseSensitive() { + return caseSensitive_; + } + + 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 < values_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, values_.getRaw(i)); + } + if (caseSensitive_ != false) { + output.writeBool(2, caseSensitive_); + } + unknownFields.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 < values_.size(); i++) { + dataSize += computeStringSizeNoTag(values_.getRaw(i)); + } + size += dataSize; + size += 1 * getValuesList().size(); + } + if (caseSensitive_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, caseSensitive_); + } + size += unknownFields.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.analytics.data.v1alpha.InListFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.InListFilter other = + (com.google.analytics.data.v1alpha.InListFilter) obj; + + if (!getValuesList().equals(other.getValuesList())) return false; + if (getCaseSensitive() != other.getCaseSensitive()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getValuesCount() > 0) { + hash = (37 * hash) + VALUES_FIELD_NUMBER; + hash = (53 * hash) + getValuesList().hashCode(); + } + hash = (37 * hash) + CASE_SENSITIVE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getCaseSensitive()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.InListFilter 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.analytics.data.v1alpha.InListFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.InListFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.InListFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The result needs to be in a list of string values.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.InListFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.InListFilter) + com.google.analytics.data.v1alpha.InListFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_InListFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_InListFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.InListFilter.class, + com.google.analytics.data.v1alpha.InListFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.InListFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + values_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + caseSensitive_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_InListFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter build() { + com.google.analytics.data.v1alpha.InListFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter buildPartial() { + com.google.analytics.data.v1alpha.InListFilter result = + new com.google.analytics.data.v1alpha.InListFilter(this); + int from_bitField0_ = bitField0_; + if (((bitField0_ & 0x00000001) != 0)) { + values_ = values_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.values_ = values_; + result.caseSensitive_ = caseSensitive_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.InListFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.InListFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.InListFilter other) { + if (other == com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance()) return this; + if (!other.values_.isEmpty()) { + if (values_.isEmpty()) { + values_ = other.values_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureValuesIsMutable(); + values_.addAll(other.values_); + } + onChanged(); + } + if (other.getCaseSensitive() != false) { + setCaseSensitive(other.getCaseSensitive()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.InListFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.InListFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringList values_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureValuesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + values_ = new com.google.protobuf.LazyStringArrayList(values_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @return A list containing the values. + */ + public com.google.protobuf.ProtocolStringList getValuesList() { + return values_.getUnmodifiableView(); + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @return The count of values. + */ + public int getValuesCount() { + return values_.size(); + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @param index The index of the element to return. + * @return The values at the given index. + */ + public java.lang.String getValues(int index) { + return values_.get(index); + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @param index The index of the value to return. + * @return The bytes of the values at the given index. + */ + public com.google.protobuf.ByteString getValuesBytes(int index) { + return values_.getByteString(index); + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @param index The index to set the value at. + * @param value The values to set. + * @return This builder for chaining. + */ + public Builder setValues(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureValuesIsMutable(); + values_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @param value The values to add. + * @return This builder for chaining. + */ + public Builder addValues(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureValuesIsMutable(); + values_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @param values The values to add. + * @return This builder for chaining. + */ + public Builder addAllValues(java.lang.Iterable values) { + ensureValuesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, values_); + onChanged(); + return this; + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @return This builder for chaining. + */ + public Builder clearValues() { + values_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+     * The list of string values.
+     * Must be non-empty.
+     * 
+ * + * repeated string values = 1; + * + * @param value The bytes of the values to add. + * @return This builder for chaining. + */ + public Builder addValuesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureValuesIsMutable(); + values_.add(value); + onChanged(); + return this; + } + + private boolean caseSensitive_; + /** + * + * + *
+     * If true, the string value is case sensitive.
+     * 
+ * + * bool case_sensitive = 2; + * + * @return The caseSensitive. + */ + @java.lang.Override + public boolean getCaseSensitive() { + return caseSensitive_; + } + /** + * + * + *
+     * If true, the string value is case sensitive.
+     * 
+ * + * bool case_sensitive = 2; + * + * @param value The caseSensitive to set. + * @return This builder for chaining. + */ + public Builder setCaseSensitive(boolean value) { + + caseSensitive_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If true, the string value is case sensitive.
+     * 
+ * + * bool case_sensitive = 2; + * + * @return This builder for chaining. + */ + public Builder clearCaseSensitive() { + + caseSensitive_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.InListFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.InListFilter) + private static final com.google.analytics.data.v1alpha.InListFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.InListFilter(); + } + + public static com.google.analytics.data.v1alpha.InListFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public InListFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new InListFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.InListFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilterOrBuilder.java new file mode 100644 index 00000000..b857975e --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/InListFilterOrBuilder.java @@ -0,0 +1,93 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface InListFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.InListFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @return A list containing the values. + */ + java.util.List getValuesList(); + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @return The count of values. + */ + int getValuesCount(); + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @param index The index of the element to return. + * @return The values at the given index. + */ + java.lang.String getValues(int index); + /** + * + * + *
+   * The list of string values.
+   * Must be non-empty.
+   * 
+ * + * repeated string values = 1; + * + * @param index The index of the value to return. + * @return The bytes of the values at the given index. + */ + com.google.protobuf.ByteString getValuesBytes(int index); + + /** + * + * + *
+   * If true, the string value is case sensitive.
+   * 
+ * + * bool case_sensitive = 2; + * + * @return The caseSensitive. + */ + boolean getCaseSensitive(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeader.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeader.java new file mode 100644 index 00000000..b2605e77 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeader.java @@ -0,0 +1,792 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Describes a metric column in the report. Visible metrics requested in a
+ * report produce column entries within rows and MetricHeaders. However,
+ * metrics used exclusively within filters or expressions do not produce columns
+ * in a report; correspondingly, those metrics do not produce headers.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.MetricHeader} + */ +public final class MetricHeader extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.MetricHeader) + MetricHeaderOrBuilder { + private static final long serialVersionUID = 0L; + // Use MetricHeader.newBuilder() to construct. + private MetricHeader(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private MetricHeader() { + name_ = ""; + type_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new MetricHeader(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private MetricHeader( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + name_ = s; + break; + } + case 16: + { + int rawValue = input.readEnum(); + + type_ = rawValue; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricHeader_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricHeader_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.MetricHeader.class, + com.google.analytics.data.v1alpha.MetricHeader.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The metric's name.
+   * 
+ * + * 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 metric's name.
+   * 
+ * + * 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 TYPE_FIELD_NUMBER = 2; + private int type_; + /** + * + * + *
+   * The metric's data type.
+   * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+   * The metric's data type.
+   * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return The type. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricType getType() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.MetricType result = + com.google.analytics.data.v1alpha.MetricType.valueOf(type_); + return result == null ? com.google.analytics.data.v1alpha.MetricType.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 (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (type_ != com.google.analytics.data.v1alpha.MetricType.METRIC_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(2, type_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (type_ != com.google.analytics.data.v1alpha.MetricType.METRIC_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, type_); + } + size += unknownFields.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.analytics.data.v1alpha.MetricHeader)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.MetricHeader other = + (com.google.analytics.data.v1alpha.MetricHeader) obj; + + if (!getName().equals(other.getName())) return false; + if (type_ != other.type_) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.MetricHeader 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.analytics.data.v1alpha.MetricHeader parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.MetricHeader parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.MetricHeader 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Describes a metric column in the report. Visible metrics requested in a
+   * report produce column entries within rows and MetricHeaders. However,
+   * metrics used exclusively within filters or expressions do not produce columns
+   * in a report; correspondingly, those metrics do not produce headers.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.MetricHeader} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.MetricHeader) + com.google.analytics.data.v1alpha.MetricHeaderOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricHeader_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricHeader_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.MetricHeader.class, + com.google.analytics.data.v1alpha.MetricHeader.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.MetricHeader.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + type_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricHeader_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricHeader getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.MetricHeader.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricHeader build() { + com.google.analytics.data.v1alpha.MetricHeader result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricHeader buildPartial() { + com.google.analytics.data.v1alpha.MetricHeader result = + new com.google.analytics.data.v1alpha.MetricHeader(this); + result.name_ = name_; + result.type_ = type_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.MetricHeader) { + return mergeFrom((com.google.analytics.data.v1alpha.MetricHeader) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.MetricHeader other) { + if (other == com.google.analytics.data.v1alpha.MetricHeader.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.MetricHeader parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.MetricHeader) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The metric's name.
+     * 
+ * + * 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 metric's name.
+     * 
+ * + * 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 metric's name.
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The metric's name.
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The metric's name.
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private int type_ = 0; + /** + * + * + *
+     * The metric's data type.
+     * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+     * The metric's data type.
+     * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The metric's data type.
+     * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return The type. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricType getType() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.MetricType result = + com.google.analytics.data.v1alpha.MetricType.valueOf(type_); + return result == null ? com.google.analytics.data.v1alpha.MetricType.UNRECOGNIZED : result; + } + /** + * + * + *
+     * The metric's data type.
+     * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.analytics.data.v1alpha.MetricType value) { + if (value == null) { + throw new NullPointerException(); + } + + type_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The metric's data type.
+     * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return This builder for chaining. + */ + public Builder clearType() { + + type_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.MetricHeader) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.MetricHeader) + private static final com.google.analytics.data.v1alpha.MetricHeader DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.MetricHeader(); + } + + public static com.google.analytics.data.v1alpha.MetricHeader getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MetricHeader parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new MetricHeader(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.MetricHeader getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeaderOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeaderOrBuilder.java new file mode 100644 index 00000000..afb74089 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricHeaderOrBuilder.java @@ -0,0 +1,75 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface MetricHeaderOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.MetricHeader) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The metric's name.
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The metric's name.
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * The metric's data type.
+   * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + /** + * + * + *
+   * The metric's data type.
+   * 
+ * + * .google.analytics.data.v1alpha.MetricType type = 2; + * + * @return The type. + */ + com.google.analytics.data.v1alpha.MetricType getType(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricType.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricType.java new file mode 100644 index 00000000..96026dd4 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricType.java @@ -0,0 +1,398 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A metric's value type.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.MetricType} + */ +public enum MetricType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified type.
+   * 
+ * + * METRIC_TYPE_UNSPECIFIED = 0; + */ + METRIC_TYPE_UNSPECIFIED(0), + /** + * + * + *
+   * Integer type.
+   * 
+ * + * TYPE_INTEGER = 1; + */ + TYPE_INTEGER(1), + /** + * + * + *
+   * Floating point type.
+   * 
+ * + * TYPE_FLOAT = 2; + */ + TYPE_FLOAT(2), + /** + * + * + *
+   * A duration of seconds; a special floating point type.
+   * 
+ * + * TYPE_SECONDS = 4; + */ + TYPE_SECONDS(4), + /** + * + * + *
+   * A duration in milliseconds; a special floating point type.
+   * 
+ * + * TYPE_MILLISECONDS = 5; + */ + TYPE_MILLISECONDS(5), + /** + * + * + *
+   * A duration in minutes; a special floating point type.
+   * 
+ * + * TYPE_MINUTES = 6; + */ + TYPE_MINUTES(6), + /** + * + * + *
+   * A duration in hours; a special floating point type.
+   * 
+ * + * TYPE_HOURS = 7; + */ + TYPE_HOURS(7), + /** + * + * + *
+   * A custom metric of standard type; a special floating point type.
+   * 
+ * + * TYPE_STANDARD = 8; + */ + TYPE_STANDARD(8), + /** + * + * + *
+   * An amount of money; a special floating point type.
+   * 
+ * + * TYPE_CURRENCY = 9; + */ + TYPE_CURRENCY(9), + /** + * + * + *
+   * A length in feet; a special floating point type.
+   * 
+ * + * TYPE_FEET = 10; + */ + TYPE_FEET(10), + /** + * + * + *
+   * A length in miles; a special floating point type.
+   * 
+ * + * TYPE_MILES = 11; + */ + TYPE_MILES(11), + /** + * + * + *
+   * A length in meters; a special floating point type.
+   * 
+ * + * TYPE_METERS = 12; + */ + TYPE_METERS(12), + /** + * + * + *
+   * A length in kilometers; a special floating point type.
+   * 
+ * + * TYPE_KILOMETERS = 13; + */ + TYPE_KILOMETERS(13), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified type.
+   * 
+ * + * METRIC_TYPE_UNSPECIFIED = 0; + */ + public static final int METRIC_TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * Integer type.
+   * 
+ * + * TYPE_INTEGER = 1; + */ + public static final int TYPE_INTEGER_VALUE = 1; + /** + * + * + *
+   * Floating point type.
+   * 
+ * + * TYPE_FLOAT = 2; + */ + public static final int TYPE_FLOAT_VALUE = 2; + /** + * + * + *
+   * A duration of seconds; a special floating point type.
+   * 
+ * + * TYPE_SECONDS = 4; + */ + public static final int TYPE_SECONDS_VALUE = 4; + /** + * + * + *
+   * A duration in milliseconds; a special floating point type.
+   * 
+ * + * TYPE_MILLISECONDS = 5; + */ + public static final int TYPE_MILLISECONDS_VALUE = 5; + /** + * + * + *
+   * A duration in minutes; a special floating point type.
+   * 
+ * + * TYPE_MINUTES = 6; + */ + public static final int TYPE_MINUTES_VALUE = 6; + /** + * + * + *
+   * A duration in hours; a special floating point type.
+   * 
+ * + * TYPE_HOURS = 7; + */ + public static final int TYPE_HOURS_VALUE = 7; + /** + * + * + *
+   * A custom metric of standard type; a special floating point type.
+   * 
+ * + * TYPE_STANDARD = 8; + */ + public static final int TYPE_STANDARD_VALUE = 8; + /** + * + * + *
+   * An amount of money; a special floating point type.
+   * 
+ * + * TYPE_CURRENCY = 9; + */ + public static final int TYPE_CURRENCY_VALUE = 9; + /** + * + * + *
+   * A length in feet; a special floating point type.
+   * 
+ * + * TYPE_FEET = 10; + */ + public static final int TYPE_FEET_VALUE = 10; + /** + * + * + *
+   * A length in miles; a special floating point type.
+   * 
+ * + * TYPE_MILES = 11; + */ + public static final int TYPE_MILES_VALUE = 11; + /** + * + * + *
+   * A length in meters; a special floating point type.
+   * 
+ * + * TYPE_METERS = 12; + */ + public static final int TYPE_METERS_VALUE = 12; + /** + * + * + *
+   * A length in kilometers; a special floating point type.
+   * 
+ * + * TYPE_KILOMETERS = 13; + */ + public static final int TYPE_KILOMETERS_VALUE = 13; + + 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 MetricType 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 MetricType forNumber(int value) { + switch (value) { + case 0: + return METRIC_TYPE_UNSPECIFIED; + case 1: + return TYPE_INTEGER; + case 2: + return TYPE_FLOAT; + case 4: + return TYPE_SECONDS; + case 5: + return TYPE_MILLISECONDS; + case 6: + return TYPE_MINUTES; + case 7: + return TYPE_HOURS; + case 8: + return TYPE_STANDARD; + case 9: + return TYPE_CURRENCY; + case 10: + return TYPE_FEET; + case 11: + return TYPE_MILES; + case 12: + return TYPE_METERS; + case 13: + return TYPE_KILOMETERS; + 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 MetricType findValueByNumber(int number) { + return MetricType.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(6); + } + + private static final MetricType[] VALUES = values(); + + public static MetricType 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 MetricType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.MetricType) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValue.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValue.java new file mode 100644 index 00000000..98b33c48 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValue.java @@ -0,0 +1,766 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The value of a metric.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.MetricValue} + */ +public final class MetricValue extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.MetricValue) + MetricValueOrBuilder { + private static final long serialVersionUID = 0L; + // Use MetricValue.newBuilder() to construct. + private MetricValue(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private MetricValue() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new MetricValue(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private MetricValue( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + oneValueCase_ = 4; + oneValue_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricValue_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricValue_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.MetricValue.class, + com.google.analytics.data.v1alpha.MetricValue.Builder.class); + } + + private int oneValueCase_ = 0; + private java.lang.Object oneValue_; + + public enum OneValueCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + VALUE(4), + ONEVALUE_NOT_SET(0); + private final int value; + + private OneValueCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneValueCase valueOf(int value) { + return forNumber(value); + } + + public static OneValueCase forNumber(int value) { + switch (value) { + case 4: + return VALUE; + case 0: + return ONEVALUE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneValueCase getOneValueCase() { + return OneValueCase.forNumber(oneValueCase_); + } + + public static final int VALUE_FIELD_NUMBER = 4; + /** + * + * + *
+   * Measurement value. See MetricHeader for type.
+   * 
+ * + * string value = 4; + * + * @return Whether the value field is set. + */ + public boolean hasValue() { + return oneValueCase_ == 4; + } + /** + * + * + *
+   * Measurement value. See MetricHeader for type.
+   * 
+ * + * string value = 4; + * + * @return The value. + */ + public java.lang.String getValue() { + java.lang.Object ref = ""; + if (oneValueCase_ == 4) { + ref = oneValue_; + } + 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(); + if (oneValueCase_ == 4) { + oneValue_ = s; + } + return s; + } + } + /** + * + * + *
+   * Measurement value. See MetricHeader for type.
+   * 
+ * + * string value = 4; + * + * @return The bytes for value. + */ + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = ""; + if (oneValueCase_ == 4) { + ref = oneValue_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneValueCase_ == 4) { + oneValue_ = 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 (oneValueCase_ == 4) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, oneValue_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (oneValueCase_ == 4) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, oneValue_); + } + size += unknownFields.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.analytics.data.v1alpha.MetricValue)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.MetricValue other = + (com.google.analytics.data.v1alpha.MetricValue) obj; + + if (!getOneValueCase().equals(other.getOneValueCase())) return false; + switch (oneValueCase_) { + case 4: + if (!getValue().equals(other.getValue())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (oneValueCase_) { + case 4: + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.MetricValue 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.analytics.data.v1alpha.MetricValue parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.MetricValue parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.MetricValue 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The value of a metric.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.MetricValue} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.MetricValue) + com.google.analytics.data.v1alpha.MetricValueOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricValue_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricValue_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.MetricValue.class, + com.google.analytics.data.v1alpha.MetricValue.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.MetricValue.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + oneValueCase_ = 0; + oneValue_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_MetricValue_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricValue getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.MetricValue.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricValue build() { + com.google.analytics.data.v1alpha.MetricValue result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricValue buildPartial() { + com.google.analytics.data.v1alpha.MetricValue result = + new com.google.analytics.data.v1alpha.MetricValue(this); + if (oneValueCase_ == 4) { + result.oneValue_ = oneValue_; + } + result.oneValueCase_ = oneValueCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.MetricValue) { + return mergeFrom((com.google.analytics.data.v1alpha.MetricValue) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.MetricValue other) { + if (other == com.google.analytics.data.v1alpha.MetricValue.getDefaultInstance()) return this; + switch (other.getOneValueCase()) { + case VALUE: + { + oneValueCase_ = 4; + oneValue_ = other.oneValue_; + onChanged(); + break; + } + case ONEVALUE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.MetricValue parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.MetricValue) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneValueCase_ = 0; + private java.lang.Object oneValue_; + + public OneValueCase getOneValueCase() { + return OneValueCase.forNumber(oneValueCase_); + } + + public Builder clearOneValue() { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + return this; + } + + /** + * + * + *
+     * Measurement value. See MetricHeader for type.
+     * 
+ * + * string value = 4; + * + * @return Whether the value field is set. + */ + @java.lang.Override + public boolean hasValue() { + return oneValueCase_ == 4; + } + /** + * + * + *
+     * Measurement value. See MetricHeader for type.
+     * 
+ * + * string value = 4; + * + * @return The value. + */ + @java.lang.Override + public java.lang.String getValue() { + java.lang.Object ref = ""; + if (oneValueCase_ == 4) { + ref = oneValue_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (oneValueCase_ == 4) { + oneValue_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Measurement value. See MetricHeader for type.
+     * 
+ * + * string value = 4; + * + * @return The bytes for value. + */ + @java.lang.Override + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = ""; + if (oneValueCase_ == 4) { + ref = oneValue_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneValueCase_ == 4) { + oneValue_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Measurement value. See MetricHeader for type.
+     * 
+ * + * string value = 4; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + oneValueCase_ = 4; + oneValue_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Measurement value. See MetricHeader for type.
+     * 
+ * + * string value = 4; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + if (oneValueCase_ == 4) { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * Measurement value. See MetricHeader for type.
+     * 
+ * + * string value = 4; + * + * @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); + oneValueCase_ = 4; + oneValue_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.MetricValue) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.MetricValue) + private static final com.google.analytics.data.v1alpha.MetricValue DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.MetricValue(); + } + + public static com.google.analytics.data.v1alpha.MetricValue getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MetricValue parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new MetricValue(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.MetricValue getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValueOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValueOrBuilder.java new file mode 100644 index 00000000..b5a984e9 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/MetricValueOrBuilder.java @@ -0,0 +1,64 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface MetricValueOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.MetricValue) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Measurement value. See MetricHeader for type.
+   * 
+ * + * string value = 4; + * + * @return Whether the value field is set. + */ + boolean hasValue(); + /** + * + * + *
+   * Measurement value. See MetricHeader for type.
+   * 
+ * + * string value = 4; + * + * @return The value. + */ + java.lang.String getValue(); + /** + * + * + *
+   * Measurement value. See MetricHeader for type.
+   * 
+ * + * string value = 4; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); + + public com.google.analytics.data.v1alpha.MetricValue.OneValueCase getOneValueCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilter.java new file mode 100644 index 00000000..63121287 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilter.java @@ -0,0 +1,1117 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Filters for numeric or date values.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.NumericFilter} + */ +public final class NumericFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.NumericFilter) + NumericFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use NumericFilter.newBuilder() to construct. + private NumericFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private NumericFilter() { + operation_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new NumericFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private NumericFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + operation_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.NumericValue.Builder subBuilder = null; + if (value_ != null) { + subBuilder = value_.toBuilder(); + } + value_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericValue.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(value_); + value_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.NumericFilter.class, + com.google.analytics.data.v1alpha.NumericFilter.Builder.class); + } + + /** + * + * + *
+   * The operation applied to a numeric filter
+   * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.NumericFilter.Operation} + */ + public enum Operation implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified.
+     * 
+ * + * OPERATION_UNSPECIFIED = 0; + */ + OPERATION_UNSPECIFIED(0), + /** + * + * + *
+     * Equal
+     * 
+ * + * EQUAL = 1; + */ + EQUAL(1), + /** + * + * + *
+     * Less than
+     * 
+ * + * LESS_THAN = 2; + */ + LESS_THAN(2), + /** + * + * + *
+     * Less than or equal
+     * 
+ * + * LESS_THAN_OR_EQUAL = 3; + */ + LESS_THAN_OR_EQUAL(3), + /** + * + * + *
+     * Greater than
+     * 
+ * + * GREATER_THAN = 4; + */ + GREATER_THAN(4), + /** + * + * + *
+     * Greater than or equal
+     * 
+ * + * GREATER_THAN_OR_EQUAL = 5; + */ + GREATER_THAN_OR_EQUAL(5), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unspecified.
+     * 
+ * + * OPERATION_UNSPECIFIED = 0; + */ + public static final int OPERATION_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * Equal
+     * 
+ * + * EQUAL = 1; + */ + public static final int EQUAL_VALUE = 1; + /** + * + * + *
+     * Less than
+     * 
+ * + * LESS_THAN = 2; + */ + public static final int LESS_THAN_VALUE = 2; + /** + * + * + *
+     * Less than or equal
+     * 
+ * + * LESS_THAN_OR_EQUAL = 3; + */ + public static final int LESS_THAN_OR_EQUAL_VALUE = 3; + /** + * + * + *
+     * Greater than
+     * 
+ * + * GREATER_THAN = 4; + */ + public static final int GREATER_THAN_VALUE = 4; + /** + * + * + *
+     * Greater than or equal
+     * 
+ * + * GREATER_THAN_OR_EQUAL = 5; + */ + public static final int GREATER_THAN_OR_EQUAL_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 Operation 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 Operation forNumber(int value) { + switch (value) { + case 0: + return OPERATION_UNSPECIFIED; + case 1: + return EQUAL; + case 2: + return LESS_THAN; + case 3: + return LESS_THAN_OR_EQUAL; + case 4: + return GREATER_THAN; + case 5: + return GREATER_THAN_OR_EQUAL; + 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 Operation findValueByNumber(int number) { + return Operation.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.NumericFilter.getDescriptor().getEnumTypes().get(0); + } + + private static final Operation[] VALUES = values(); + + public static Operation 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 Operation(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.NumericFilter.Operation) + } + + public static final int OPERATION_FIELD_NUMBER = 1; + private int operation_; + /** + * + * + *
+   * The operation type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return The enum numeric value on the wire for operation. + */ + @java.lang.Override + public int getOperationValue() { + return operation_; + } + /** + * + * + *
+   * The operation type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return The operation. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter.Operation getOperation() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.NumericFilter.Operation result = + com.google.analytics.data.v1alpha.NumericFilter.Operation.valueOf(operation_); + return result == null + ? com.google.analytics.data.v1alpha.NumericFilter.Operation.UNRECOGNIZED + : result; + } + + public static final int VALUE_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.NumericValue value_; + /** + * + * + *
+   * A numeric value or a date value.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + * + * @return Whether the value field is set. + */ + @java.lang.Override + public boolean hasValue() { + return value_ != null; + } + /** + * + * + *
+   * A numeric value or a date value.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + * + * @return The value. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValue getValue() { + return value_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : value_; + } + /** + * + * + *
+   * A numeric value or a date value.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValueOrBuilder getValueOrBuilder() { + return getValue(); + } + + 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 (operation_ + != com.google.analytics.data.v1alpha.NumericFilter.Operation.OPERATION_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, operation_); + } + if (value_ != null) { + output.writeMessage(2, getValue()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (operation_ + != com.google.analytics.data.v1alpha.NumericFilter.Operation.OPERATION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, operation_); + } + if (value_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getValue()); + } + size += unknownFields.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.analytics.data.v1alpha.NumericFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.NumericFilter other = + (com.google.analytics.data.v1alpha.NumericFilter) obj; + + if (operation_ != other.operation_) return false; + if (hasValue() != other.hasValue()) return false; + if (hasValue()) { + if (!getValue().equals(other.getValue())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + OPERATION_FIELD_NUMBER; + hash = (53 * hash) + operation_; + if (hasValue()) { + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.NumericFilter 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.analytics.data.v1alpha.NumericFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.NumericFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.NumericFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Filters for numeric or date values.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.NumericFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.NumericFilter) + com.google.analytics.data.v1alpha.NumericFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.NumericFilter.class, + com.google.analytics.data.v1alpha.NumericFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.NumericFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + operation_ = 0; + + if (valueBuilder_ == null) { + value_ = null; + } else { + value_ = null; + valueBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter build() { + com.google.analytics.data.v1alpha.NumericFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter buildPartial() { + com.google.analytics.data.v1alpha.NumericFilter result = + new com.google.analytics.data.v1alpha.NumericFilter(this); + result.operation_ = operation_; + if (valueBuilder_ == null) { + result.value_ = value_; + } else { + result.value_ = valueBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.NumericFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.NumericFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.NumericFilter other) { + if (other == com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance()) + return this; + if (other.operation_ != 0) { + setOperationValue(other.getOperationValue()); + } + if (other.hasValue()) { + mergeValue(other.getValue()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.NumericFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.NumericFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int operation_ = 0; + /** + * + * + *
+     * The operation type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return The enum numeric value on the wire for operation. + */ + @java.lang.Override + public int getOperationValue() { + return operation_; + } + /** + * + * + *
+     * The operation type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @param value The enum numeric value on the wire for operation to set. + * @return This builder for chaining. + */ + public Builder setOperationValue(int value) { + + operation_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The operation type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return The operation. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter.Operation getOperation() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.NumericFilter.Operation result = + com.google.analytics.data.v1alpha.NumericFilter.Operation.valueOf(operation_); + return result == null + ? com.google.analytics.data.v1alpha.NumericFilter.Operation.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * The operation type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @param value The operation to set. + * @return This builder for chaining. + */ + public Builder setOperation(com.google.analytics.data.v1alpha.NumericFilter.Operation value) { + if (value == null) { + throw new NullPointerException(); + } + + operation_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The operation type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return This builder for chaining. + */ + public Builder clearOperation() { + + operation_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.NumericValue value_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder> + valueBuilder_; + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + * + * @return Whether the value field is set. + */ + public boolean hasValue() { + return valueBuilder_ != null || value_ != null; + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + * + * @return The value. + */ + public com.google.analytics.data.v1alpha.NumericValue getValue() { + if (valueBuilder_ == null) { + return value_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : value_; + } else { + return valueBuilder_.getMessage(); + } + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + public Builder setValue(com.google.analytics.data.v1alpha.NumericValue value) { + if (valueBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + value_ = value; + onChanged(); + } else { + valueBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + public Builder setValue( + com.google.analytics.data.v1alpha.NumericValue.Builder builderForValue) { + if (valueBuilder_ == null) { + value_ = builderForValue.build(); + onChanged(); + } else { + valueBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + public Builder mergeValue(com.google.analytics.data.v1alpha.NumericValue value) { + if (valueBuilder_ == null) { + if (value_ != null) { + value_ = + com.google.analytics.data.v1alpha.NumericValue.newBuilder(value_) + .mergeFrom(value) + .buildPartial(); + } else { + value_ = value; + } + onChanged(); + } else { + valueBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + public Builder clearValue() { + if (valueBuilder_ == null) { + value_ = null; + onChanged(); + } else { + value_ = null; + valueBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + public com.google.analytics.data.v1alpha.NumericValue.Builder getValueBuilder() { + + onChanged(); + return getValueFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + public com.google.analytics.data.v1alpha.NumericValueOrBuilder getValueOrBuilder() { + if (valueBuilder_ != null) { + return valueBuilder_.getMessageOrBuilder(); + } else { + return value_ == null + ? com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance() + : value_; + } + } + /** + * + * + *
+     * A numeric value or a date value.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder> + getValueFieldBuilder() { + if (valueBuilder_ == null) { + valueBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericValue, + com.google.analytics.data.v1alpha.NumericValue.Builder, + com.google.analytics.data.v1alpha.NumericValueOrBuilder>( + getValue(), getParentForChildren(), isClean()); + value_ = null; + } + return valueBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.NumericFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.NumericFilter) + private static final com.google.analytics.data.v1alpha.NumericFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.NumericFilter(); + } + + public static com.google.analytics.data.v1alpha.NumericFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public NumericFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new NumericFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.NumericFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilterOrBuilder.java new file mode 100644 index 00000000..d7653660 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericFilterOrBuilder.java @@ -0,0 +1,85 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface NumericFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.NumericFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The operation type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return The enum numeric value on the wire for operation. + */ + int getOperationValue(); + /** + * + * + *
+   * The operation type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * + * @return The operation. + */ + com.google.analytics.data.v1alpha.NumericFilter.Operation getOperation(); + + /** + * + * + *
+   * A numeric value or a date value.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + * + * @return Whether the value field is set. + */ + boolean hasValue(); + /** + * + * + *
+   * A numeric value or a date value.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + * + * @return The value. + */ + com.google.analytics.data.v1alpha.NumericValue getValue(); + /** + * + * + *
+   * A numeric value or a date value.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericValue value = 2; + */ + com.google.analytics.data.v1alpha.NumericValueOrBuilder getValueOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValue.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValue.java new file mode 100644 index 00000000..6dc7d01d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValue.java @@ -0,0 +1,805 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * To represent a number.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.NumericValue} + */ +public final class NumericValue extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.NumericValue) + NumericValueOrBuilder { + private static final long serialVersionUID = 0L; + // Use NumericValue.newBuilder() to construct. + private NumericValue(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private NumericValue() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new NumericValue(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private NumericValue( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + oneValue_ = input.readInt64(); + oneValueCase_ = 1; + break; + } + case 17: + { + oneValue_ = input.readDouble(); + oneValueCase_ = 2; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericValue_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericValue_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.NumericValue.class, + com.google.analytics.data.v1alpha.NumericValue.Builder.class); + } + + private int oneValueCase_ = 0; + private java.lang.Object oneValue_; + + public enum OneValueCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + INT64_VALUE(1), + DOUBLE_VALUE(2), + ONEVALUE_NOT_SET(0); + private final int value; + + private OneValueCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneValueCase valueOf(int value) { + return forNumber(value); + } + + public static OneValueCase forNumber(int value) { + switch (value) { + case 1: + return INT64_VALUE; + case 2: + return DOUBLE_VALUE; + case 0: + return ONEVALUE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneValueCase getOneValueCase() { + return OneValueCase.forNumber(oneValueCase_); + } + + public static final int INT64_VALUE_FIELD_NUMBER = 1; + /** + * + * + *
+   * Integer value
+   * 
+ * + * int64 int64_value = 1; + * + * @return Whether the int64Value field is set. + */ + @java.lang.Override + public boolean hasInt64Value() { + return oneValueCase_ == 1; + } + /** + * + * + *
+   * Integer value
+   * 
+ * + * int64 int64_value = 1; + * + * @return The int64Value. + */ + @java.lang.Override + public long getInt64Value() { + if (oneValueCase_ == 1) { + return (java.lang.Long) oneValue_; + } + return 0L; + } + + public static final int DOUBLE_VALUE_FIELD_NUMBER = 2; + /** + * + * + *
+   * Double value
+   * 
+ * + * double double_value = 2; + * + * @return Whether the doubleValue field is set. + */ + @java.lang.Override + public boolean hasDoubleValue() { + return oneValueCase_ == 2; + } + /** + * + * + *
+   * Double value
+   * 
+ * + * double double_value = 2; + * + * @return The doubleValue. + */ + @java.lang.Override + public double getDoubleValue() { + if (oneValueCase_ == 2) { + return (java.lang.Double) oneValue_; + } + return 0D; + } + + 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 (oneValueCase_ == 1) { + output.writeInt64(1, (long) ((java.lang.Long) oneValue_)); + } + if (oneValueCase_ == 2) { + output.writeDouble(2, (double) ((java.lang.Double) oneValue_)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (oneValueCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeInt64Size( + 1, (long) ((java.lang.Long) oneValue_)); + } + if (oneValueCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeDoubleSize( + 2, (double) ((java.lang.Double) oneValue_)); + } + size += unknownFields.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.analytics.data.v1alpha.NumericValue)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.NumericValue other = + (com.google.analytics.data.v1alpha.NumericValue) obj; + + if (!getOneValueCase().equals(other.getOneValueCase())) return false; + switch (oneValueCase_) { + case 1: + if (getInt64Value() != other.getInt64Value()) return false; + break; + case 2: + if (java.lang.Double.doubleToLongBits(getDoubleValue()) + != java.lang.Double.doubleToLongBits(other.getDoubleValue())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (oneValueCase_) { + case 1: + hash = (37 * hash) + INT64_VALUE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getInt64Value()); + break; + case 2: + hash = (37 * hash) + DOUBLE_VALUE_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getDoubleValue())); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.NumericValue 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.analytics.data.v1alpha.NumericValue parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.NumericValue parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.NumericValue 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * To represent a number.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.NumericValue} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.NumericValue) + com.google.analytics.data.v1alpha.NumericValueOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericValue_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericValue_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.NumericValue.class, + com.google.analytics.data.v1alpha.NumericValue.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.NumericValue.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + oneValueCase_ = 0; + oneValue_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_NumericValue_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValue getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValue build() { + com.google.analytics.data.v1alpha.NumericValue result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericValue buildPartial() { + com.google.analytics.data.v1alpha.NumericValue result = + new com.google.analytics.data.v1alpha.NumericValue(this); + if (oneValueCase_ == 1) { + result.oneValue_ = oneValue_; + } + if (oneValueCase_ == 2) { + result.oneValue_ = oneValue_; + } + result.oneValueCase_ = oneValueCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.NumericValue) { + return mergeFrom((com.google.analytics.data.v1alpha.NumericValue) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.NumericValue other) { + if (other == com.google.analytics.data.v1alpha.NumericValue.getDefaultInstance()) return this; + switch (other.getOneValueCase()) { + case INT64_VALUE: + { + setInt64Value(other.getInt64Value()); + break; + } + case DOUBLE_VALUE: + { + setDoubleValue(other.getDoubleValue()); + break; + } + case ONEVALUE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.NumericValue parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.NumericValue) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneValueCase_ = 0; + private java.lang.Object oneValue_; + + public OneValueCase getOneValueCase() { + return OneValueCase.forNumber(oneValueCase_); + } + + public Builder clearOneValue() { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + return this; + } + + /** + * + * + *
+     * Integer value
+     * 
+ * + * int64 int64_value = 1; + * + * @return Whether the int64Value field is set. + */ + public boolean hasInt64Value() { + return oneValueCase_ == 1; + } + /** + * + * + *
+     * Integer value
+     * 
+ * + * int64 int64_value = 1; + * + * @return The int64Value. + */ + public long getInt64Value() { + if (oneValueCase_ == 1) { + return (java.lang.Long) oneValue_; + } + return 0L; + } + /** + * + * + *
+     * Integer value
+     * 
+ * + * int64 int64_value = 1; + * + * @param value The int64Value to set. + * @return This builder for chaining. + */ + public Builder setInt64Value(long value) { + oneValueCase_ = 1; + oneValue_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Integer value
+     * 
+ * + * int64 int64_value = 1; + * + * @return This builder for chaining. + */ + public Builder clearInt64Value() { + if (oneValueCase_ == 1) { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Double value
+     * 
+ * + * double double_value = 2; + * + * @return Whether the doubleValue field is set. + */ + public boolean hasDoubleValue() { + return oneValueCase_ == 2; + } + /** + * + * + *
+     * Double value
+     * 
+ * + * double double_value = 2; + * + * @return The doubleValue. + */ + public double getDoubleValue() { + if (oneValueCase_ == 2) { + return (java.lang.Double) oneValue_; + } + return 0D; + } + /** + * + * + *
+     * Double value
+     * 
+ * + * double double_value = 2; + * + * @param value The doubleValue to set. + * @return This builder for chaining. + */ + public Builder setDoubleValue(double value) { + oneValueCase_ = 2; + oneValue_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Double value
+     * 
+ * + * double double_value = 2; + * + * @return This builder for chaining. + */ + public Builder clearDoubleValue() { + if (oneValueCase_ == 2) { + oneValueCase_ = 0; + oneValue_ = null; + onChanged(); + } + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.NumericValue) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.NumericValue) + private static final com.google.analytics.data.v1alpha.NumericValue DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.NumericValue(); + } + + public static com.google.analytics.data.v1alpha.NumericValue getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public NumericValue parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new NumericValue(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.NumericValue getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValueOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValueOrBuilder.java new file mode 100644 index 00000000..fa7ace8c --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/NumericValueOrBuilder.java @@ -0,0 +1,77 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface NumericValueOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.NumericValue) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Integer value
+   * 
+ * + * int64 int64_value = 1; + * + * @return Whether the int64Value field is set. + */ + boolean hasInt64Value(); + /** + * + * + *
+   * Integer value
+   * 
+ * + * int64 int64_value = 1; + * + * @return The int64Value. + */ + long getInt64Value(); + + /** + * + * + *
+   * Double value
+   * 
+ * + * double double_value = 2; + * + * @return Whether the doubleValue field is set. + */ + boolean hasDoubleValue(); + /** + * + * + *
+   * Double value
+   * 
+ * + * double double_value = 2; + * + * @return The doubleValue. + */ + double getDoubleValue(); + + public com.google.analytics.data.v1alpha.NumericValue.OneValueCase getOneValueCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuota.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuota.java new file mode 100644 index 00000000..975f743d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuota.java @@ -0,0 +1,2038 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Current state of all quotas for this Analytics Property. If any quota for a
+ * property is exhausted, all requests to that property will return Resource
+ * Exhausted errors.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.PropertyQuota} + */ +public final class PropertyQuota extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.PropertyQuota) + PropertyQuotaOrBuilder { + private static final long serialVersionUID = 0L; + // Use PropertyQuota.newBuilder() to construct. + private PropertyQuota(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private PropertyQuota() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new PropertyQuota(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private PropertyQuota( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.QuotaStatus.Builder subBuilder = null; + if (tokensPerDay_ != null) { + subBuilder = tokensPerDay_.toBuilder(); + } + tokensPerDay_ = + input.readMessage( + com.google.analytics.data.v1alpha.QuotaStatus.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(tokensPerDay_); + tokensPerDay_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.analytics.data.v1alpha.QuotaStatus.Builder subBuilder = null; + if (tokensPerHour_ != null) { + subBuilder = tokensPerHour_.toBuilder(); + } + tokensPerHour_ = + input.readMessage( + com.google.analytics.data.v1alpha.QuotaStatus.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(tokensPerHour_); + tokensPerHour_ = subBuilder.buildPartial(); + } + + break; + } + case 26: + { + com.google.analytics.data.v1alpha.QuotaStatus.Builder subBuilder = null; + if (concurrentRequests_ != null) { + subBuilder = concurrentRequests_.toBuilder(); + } + concurrentRequests_ = + input.readMessage( + com.google.analytics.data.v1alpha.QuotaStatus.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(concurrentRequests_); + concurrentRequests_ = subBuilder.buildPartial(); + } + + break; + } + case 34: + { + com.google.analytics.data.v1alpha.QuotaStatus.Builder subBuilder = null; + if (serverErrorsPerProjectPerHour_ != null) { + subBuilder = serverErrorsPerProjectPerHour_.toBuilder(); + } + serverErrorsPerProjectPerHour_ = + input.readMessage( + com.google.analytics.data.v1alpha.QuotaStatus.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(serverErrorsPerProjectPerHour_); + serverErrorsPerProjectPerHour_ = subBuilder.buildPartial(); + } + + break; + } + case 42: + { + com.google.analytics.data.v1alpha.QuotaStatus.Builder subBuilder = null; + if (potentiallyThresholdedRequestsPerHour_ != null) { + subBuilder = potentiallyThresholdedRequestsPerHour_.toBuilder(); + } + potentiallyThresholdedRequestsPerHour_ = + input.readMessage( + com.google.analytics.data.v1alpha.QuotaStatus.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(potentiallyThresholdedRequestsPerHour_); + potentiallyThresholdedRequestsPerHour_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_PropertyQuota_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_PropertyQuota_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.PropertyQuota.class, + com.google.analytics.data.v1alpha.PropertyQuota.Builder.class); + } + + public static final int TOKENS_PER_DAY_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.QuotaStatus tokensPerDay_; + /** + * + * + *
+   * Standard Analytics Properties can use up to 25,000 tokens per day;
+   * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+   * consume fewer than 10 tokens.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * + * @return Whether the tokensPerDay field is set. + */ + @java.lang.Override + public boolean hasTokensPerDay() { + return tokensPerDay_ != null; + } + /** + * + * + *
+   * Standard Analytics Properties can use up to 25,000 tokens per day;
+   * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+   * consume fewer than 10 tokens.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * + * @return The tokensPerDay. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus getTokensPerDay() { + return tokensPerDay_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : tokensPerDay_; + } + /** + * + * + *
+   * Standard Analytics Properties can use up to 25,000 tokens per day;
+   * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+   * consume fewer than 10 tokens.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getTokensPerDayOrBuilder() { + return getTokensPerDay(); + } + + public static final int TOKENS_PER_HOUR_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.QuotaStatus tokensPerHour_; + /** + * + * + *
+   * Standard Analytics Properties can use up to 5,000 tokens per hour;
+   * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+   * consumes a single number of tokens, and that number is deducted from both
+   * the hourly and daily quotas.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * + * @return Whether the tokensPerHour field is set. + */ + @java.lang.Override + public boolean hasTokensPerHour() { + return tokensPerHour_ != null; + } + /** + * + * + *
+   * Standard Analytics Properties can use up to 5,000 tokens per hour;
+   * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+   * consumes a single number of tokens, and that number is deducted from both
+   * the hourly and daily quotas.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * + * @return The tokensPerHour. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus getTokensPerHour() { + return tokensPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : tokensPerHour_; + } + /** + * + * + *
+   * Standard Analytics Properties can use up to 5,000 tokens per hour;
+   * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+   * consumes a single number of tokens, and that number is deducted from both
+   * the hourly and daily quotas.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getTokensPerHourOrBuilder() { + return getTokensPerHour(); + } + + public static final int CONCURRENT_REQUESTS_FIELD_NUMBER = 3; + private com.google.analytics.data.v1alpha.QuotaStatus concurrentRequests_; + /** + * + * + *
+   * Standard Analytics Properties can send up to 10 concurrent requests;
+   * Analytics 360 Properties can use up to 50 concurrent requests.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * + * @return Whether the concurrentRequests field is set. + */ + @java.lang.Override + public boolean hasConcurrentRequests() { + return concurrentRequests_ != null; + } + /** + * + * + *
+   * Standard Analytics Properties can send up to 10 concurrent requests;
+   * Analytics 360 Properties can use up to 50 concurrent requests.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * + * @return The concurrentRequests. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus getConcurrentRequests() { + return concurrentRequests_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : concurrentRequests_; + } + /** + * + * + *
+   * Standard Analytics Properties can send up to 10 concurrent requests;
+   * Analytics 360 Properties can use up to 50 concurrent requests.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getConcurrentRequestsOrBuilder() { + return getConcurrentRequests(); + } + + public static final int SERVER_ERRORS_PER_PROJECT_PER_HOUR_FIELD_NUMBER = 4; + private com.google.analytics.data.v1alpha.QuotaStatus serverErrorsPerProjectPerHour_; + /** + * + * + *
+   * Standard Analytics Properties and cloud project pairs can have up to 10
+   * server errors per hour; Analytics 360 Properties and cloud project pairs
+   * can have up to 50 server errors per hour.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + * @return Whether the serverErrorsPerProjectPerHour field is set. + */ + @java.lang.Override + public boolean hasServerErrorsPerProjectPerHour() { + return serverErrorsPerProjectPerHour_ != null; + } + /** + * + * + *
+   * Standard Analytics Properties and cloud project pairs can have up to 10
+   * server errors per hour; Analytics 360 Properties and cloud project pairs
+   * can have up to 50 server errors per hour.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + * @return The serverErrorsPerProjectPerHour. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus getServerErrorsPerProjectPerHour() { + return serverErrorsPerProjectPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : serverErrorsPerProjectPerHour_; + } + /** + * + * + *
+   * Standard Analytics Properties and cloud project pairs can have up to 10
+   * server errors per hour; Analytics 360 Properties and cloud project pairs
+   * can have up to 50 server errors per hour.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder + getServerErrorsPerProjectPerHourOrBuilder() { + return getServerErrorsPerProjectPerHour(); + } + + public static final int POTENTIALLY_THRESHOLDED_REQUESTS_PER_HOUR_FIELD_NUMBER = 5; + private com.google.analytics.data.v1alpha.QuotaStatus potentiallyThresholdedRequestsPerHour_; + /** + * + * + *
+   * Analytics Properties can send up to 120 requests with potentially
+   * thresholded dimensions per hour. In a batch request, each report request
+   * is individually counted for this quota if the request contains potentially
+   * thresholded dimensions.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + * + * @return Whether the potentiallyThresholdedRequestsPerHour field is set. + */ + @java.lang.Override + public boolean hasPotentiallyThresholdedRequestsPerHour() { + return potentiallyThresholdedRequestsPerHour_ != null; + } + /** + * + * + *
+   * Analytics Properties can send up to 120 requests with potentially
+   * thresholded dimensions per hour. In a batch request, each report request
+   * is individually counted for this quota if the request contains potentially
+   * thresholded dimensions.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + * + * @return The potentiallyThresholdedRequestsPerHour. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus getPotentiallyThresholdedRequestsPerHour() { + return potentiallyThresholdedRequestsPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : potentiallyThresholdedRequestsPerHour_; + } + /** + * + * + *
+   * Analytics Properties can send up to 120 requests with potentially
+   * thresholded dimensions per hour. In a batch request, each report request
+   * is individually counted for this quota if the request contains potentially
+   * thresholded dimensions.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder + getPotentiallyThresholdedRequestsPerHourOrBuilder() { + return getPotentiallyThresholdedRequestsPerHour(); + } + + 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 (tokensPerDay_ != null) { + output.writeMessage(1, getTokensPerDay()); + } + if (tokensPerHour_ != null) { + output.writeMessage(2, getTokensPerHour()); + } + if (concurrentRequests_ != null) { + output.writeMessage(3, getConcurrentRequests()); + } + if (serverErrorsPerProjectPerHour_ != null) { + output.writeMessage(4, getServerErrorsPerProjectPerHour()); + } + if (potentiallyThresholdedRequestsPerHour_ != null) { + output.writeMessage(5, getPotentiallyThresholdedRequestsPerHour()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (tokensPerDay_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTokensPerDay()); + } + if (tokensPerHour_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getTokensPerHour()); + } + if (concurrentRequests_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getConcurrentRequests()); + } + if (serverErrorsPerProjectPerHour_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, getServerErrorsPerProjectPerHour()); + } + if (potentiallyThresholdedRequestsPerHour_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, getPotentiallyThresholdedRequestsPerHour()); + } + size += unknownFields.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.analytics.data.v1alpha.PropertyQuota)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.PropertyQuota other = + (com.google.analytics.data.v1alpha.PropertyQuota) obj; + + if (hasTokensPerDay() != other.hasTokensPerDay()) return false; + if (hasTokensPerDay()) { + if (!getTokensPerDay().equals(other.getTokensPerDay())) return false; + } + if (hasTokensPerHour() != other.hasTokensPerHour()) return false; + if (hasTokensPerHour()) { + if (!getTokensPerHour().equals(other.getTokensPerHour())) return false; + } + if (hasConcurrentRequests() != other.hasConcurrentRequests()) return false; + if (hasConcurrentRequests()) { + if (!getConcurrentRequests().equals(other.getConcurrentRequests())) return false; + } + if (hasServerErrorsPerProjectPerHour() != other.hasServerErrorsPerProjectPerHour()) + return false; + if (hasServerErrorsPerProjectPerHour()) { + if (!getServerErrorsPerProjectPerHour().equals(other.getServerErrorsPerProjectPerHour())) + return false; + } + if (hasPotentiallyThresholdedRequestsPerHour() + != other.hasPotentiallyThresholdedRequestsPerHour()) return false; + if (hasPotentiallyThresholdedRequestsPerHour()) { + if (!getPotentiallyThresholdedRequestsPerHour() + .equals(other.getPotentiallyThresholdedRequestsPerHour())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasTokensPerDay()) { + hash = (37 * hash) + TOKENS_PER_DAY_FIELD_NUMBER; + hash = (53 * hash) + getTokensPerDay().hashCode(); + } + if (hasTokensPerHour()) { + hash = (37 * hash) + TOKENS_PER_HOUR_FIELD_NUMBER; + hash = (53 * hash) + getTokensPerHour().hashCode(); + } + if (hasConcurrentRequests()) { + hash = (37 * hash) + CONCURRENT_REQUESTS_FIELD_NUMBER; + hash = (53 * hash) + getConcurrentRequests().hashCode(); + } + if (hasServerErrorsPerProjectPerHour()) { + hash = (37 * hash) + SERVER_ERRORS_PER_PROJECT_PER_HOUR_FIELD_NUMBER; + hash = (53 * hash) + getServerErrorsPerProjectPerHour().hashCode(); + } + if (hasPotentiallyThresholdedRequestsPerHour()) { + hash = (37 * hash) + POTENTIALLY_THRESHOLDED_REQUESTS_PER_HOUR_FIELD_NUMBER; + hash = (53 * hash) + getPotentiallyThresholdedRequestsPerHour().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota 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.analytics.data.v1alpha.PropertyQuota parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.PropertyQuota 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Current state of all quotas for this Analytics Property. If any quota for a
+   * property is exhausted, all requests to that property will return Resource
+   * Exhausted errors.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.PropertyQuota} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.PropertyQuota) + com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_PropertyQuota_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_PropertyQuota_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.PropertyQuota.class, + com.google.analytics.data.v1alpha.PropertyQuota.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.PropertyQuota.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (tokensPerDayBuilder_ == null) { + tokensPerDay_ = null; + } else { + tokensPerDay_ = null; + tokensPerDayBuilder_ = null; + } + if (tokensPerHourBuilder_ == null) { + tokensPerHour_ = null; + } else { + tokensPerHour_ = null; + tokensPerHourBuilder_ = null; + } + if (concurrentRequestsBuilder_ == null) { + concurrentRequests_ = null; + } else { + concurrentRequests_ = null; + concurrentRequestsBuilder_ = null; + } + if (serverErrorsPerProjectPerHourBuilder_ == null) { + serverErrorsPerProjectPerHour_ = null; + } else { + serverErrorsPerProjectPerHour_ = null; + serverErrorsPerProjectPerHourBuilder_ = null; + } + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + potentiallyThresholdedRequestsPerHour_ = null; + } else { + potentiallyThresholdedRequestsPerHour_ = null; + potentiallyThresholdedRequestsPerHourBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_PropertyQuota_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.PropertyQuota getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.PropertyQuota.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.PropertyQuota build() { + com.google.analytics.data.v1alpha.PropertyQuota result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.PropertyQuota buildPartial() { + com.google.analytics.data.v1alpha.PropertyQuota result = + new com.google.analytics.data.v1alpha.PropertyQuota(this); + if (tokensPerDayBuilder_ == null) { + result.tokensPerDay_ = tokensPerDay_; + } else { + result.tokensPerDay_ = tokensPerDayBuilder_.build(); + } + if (tokensPerHourBuilder_ == null) { + result.tokensPerHour_ = tokensPerHour_; + } else { + result.tokensPerHour_ = tokensPerHourBuilder_.build(); + } + if (concurrentRequestsBuilder_ == null) { + result.concurrentRequests_ = concurrentRequests_; + } else { + result.concurrentRequests_ = concurrentRequestsBuilder_.build(); + } + if (serverErrorsPerProjectPerHourBuilder_ == null) { + result.serverErrorsPerProjectPerHour_ = serverErrorsPerProjectPerHour_; + } else { + result.serverErrorsPerProjectPerHour_ = serverErrorsPerProjectPerHourBuilder_.build(); + } + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + result.potentiallyThresholdedRequestsPerHour_ = potentiallyThresholdedRequestsPerHour_; + } else { + result.potentiallyThresholdedRequestsPerHour_ = + potentiallyThresholdedRequestsPerHourBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.PropertyQuota) { + return mergeFrom((com.google.analytics.data.v1alpha.PropertyQuota) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.PropertyQuota other) { + if (other == com.google.analytics.data.v1alpha.PropertyQuota.getDefaultInstance()) + return this; + if (other.hasTokensPerDay()) { + mergeTokensPerDay(other.getTokensPerDay()); + } + if (other.hasTokensPerHour()) { + mergeTokensPerHour(other.getTokensPerHour()); + } + if (other.hasConcurrentRequests()) { + mergeConcurrentRequests(other.getConcurrentRequests()); + } + if (other.hasServerErrorsPerProjectPerHour()) { + mergeServerErrorsPerProjectPerHour(other.getServerErrorsPerProjectPerHour()); + } + if (other.hasPotentiallyThresholdedRequestsPerHour()) { + mergePotentiallyThresholdedRequestsPerHour( + other.getPotentiallyThresholdedRequestsPerHour()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.PropertyQuota parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.PropertyQuota) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.analytics.data.v1alpha.QuotaStatus tokensPerDay_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + tokensPerDayBuilder_; + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * + * @return Whether the tokensPerDay field is set. + */ + public boolean hasTokensPerDay() { + return tokensPerDayBuilder_ != null || tokensPerDay_ != null; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * + * @return The tokensPerDay. + */ + public com.google.analytics.data.v1alpha.QuotaStatus getTokensPerDay() { + if (tokensPerDayBuilder_ == null) { + return tokensPerDay_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : tokensPerDay_; + } else { + return tokensPerDayBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + public Builder setTokensPerDay(com.google.analytics.data.v1alpha.QuotaStatus value) { + if (tokensPerDayBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + tokensPerDay_ = value; + onChanged(); + } else { + tokensPerDayBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + public Builder setTokensPerDay( + com.google.analytics.data.v1alpha.QuotaStatus.Builder builderForValue) { + if (tokensPerDayBuilder_ == null) { + tokensPerDay_ = builderForValue.build(); + onChanged(); + } else { + tokensPerDayBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + public Builder mergeTokensPerDay(com.google.analytics.data.v1alpha.QuotaStatus value) { + if (tokensPerDayBuilder_ == null) { + if (tokensPerDay_ != null) { + tokensPerDay_ = + com.google.analytics.data.v1alpha.QuotaStatus.newBuilder(tokensPerDay_) + .mergeFrom(value) + .buildPartial(); + } else { + tokensPerDay_ = value; + } + onChanged(); + } else { + tokensPerDayBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + public Builder clearTokensPerDay() { + if (tokensPerDayBuilder_ == null) { + tokensPerDay_ = null; + onChanged(); + } else { + tokensPerDay_ = null; + tokensPerDayBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + public com.google.analytics.data.v1alpha.QuotaStatus.Builder getTokensPerDayBuilder() { + + onChanged(); + return getTokensPerDayFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getTokensPerDayOrBuilder() { + if (tokensPerDayBuilder_ != null) { + return tokensPerDayBuilder_.getMessageOrBuilder(); + } else { + return tokensPerDay_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : tokensPerDay_; + } + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 25,000 tokens per day;
+     * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+     * consume fewer than 10 tokens.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + getTokensPerDayFieldBuilder() { + if (tokensPerDayBuilder_ == null) { + tokensPerDayBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder>( + getTokensPerDay(), getParentForChildren(), isClean()); + tokensPerDay_ = null; + } + return tokensPerDayBuilder_; + } + + private com.google.analytics.data.v1alpha.QuotaStatus tokensPerHour_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + tokensPerHourBuilder_; + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * + * @return Whether the tokensPerHour field is set. + */ + public boolean hasTokensPerHour() { + return tokensPerHourBuilder_ != null || tokensPerHour_ != null; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * + * @return The tokensPerHour. + */ + public com.google.analytics.data.v1alpha.QuotaStatus getTokensPerHour() { + if (tokensPerHourBuilder_ == null) { + return tokensPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : tokensPerHour_; + } else { + return tokensPerHourBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + public Builder setTokensPerHour(com.google.analytics.data.v1alpha.QuotaStatus value) { + if (tokensPerHourBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + tokensPerHour_ = value; + onChanged(); + } else { + tokensPerHourBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + public Builder setTokensPerHour( + com.google.analytics.data.v1alpha.QuotaStatus.Builder builderForValue) { + if (tokensPerHourBuilder_ == null) { + tokensPerHour_ = builderForValue.build(); + onChanged(); + } else { + tokensPerHourBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + public Builder mergeTokensPerHour(com.google.analytics.data.v1alpha.QuotaStatus value) { + if (tokensPerHourBuilder_ == null) { + if (tokensPerHour_ != null) { + tokensPerHour_ = + com.google.analytics.data.v1alpha.QuotaStatus.newBuilder(tokensPerHour_) + .mergeFrom(value) + .buildPartial(); + } else { + tokensPerHour_ = value; + } + onChanged(); + } else { + tokensPerHourBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + public Builder clearTokensPerHour() { + if (tokensPerHourBuilder_ == null) { + tokensPerHour_ = null; + onChanged(); + } else { + tokensPerHour_ = null; + tokensPerHourBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + public com.google.analytics.data.v1alpha.QuotaStatus.Builder getTokensPerHourBuilder() { + + onChanged(); + return getTokensPerHourFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getTokensPerHourOrBuilder() { + if (tokensPerHourBuilder_ != null) { + return tokensPerHourBuilder_.getMessageOrBuilder(); + } else { + return tokensPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : tokensPerHour_; + } + } + /** + * + * + *
+     * Standard Analytics Properties can use up to 5,000 tokens per hour;
+     * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+     * consumes a single number of tokens, and that number is deducted from both
+     * the hourly and daily quotas.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + getTokensPerHourFieldBuilder() { + if (tokensPerHourBuilder_ == null) { + tokensPerHourBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder>( + getTokensPerHour(), getParentForChildren(), isClean()); + tokensPerHour_ = null; + } + return tokensPerHourBuilder_; + } + + private com.google.analytics.data.v1alpha.QuotaStatus concurrentRequests_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + concurrentRequestsBuilder_; + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * + * @return Whether the concurrentRequests field is set. + */ + public boolean hasConcurrentRequests() { + return concurrentRequestsBuilder_ != null || concurrentRequests_ != null; + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * + * @return The concurrentRequests. + */ + public com.google.analytics.data.v1alpha.QuotaStatus getConcurrentRequests() { + if (concurrentRequestsBuilder_ == null) { + return concurrentRequests_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : concurrentRequests_; + } else { + return concurrentRequestsBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + public Builder setConcurrentRequests(com.google.analytics.data.v1alpha.QuotaStatus value) { + if (concurrentRequestsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + concurrentRequests_ = value; + onChanged(); + } else { + concurrentRequestsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + public Builder setConcurrentRequests( + com.google.analytics.data.v1alpha.QuotaStatus.Builder builderForValue) { + if (concurrentRequestsBuilder_ == null) { + concurrentRequests_ = builderForValue.build(); + onChanged(); + } else { + concurrentRequestsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + public Builder mergeConcurrentRequests(com.google.analytics.data.v1alpha.QuotaStatus value) { + if (concurrentRequestsBuilder_ == null) { + if (concurrentRequests_ != null) { + concurrentRequests_ = + com.google.analytics.data.v1alpha.QuotaStatus.newBuilder(concurrentRequests_) + .mergeFrom(value) + .buildPartial(); + } else { + concurrentRequests_ = value; + } + onChanged(); + } else { + concurrentRequestsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + public Builder clearConcurrentRequests() { + if (concurrentRequestsBuilder_ == null) { + concurrentRequests_ = null; + onChanged(); + } else { + concurrentRequests_ = null; + concurrentRequestsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + public com.google.analytics.data.v1alpha.QuotaStatus.Builder getConcurrentRequestsBuilder() { + + onChanged(); + return getConcurrentRequestsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getConcurrentRequestsOrBuilder() { + if (concurrentRequestsBuilder_ != null) { + return concurrentRequestsBuilder_.getMessageOrBuilder(); + } else { + return concurrentRequests_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : concurrentRequests_; + } + } + /** + * + * + *
+     * Standard Analytics Properties can send up to 10 concurrent requests;
+     * Analytics 360 Properties can use up to 50 concurrent requests.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + getConcurrentRequestsFieldBuilder() { + if (concurrentRequestsBuilder_ == null) { + concurrentRequestsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder>( + getConcurrentRequests(), getParentForChildren(), isClean()); + concurrentRequests_ = null; + } + return concurrentRequestsBuilder_; + } + + private com.google.analytics.data.v1alpha.QuotaStatus serverErrorsPerProjectPerHour_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + serverErrorsPerProjectPerHourBuilder_; + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + * + * @return Whether the serverErrorsPerProjectPerHour field is set. + */ + public boolean hasServerErrorsPerProjectPerHour() { + return serverErrorsPerProjectPerHourBuilder_ != null + || serverErrorsPerProjectPerHour_ != null; + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + * + * @return The serverErrorsPerProjectPerHour. + */ + public com.google.analytics.data.v1alpha.QuotaStatus getServerErrorsPerProjectPerHour() { + if (serverErrorsPerProjectPerHourBuilder_ == null) { + return serverErrorsPerProjectPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : serverErrorsPerProjectPerHour_; + } else { + return serverErrorsPerProjectPerHourBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + public Builder setServerErrorsPerProjectPerHour( + com.google.analytics.data.v1alpha.QuotaStatus value) { + if (serverErrorsPerProjectPerHourBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + serverErrorsPerProjectPerHour_ = value; + onChanged(); + } else { + serverErrorsPerProjectPerHourBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + public Builder setServerErrorsPerProjectPerHour( + com.google.analytics.data.v1alpha.QuotaStatus.Builder builderForValue) { + if (serverErrorsPerProjectPerHourBuilder_ == null) { + serverErrorsPerProjectPerHour_ = builderForValue.build(); + onChanged(); + } else { + serverErrorsPerProjectPerHourBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + public Builder mergeServerErrorsPerProjectPerHour( + com.google.analytics.data.v1alpha.QuotaStatus value) { + if (serverErrorsPerProjectPerHourBuilder_ == null) { + if (serverErrorsPerProjectPerHour_ != null) { + serverErrorsPerProjectPerHour_ = + com.google.analytics.data.v1alpha.QuotaStatus.newBuilder( + serverErrorsPerProjectPerHour_) + .mergeFrom(value) + .buildPartial(); + } else { + serverErrorsPerProjectPerHour_ = value; + } + onChanged(); + } else { + serverErrorsPerProjectPerHourBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + public Builder clearServerErrorsPerProjectPerHour() { + if (serverErrorsPerProjectPerHourBuilder_ == null) { + serverErrorsPerProjectPerHour_ = null; + onChanged(); + } else { + serverErrorsPerProjectPerHour_ = null; + serverErrorsPerProjectPerHourBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + public com.google.analytics.data.v1alpha.QuotaStatus.Builder + getServerErrorsPerProjectPerHourBuilder() { + + onChanged(); + return getServerErrorsPerProjectPerHourFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder + getServerErrorsPerProjectPerHourOrBuilder() { + if (serverErrorsPerProjectPerHourBuilder_ != null) { + return serverErrorsPerProjectPerHourBuilder_.getMessageOrBuilder(); + } else { + return serverErrorsPerProjectPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : serverErrorsPerProjectPerHour_; + } + } + /** + * + * + *
+     * Standard Analytics Properties and cloud project pairs can have up to 10
+     * server errors per hour; Analytics 360 Properties and cloud project pairs
+     * can have up to 50 server errors per hour.
+     * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + getServerErrorsPerProjectPerHourFieldBuilder() { + if (serverErrorsPerProjectPerHourBuilder_ == null) { + serverErrorsPerProjectPerHourBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder>( + getServerErrorsPerProjectPerHour(), getParentForChildren(), isClean()); + serverErrorsPerProjectPerHour_ = null; + } + return serverErrorsPerProjectPerHourBuilder_; + } + + private com.google.analytics.data.v1alpha.QuotaStatus potentiallyThresholdedRequestsPerHour_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + potentiallyThresholdedRequestsPerHourBuilder_; + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + * + * @return Whether the potentiallyThresholdedRequestsPerHour field is set. + */ + public boolean hasPotentiallyThresholdedRequestsPerHour() { + return potentiallyThresholdedRequestsPerHourBuilder_ != null + || potentiallyThresholdedRequestsPerHour_ != null; + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + * + * @return The potentiallyThresholdedRequestsPerHour. + */ + public com.google.analytics.data.v1alpha.QuotaStatus + getPotentiallyThresholdedRequestsPerHour() { + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + return potentiallyThresholdedRequestsPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : potentiallyThresholdedRequestsPerHour_; + } else { + return potentiallyThresholdedRequestsPerHourBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + public Builder setPotentiallyThresholdedRequestsPerHour( + com.google.analytics.data.v1alpha.QuotaStatus value) { + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + potentiallyThresholdedRequestsPerHour_ = value; + onChanged(); + } else { + potentiallyThresholdedRequestsPerHourBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + public Builder setPotentiallyThresholdedRequestsPerHour( + com.google.analytics.data.v1alpha.QuotaStatus.Builder builderForValue) { + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + potentiallyThresholdedRequestsPerHour_ = builderForValue.build(); + onChanged(); + } else { + potentiallyThresholdedRequestsPerHourBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + public Builder mergePotentiallyThresholdedRequestsPerHour( + com.google.analytics.data.v1alpha.QuotaStatus value) { + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + if (potentiallyThresholdedRequestsPerHour_ != null) { + potentiallyThresholdedRequestsPerHour_ = + com.google.analytics.data.v1alpha.QuotaStatus.newBuilder( + potentiallyThresholdedRequestsPerHour_) + .mergeFrom(value) + .buildPartial(); + } else { + potentiallyThresholdedRequestsPerHour_ = value; + } + onChanged(); + } else { + potentiallyThresholdedRequestsPerHourBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + public Builder clearPotentiallyThresholdedRequestsPerHour() { + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + potentiallyThresholdedRequestsPerHour_ = null; + onChanged(); + } else { + potentiallyThresholdedRequestsPerHour_ = null; + potentiallyThresholdedRequestsPerHourBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + public com.google.analytics.data.v1alpha.QuotaStatus.Builder + getPotentiallyThresholdedRequestsPerHourBuilder() { + + onChanged(); + return getPotentiallyThresholdedRequestsPerHourFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + public com.google.analytics.data.v1alpha.QuotaStatusOrBuilder + getPotentiallyThresholdedRequestsPerHourOrBuilder() { + if (potentiallyThresholdedRequestsPerHourBuilder_ != null) { + return potentiallyThresholdedRequestsPerHourBuilder_.getMessageOrBuilder(); + } else { + return potentiallyThresholdedRequestsPerHour_ == null + ? com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance() + : potentiallyThresholdedRequestsPerHour_; + } + } + /** + * + * + *
+     * Analytics Properties can send up to 120 requests with potentially
+     * thresholded dimensions per hour. In a batch request, each report request
+     * is individually counted for this quota if the request contains potentially
+     * thresholded dimensions.
+     * 
+ * + * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder> + getPotentiallyThresholdedRequestsPerHourFieldBuilder() { + if (potentiallyThresholdedRequestsPerHourBuilder_ == null) { + potentiallyThresholdedRequestsPerHourBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.QuotaStatus, + com.google.analytics.data.v1alpha.QuotaStatus.Builder, + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder>( + getPotentiallyThresholdedRequestsPerHour(), getParentForChildren(), isClean()); + potentiallyThresholdedRequestsPerHour_ = null; + } + return potentiallyThresholdedRequestsPerHourBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.PropertyQuota) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.PropertyQuota) + private static final com.google.analytics.data.v1alpha.PropertyQuota DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.PropertyQuota(); + } + + public static com.google.analytics.data.v1alpha.PropertyQuota getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public PropertyQuota parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new PropertyQuota(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.PropertyQuota getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuotaOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuotaOrBuilder.java new file mode 100644 index 00000000..3551dd0d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/PropertyQuotaOrBuilder.java @@ -0,0 +1,238 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface PropertyQuotaOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.PropertyQuota) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Standard Analytics Properties can use up to 25,000 tokens per day;
+   * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+   * consume fewer than 10 tokens.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * + * @return Whether the tokensPerDay field is set. + */ + boolean hasTokensPerDay(); + /** + * + * + *
+   * Standard Analytics Properties can use up to 25,000 tokens per day;
+   * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+   * consume fewer than 10 tokens.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * + * @return The tokensPerDay. + */ + com.google.analytics.data.v1alpha.QuotaStatus getTokensPerDay(); + /** + * + * + *
+   * Standard Analytics Properties can use up to 25,000 tokens per day;
+   * Analytics 360 Properties can use 250,000 tokens per day. Most requests
+   * consume fewer than 10 tokens.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getTokensPerDayOrBuilder(); + + /** + * + * + *
+   * Standard Analytics Properties can use up to 5,000 tokens per hour;
+   * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+   * consumes a single number of tokens, and that number is deducted from both
+   * the hourly and daily quotas.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * + * @return Whether the tokensPerHour field is set. + */ + boolean hasTokensPerHour(); + /** + * + * + *
+   * Standard Analytics Properties can use up to 5,000 tokens per hour;
+   * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+   * consumes a single number of tokens, and that number is deducted from both
+   * the hourly and daily quotas.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * + * @return The tokensPerHour. + */ + com.google.analytics.data.v1alpha.QuotaStatus getTokensPerHour(); + /** + * + * + *
+   * Standard Analytics Properties can use up to 5,000 tokens per hour;
+   * Analytics 360 Properties can use 50,000 tokens per hour. An API request
+   * consumes a single number of tokens, and that number is deducted from both
+   * the hourly and daily quotas.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getTokensPerHourOrBuilder(); + + /** + * + * + *
+   * Standard Analytics Properties can send up to 10 concurrent requests;
+   * Analytics 360 Properties can use up to 50 concurrent requests.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * + * @return Whether the concurrentRequests field is set. + */ + boolean hasConcurrentRequests(); + /** + * + * + *
+   * Standard Analytics Properties can send up to 10 concurrent requests;
+   * Analytics 360 Properties can use up to 50 concurrent requests.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * + * @return The concurrentRequests. + */ + com.google.analytics.data.v1alpha.QuotaStatus getConcurrentRequests(); + /** + * + * + *
+   * Standard Analytics Properties can send up to 10 concurrent requests;
+   * Analytics 360 Properties can use up to 50 concurrent requests.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder getConcurrentRequestsOrBuilder(); + + /** + * + * + *
+   * Standard Analytics Properties and cloud project pairs can have up to 10
+   * server errors per hour; Analytics 360 Properties and cloud project pairs
+   * can have up to 50 server errors per hour.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + * @return Whether the serverErrorsPerProjectPerHour field is set. + */ + boolean hasServerErrorsPerProjectPerHour(); + /** + * + * + *
+   * Standard Analytics Properties and cloud project pairs can have up to 10
+   * server errors per hour; Analytics 360 Properties and cloud project pairs
+   * can have up to 50 server errors per hour.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * + * @return The serverErrorsPerProjectPerHour. + */ + com.google.analytics.data.v1alpha.QuotaStatus getServerErrorsPerProjectPerHour(); + /** + * + * + *
+   * Standard Analytics Properties and cloud project pairs can have up to 10
+   * server errors per hour; Analytics 360 Properties and cloud project pairs
+   * can have up to 50 server errors per hour.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + */ + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder + getServerErrorsPerProjectPerHourOrBuilder(); + + /** + * + * + *
+   * Analytics Properties can send up to 120 requests with potentially
+   * thresholded dimensions per hour. In a batch request, each report request
+   * is individually counted for this quota if the request contains potentially
+   * thresholded dimensions.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + * + * @return Whether the potentiallyThresholdedRequestsPerHour field is set. + */ + boolean hasPotentiallyThresholdedRequestsPerHour(); + /** + * + * + *
+   * Analytics Properties can send up to 120 requests with potentially
+   * thresholded dimensions per hour. In a batch request, each report request
+   * is individually counted for this quota if the request contains potentially
+   * thresholded dimensions.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + * + * @return The potentiallyThresholdedRequestsPerHour. + */ + com.google.analytics.data.v1alpha.QuotaStatus getPotentiallyThresholdedRequestsPerHour(); + /** + * + * + *
+   * Analytics Properties can send up to 120 requests with potentially
+   * thresholded dimensions per hour. In a batch request, each report request
+   * is individually counted for this quota if the request contains potentially
+   * thresholded dimensions.
+   * 
+ * + * .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * + */ + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder + getPotentiallyThresholdedRequestsPerHourOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatus.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatus.java new file mode 100644 index 00000000..24e81a62 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatus.java @@ -0,0 +1,636 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Current state for a particular quota group.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.QuotaStatus} + */ +public final class QuotaStatus extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.QuotaStatus) + QuotaStatusOrBuilder { + private static final long serialVersionUID = 0L; + // Use QuotaStatus.newBuilder() to construct. + private QuotaStatus(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private QuotaStatus() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new QuotaStatus(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private QuotaStatus( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + consumed_ = input.readInt32(); + break; + } + case 16: + { + remaining_ = input.readInt32(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_QuotaStatus_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_QuotaStatus_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.QuotaStatus.class, + com.google.analytics.data.v1alpha.QuotaStatus.Builder.class); + } + + public static final int CONSUMED_FIELD_NUMBER = 1; + private int consumed_; + /** + * + * + *
+   * Quota consumed by this request.
+   * 
+ * + * int32 consumed = 1; + * + * @return The consumed. + */ + @java.lang.Override + public int getConsumed() { + return consumed_; + } + + public static final int REMAINING_FIELD_NUMBER = 2; + private int remaining_; + /** + * + * + *
+   * Quota remaining after this request.
+   * 
+ * + * int32 remaining = 2; + * + * @return The remaining. + */ + @java.lang.Override + public int getRemaining() { + return remaining_; + } + + 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 (consumed_ != 0) { + output.writeInt32(1, consumed_); + } + if (remaining_ != 0) { + output.writeInt32(2, remaining_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (consumed_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, consumed_); + } + if (remaining_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, remaining_); + } + size += unknownFields.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.analytics.data.v1alpha.QuotaStatus)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.QuotaStatus other = + (com.google.analytics.data.v1alpha.QuotaStatus) obj; + + if (getConsumed() != other.getConsumed()) return false; + if (getRemaining() != other.getRemaining()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + CONSUMED_FIELD_NUMBER; + hash = (53 * hash) + getConsumed(); + hash = (37 * hash) + REMAINING_FIELD_NUMBER; + hash = (53 * hash) + getRemaining(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus 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.analytics.data.v1alpha.QuotaStatus parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.QuotaStatus 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Current state for a particular quota group.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.QuotaStatus} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.QuotaStatus) + com.google.analytics.data.v1alpha.QuotaStatusOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_QuotaStatus_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_QuotaStatus_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.QuotaStatus.class, + com.google.analytics.data.v1alpha.QuotaStatus.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.QuotaStatus.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + consumed_ = 0; + + remaining_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_QuotaStatus_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus build() { + com.google.analytics.data.v1alpha.QuotaStatus result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.QuotaStatus buildPartial() { + com.google.analytics.data.v1alpha.QuotaStatus result = + new com.google.analytics.data.v1alpha.QuotaStatus(this); + result.consumed_ = consumed_; + result.remaining_ = remaining_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.QuotaStatus) { + return mergeFrom((com.google.analytics.data.v1alpha.QuotaStatus) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.QuotaStatus other) { + if (other == com.google.analytics.data.v1alpha.QuotaStatus.getDefaultInstance()) return this; + if (other.getConsumed() != 0) { + setConsumed(other.getConsumed()); + } + if (other.getRemaining() != 0) { + setRemaining(other.getRemaining()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.QuotaStatus parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.QuotaStatus) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int consumed_; + /** + * + * + *
+     * Quota consumed by this request.
+     * 
+ * + * int32 consumed = 1; + * + * @return The consumed. + */ + @java.lang.Override + public int getConsumed() { + return consumed_; + } + /** + * + * + *
+     * Quota consumed by this request.
+     * 
+ * + * int32 consumed = 1; + * + * @param value The consumed to set. + * @return This builder for chaining. + */ + public Builder setConsumed(int value) { + + consumed_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Quota consumed by this request.
+     * 
+ * + * int32 consumed = 1; + * + * @return This builder for chaining. + */ + public Builder clearConsumed() { + + consumed_ = 0; + onChanged(); + return this; + } + + private int remaining_; + /** + * + * + *
+     * Quota remaining after this request.
+     * 
+ * + * int32 remaining = 2; + * + * @return The remaining. + */ + @java.lang.Override + public int getRemaining() { + return remaining_; + } + /** + * + * + *
+     * Quota remaining after this request.
+     * 
+ * + * int32 remaining = 2; + * + * @param value The remaining to set. + * @return This builder for chaining. + */ + public Builder setRemaining(int value) { + + remaining_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Quota remaining after this request.
+     * 
+ * + * int32 remaining = 2; + * + * @return This builder for chaining. + */ + public Builder clearRemaining() { + + remaining_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.QuotaStatus) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.QuotaStatus) + private static final com.google.analytics.data.v1alpha.QuotaStatus DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.QuotaStatus(); + } + + public static com.google.analytics.data.v1alpha.QuotaStatus getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public QuotaStatus parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new QuotaStatus(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.QuotaStatus getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatusOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatusOrBuilder.java new file mode 100644 index 00000000..e95d0f78 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/QuotaStatusOrBuilder.java @@ -0,0 +1,51 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface QuotaStatusOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.QuotaStatus) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Quota consumed by this request.
+   * 
+ * + * int32 consumed = 1; + * + * @return The consumed. + */ + int getConsumed(); + + /** + * + * + *
+   * Quota remaining after this request.
+   * 
+ * + * int32 remaining = 2; + * + * @return The remaining. + */ + int getRemaining(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/ReportingApiProto.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/ReportingApiProto.java new file mode 100644 index 00000000..7ea0ea7d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/ReportingApiProto.java @@ -0,0 +1,1111 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public final class ReportingApiProto { + private ReportingApiProto() {} + + 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_analytics_data_v1alpha_DateRange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_DateRange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_Dimension_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_Dimension_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_DimensionExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FilterExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FilterExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FilterExpressionList_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FilterExpressionList_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_Filter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_Filter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_StringFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_StringFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_InListFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_InListFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_NumericFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_NumericFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_BetweenFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_BetweenFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_NumericValue_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_NumericValue_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_DimensionHeader_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_DimensionHeader_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_MetricHeader_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_MetricHeader_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_Row_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_Row_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_DimensionValue_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_DimensionValue_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_MetricValue_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_MetricValue_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_PropertyQuota_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_PropertyQuota_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_QuotaStatus_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_QuotaStatus_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelBreakdown_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelBreakdown_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelNextAction_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelNextAction_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_Funnel_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_Funnel_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelStep_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelStep_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelSubReport_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelSubReport_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_UserSegment_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_UserSegment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_UserSequenceStep_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_UserSequenceStep_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SessionSegment_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SessionSegment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_EventSegment_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_EventSegment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_Segment_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_Segment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentEventFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentEventFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelEventFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelEventFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_analytics_data_v1alpha_SamplingMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_analytics_data_v1alpha_SamplingMetadata_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(google/analytics/data/v1alpha/data.pro" + + "to\022\035google.analytics.data.v1alpha\032\036googl" + + "e/protobuf/duration.proto\"?\n\tDateRange\022\022" + + "\n\nstart_date\030\001 \001(\t\022\020\n\010end_date\030\002 \001(\t\022\014\n\004" + + "name\030\003 \001(\t\"k\n\tDimension\022\014\n\004name\030\001 \001(\t\022P\n" + + "\024dimension_expression\030\002 \001(\01322.google.ana" + + "lytics.data.v1alpha.DimensionExpression\"" + + "\251\003\n\023DimensionExpression\022W\n\nlower_case\030\004 " + + "\001(\0132A.google.analytics.data.v1alpha.Dime" + + "nsionExpression.CaseExpressionH\000\022W\n\nuppe" + + "r_case\030\005 \001(\0132A.google.analytics.data.v1a" + + "lpha.DimensionExpression.CaseExpressionH" + + "\000\022_\n\013concatenate\030\006 \001(\0132H.google.analytic" + + "s.data.v1alpha.DimensionExpression.Conca" + + "tenateExpressionH\000\032(\n\016CaseExpression\022\026\n\016" + + "dimension_name\030\001 \001(\t\032C\n\025ConcatenateExpre" + + "ssion\022\027\n\017dimension_names\030\001 \003(\t\022\021\n\tdelimi" + + "ter\030\002 \001(\tB\020\n\016one_expression\"\261\002\n\020FilterEx" + + "pression\022H\n\tand_group\030\001 \001(\01323.google.ana" + + "lytics.data.v1alpha.FilterExpressionList" + + "H\000\022G\n\010or_group\030\002 \001(\01323.google.analytics." + + "data.v1alpha.FilterExpressionListH\000\022I\n\016n" + + "ot_expression\030\003 \001(\0132/.google.analytics.d" + + "ata.v1alpha.FilterExpressionH\000\0227\n\006filter" + + "\030\004 \001(\0132%.google.analytics.data.v1alpha.F" + + "ilterH\000B\006\n\004expr\"\\\n\024FilterExpressionList\022" + + "D\n\013expressions\030\001 \003(\0132/.google.analytics." + + "data.v1alpha.FilterExpression\"\307\002\n\006Filter" + + "\022\022\n\nfield_name\030\001 \001(\t\022D\n\rstring_filter\030\002 " + + "\001(\0132+.google.analytics.data.v1alpha.Stri" + + "ngFilterH\000\022E\n\016in_list_filter\030\003 \001(\0132+.goo" + + "gle.analytics.data.v1alpha.InListFilterH" + + "\000\022F\n\016numeric_filter\030\004 \001(\0132,.google.analy" + + "tics.data.v1alpha.NumericFilterH\000\022F\n\016bet" + + "ween_filter\030\005 \001(\0132,.google.analytics.dat" + + "a.v1alpha.BetweenFilterH\000B\014\n\none_filter\"" + + "\210\002\n\014StringFilter\022I\n\nmatch_type\030\001 \001(\01625.g" + + "oogle.analytics.data.v1alpha.StringFilte" + + "r.MatchType\022\r\n\005value\030\002 \001(\t\022\026\n\016case_sensi" + + "tive\030\003 \001(\010\"\205\001\n\tMatchType\022\032\n\026MATCH_TYPE_U" + + "NSPECIFIED\020\000\022\t\n\005EXACT\020\001\022\017\n\013BEGINS_WITH\020\002" + + "\022\r\n\tENDS_WITH\020\003\022\014\n\010CONTAINS\020\004\022\017\n\013FULL_RE" + + "GEXP\020\005\022\022\n\016PARTIAL_REGEXP\020\006\"6\n\014InListFilt" + + "er\022\016\n\006values\030\001 \003(\t\022\026\n\016case_sensitive\030\002 \001" + + "(\010\"\236\002\n\rNumericFilter\022I\n\toperation\030\001 \001(\0162" + + "6.google.analytics.data.v1alpha.NumericF" + + "ilter.Operation\022:\n\005value\030\002 \001(\0132+.google." + + "analytics.data.v1alpha.NumericValue\"\205\001\n\t" + + "Operation\022\031\n\025OPERATION_UNSPECIFIED\020\000\022\t\n\005" + + "EQUAL\020\001\022\r\n\tLESS_THAN\020\002\022\026\n\022LESS_THAN_OR_E" + + "QUAL\020\003\022\020\n\014GREATER_THAN\020\004\022\031\n\025GREATER_THAN" + + "_OR_EQUAL\020\005\"\217\001\n\rBetweenFilter\022?\n\nfrom_va" + + "lue\030\001 \001(\0132+.google.analytics.data.v1alph" + + "a.NumericValue\022=\n\010to_value\030\002 \001(\0132+.googl" + + "e.analytics.data.v1alpha.NumericValue\"J\n" + + "\014NumericValue\022\025\n\013int64_value\030\001 \001(\003H\000\022\026\n\014" + + "double_value\030\002 \001(\001H\000B\013\n\tone_value\"\037\n\017Dim" + + "ensionHeader\022\014\n\004name\030\001 \001(\t\"U\n\014MetricHead" + + "er\022\014\n\004name\030\001 \001(\t\0227\n\004type\030\002 \001(\0162).google." + + "analytics.data.v1alpha.MetricType\"\221\001\n\003Ro" + + "w\022G\n\020dimension_values\030\001 \003(\0132-.google.ana" + + "lytics.data.v1alpha.DimensionValue\022A\n\rme" + + "tric_values\030\002 \003(\0132*.google.analytics.dat" + + "a.v1alpha.MetricValue\".\n\016DimensionValue\022" + + "\017\n\005value\030\001 \001(\tH\000B\013\n\tone_value\"+\n\013MetricV" + + "alue\022\017\n\005value\030\004 \001(\tH\000B\013\n\tone_value\"\230\003\n\rP" + + "ropertyQuota\022B\n\016tokens_per_day\030\001 \001(\0132*.g" + + "oogle.analytics.data.v1alpha.QuotaStatus" + + "\022C\n\017tokens_per_hour\030\002 \001(\0132*.google.analy" + + "tics.data.v1alpha.QuotaStatus\022G\n\023concurr" + + "ent_requests\030\003 \001(\0132*.google.analytics.da" + + "ta.v1alpha.QuotaStatus\022V\n\"server_errors_" + + "per_project_per_hour\030\004 \001(\0132*.google.anal" + + "ytics.data.v1alpha.QuotaStatus\022]\n)potent" + + "ially_thresholded_requests_per_hour\030\005 \001(" + + "\0132*.google.analytics.data.v1alpha.QuotaS" + + "tatus\"2\n\013QuotaStatus\022\020\n\010consumed\030\001 \001(\005\022\021" + + "\n\tremaining\030\002 \001(\005\"v\n\017FunnelBreakdown\022E\n\023" + + "breakdown_dimension\030\001 \001(\0132(.google.analy" + + "tics.data.v1alpha.Dimension\022\022\n\005limit\030\002 \001" + + "(\003H\000\210\001\001B\010\n\006_limit\"y\n\020FunnelNextAction\022G\n" + + "\025next_action_dimension\030\001 \001(\0132(.google.an" + + "alytics.data.v1alpha.Dimension\022\022\n\005limit\030" + + "\002 \001(\003H\000\210\001\001B\010\n\006_limit\"Z\n\006Funnel\022\026\n\016is_ope" + + "n_funnel\030\001 \001(\010\0228\n\005steps\030\002 \003(\0132).google.a" + + "nalytics.data.v1alpha.FunnelStep\"\372\001\n\nFun" + + "nelStep\022\014\n\004name\030\001 \001(\t\022\037\n\027is_directly_fol" + + "lowed_by\030\002 \001(\010\022G\n\037within_duration_from_p" + + "rior_step\030\003 \001(\0132\031.google.protobuf.Durati" + + "onH\000\210\001\001\022P\n\021filter_expression\030\004 \001(\01325.goo" + + "gle.analytics.data.v1alpha.FunnelFilterE" + + "xpressionB\"\n _within_duration_from_prior" + + "_step\"\234\002\n\017FunnelSubReport\022I\n\021dimension_h" + + "eaders\030\001 \003(\0132..google.analytics.data.v1a" + + "lpha.DimensionHeader\022C\n\016metric_headers\030\002" + + " \003(\0132+.google.analytics.data.v1alpha.Met" + + "ricHeader\0220\n\004rows\030\003 \003(\0132\".google.analyti" + + "cs.data.v1alpha.Row\022G\n\010metadata\030\004 \001(\01325." + + "google.analytics.data.v1alpha.FunnelResp" + + "onseMetadata\"\252\001\n\013UserSegment\022S\n\027user_inc" + + "lusion_criteria\030\001 \001(\01322.google.analytics" + + ".data.v1alpha.UserSegmentCriteria\022F\n\texc" + + "lusion\030\002 \001(\01323.google.analytics.data.v1a" + + "lpha.UserSegmentExclusion\"\303\001\n\023UserSegmen" + + "tCriteria\022V\n\024and_condition_groups\030\001 \003(\0132" + + "8.google.analytics.data.v1alpha.UserSegm" + + "entConditionGroup\022T\n\023and_sequence_groups" + + "\030\002 \003(\01327.google.analytics.data.v1alpha.U" + + "serSegmentSequenceGroup\"\305\001\n\031UserSegmentC" + + "onditionGroup\022M\n\021condition_scoping\030\001 \001(\016" + + "22.google.analytics.data.v1alpha.UserCri" + + "teriaScoping\022Y\n\031segment_filter_expressio" + + "n\030\002 \001(\01326.google.analytics.data.v1alpha." + + "SegmentFilterExpression\"\364\001\n\030UserSegmentS" + + "equenceGroup\022L\n\020sequence_scoping\030\001 \001(\01622" + + ".google.analytics.data.v1alpha.UserCrite" + + "riaScoping\022<\n\031sequence_maximum_duration\030" + + "\002 \001(\0132\031.google.protobuf.Duration\022L\n\023user" + + "_sequence_steps\030\003 \003(\0132/.google.analytics" + + ".data.v1alpha.UserSequenceStep\"\330\001\n\020UserS" + + "equenceStep\022\037\n\027is_directly_followed_by\030\001" + + " \001(\010\022H\n\014step_scoping\030\002 \001(\01622.google.anal" + + "ytics.data.v1alpha.UserCriteriaScoping\022Y" + + "\n\031segment_filter_expression\030\003 \001(\01326.goog" + + "le.analytics.data.v1alpha.SegmentFilterE" + + "xpression\"\302\001\n\024UserSegmentExclusion\022U\n\027us" + + "er_exclusion_duration\030\001 \001(\01624.google.ana" + + "lytics.data.v1alpha.UserExclusionDuratio" + + "n\022S\n\027user_exclusion_criteria\030\002 \001(\01322.goo" + + "gle.analytics.data.v1alpha.UserSegmentCr" + + "iteria\"\266\001\n\016SessionSegment\022Y\n\032session_inc" + + "lusion_criteria\030\001 \001(\01325.google.analytics" + + ".data.v1alpha.SessionSegmentCriteria\022I\n\t" + + "exclusion\030\002 \001(\01326.google.analytics.data." + + "v1alpha.SessionSegmentExclusion\"s\n\026Sessi" + + "onSegmentCriteria\022Y\n\024and_condition_group" + + "s\030\001 \003(\0132;.google.analytics.data.v1alpha." + + "SessionSegmentConditionGroup\"\313\001\n\034Session" + + "SegmentConditionGroup\022P\n\021condition_scopi" + + "ng\030\001 \001(\01625.google.analytics.data.v1alpha" + + ".SessionCriteriaScoping\022Y\n\031segment_filte" + + "r_expression\030\002 \001(\01326.google.analytics.da" + + "ta.v1alpha.SegmentFilterExpression\"\321\001\n\027S" + + "essionSegmentExclusion\022[\n\032session_exclus" + + "ion_duration\030\001 \001(\01627.google.analytics.da" + + "ta.v1alpha.SessionExclusionDuration\022Y\n\032s" + + "ession_exclusion_criteria\030\002 \001(\01325.google" + + ".analytics.data.v1alpha.SessionSegmentCr" + + "iteria\"\256\001\n\014EventSegment\022U\n\030event_inclusi" + + "on_criteria\030\001 \001(\01323.google.analytics.dat" + + "a.v1alpha.EventSegmentCriteria\022G\n\texclus" + + "ion\030\002 \001(\01324.google.analytics.data.v1alph" + + "a.EventSegmentExclusion\"o\n\024EventSegmentC" + + "riteria\022W\n\024and_condition_groups\030\001 \003(\01329." + + "google.analytics.data.v1alpha.EventSegme" + + "ntConditionGroup\"\307\001\n\032EventSegmentConditi" + + "onGroup\022N\n\021condition_scoping\030\001 \001(\01623.goo" + + "gle.analytics.data.v1alpha.EventCriteria" + + "Scoping\022Y\n\031segment_filter_expression\030\002 \001" + + "(\01326.google.analytics.data.v1alpha.Segme" + + "ntFilterExpression\"\307\001\n\025EventSegmentExclu" + + "sion\022W\n\030event_exclusion_duration\030\001 \001(\01625" + + ".google.analytics.data.v1alpha.EventExcl" + + "usionDuration\022U\n\030event_exclusion_criteri" + + "a\030\002 \001(\01323.google.analytics.data.v1alpha." + + "EventSegmentCriteria\"\200\002\n\007Segment\022\014\n\004name" + + "\030\001 \001(\t\022B\n\014user_segment\030\002 \001(\0132*.google.an" + + "alytics.data.v1alpha.UserSegmentH\000\022H\n\017se" + + "ssion_segment\030\003 \001(\0132-.google.analytics.d" + + "ata.v1alpha.SessionSegmentH\000\022D\n\revent_se" + + "gment\030\004 \001(\0132+.google.analytics.data.v1al" + + "pha.EventSegmentH\000B\023\n\021one_segment_scope\"" + + "\257\003\n\027SegmentFilterExpression\022O\n\tand_group" + + "\030\001 \001(\0132:.google.analytics.data.v1alpha.S" + + "egmentFilterExpressionListH\000\022N\n\010or_group" + + "\030\002 \001(\0132:.google.analytics.data.v1alpha.S" + + "egmentFilterExpressionListH\000\022P\n\016not_expr" + + "ession\030\003 \001(\01326.google.analytics.data.v1a" + + "lpha.SegmentFilterExpressionH\000\022F\n\016segmen" + + "t_filter\030\004 \001(\0132,.google.analytics.data.v" + + "1alpha.SegmentFilterH\000\022Q\n\024segment_event_" + + "filter\030\005 \001(\01321.google.analytics.data.v1a" + + "lpha.SegmentEventFilterH\000B\006\n\004expr\"j\n\033Seg" + + "mentFilterExpressionList\022K\n\013expressions\030" + + "\001 \003(\01326.google.analytics.data.v1alpha.Se" + + "gmentFilterExpression\"\233\003\n\rSegmentFilter\022" + + "\022\n\nfield_name\030\001 \001(\t\022D\n\rstring_filter\030\004 \001" + + "(\0132+.google.analytics.data.v1alpha.Strin" + + "gFilterH\000\022E\n\016in_list_filter\030\005 \001(\0132+.goog" + + "le.analytics.data.v1alpha.InListFilterH\000" + + "\022F\n\016numeric_filter\030\006 \001(\0132,.google.analyt" + + "ics.data.v1alpha.NumericFilterH\000\022F\n\016betw" + + "een_filter\030\007 \001(\0132,.google.analytics.data" + + ".v1alpha.BetweenFilterH\000\022K\n\016filter_scopi" + + "ng\030\010 \001(\01323.google.analytics.data.v1alpha" + + ".SegmentFilterScopingB\014\n\none_filter\"R\n\024S" + + "egmentFilterScoping\022!\n\024at_any_point_in_t" + + "ime\030\001 \001(\010H\000\210\001\001B\027\n\025_at_any_point_in_time\"" + + "\327\001\n\022SegmentEventFilter\022\027\n\nevent_name\030\001 \001" + + "(\tH\000\210\001\001\022q\n#segment_parameter_filter_expr" + + "ession\030\002 \001(\0132?.google.analytics.data.v1a" + + "lpha.SegmentParameterFilterExpressionH\001\210" + + "\001\001B\r\n\013_event_nameB&\n$_segment_parameter_" + + "filter_expression\"\223\003\n SegmentParameterFi" + + "lterExpression\022X\n\tand_group\030\001 \001(\0132C.goog" + + "le.analytics.data.v1alpha.SegmentParamet" + + "erFilterExpressionListH\000\022W\n\010or_group\030\002 \001" + + "(\0132C.google.analytics.data.v1alpha.Segme" + + "ntParameterFilterExpressionListH\000\022Y\n\016not" + + "_expression\030\003 \001(\0132?.google.analytics.dat" + + "a.v1alpha.SegmentParameterFilterExpressi" + + "onH\000\022Y\n\030segment_parameter_filter\030\004 \001(\01325" + + ".google.analytics.data.v1alpha.SegmentPa" + + "rameterFilterH\000B\006\n\004expr\"|\n$SegmentParame" + + "terFilterExpressionList\022T\n\013expressions\030\001" + + " \003(\0132?.google.analytics.data.v1alpha.Seg" + + "mentParameterFilterExpression\"\351\003\n\026Segmen" + + "tParameterFilter\022\036\n\024event_parameter_name" + + "\030\001 \001(\tH\000\022\035\n\023item_parameter_name\030\002 \001(\tH\000\022" + + "D\n\rstring_filter\030\004 \001(\0132+.google.analytic" + + "s.data.v1alpha.StringFilterH\001\022E\n\016in_list" + + "_filter\030\005 \001(\0132+.google.analytics.data.v1" + + "alpha.InListFilterH\001\022F\n\016numeric_filter\030\006" + + " \001(\0132,.google.analytics.data.v1alpha.Num" + + "ericFilterH\001\022F\n\016between_filter\030\007 \001(\0132,.g" + + "oogle.analytics.data.v1alpha.BetweenFilt" + + "erH\001\022T\n\016filter_scoping\030\010 \001(\0132<.google.an" + + "alytics.data.v1alpha.SegmentParameterFil" + + "terScopingB\017\n\rone_parameterB\014\n\none_filte" + + "r\"Y\n\035SegmentParameterFilterScoping\022 \n\023in" + + "_any_n_day_period\030\001 \001(\003H\000\210\001\001B\026\n\024_in_any_" + + "n_day_period\"\247\003\n\026FunnelFilterExpression\022" + + "N\n\tand_group\030\001 \001(\01329.google.analytics.da" + + "ta.v1alpha.FunnelFilterExpressionListH\000\022" + + "M\n\010or_group\030\002 \001(\01329.google.analytics.dat" + + "a.v1alpha.FunnelFilterExpressionListH\000\022O" + + "\n\016not_expression\030\003 \001(\01325.google.analytic" + + "s.data.v1alpha.FunnelFilterExpressionH\000\022" + + "D\n\rfunnel_filter\030\004 \001(\0132+.google.analytic" + + "s.data.v1alpha.FunnelFilterH\000\022O\n\023funnel_" + + "event_filter\030\005 \001(\01320.google.analytics.da" + + "ta.v1alpha.FunnelEventFilterH\000B\006\n\004expr\"h" + + "\n\032FunnelFilterExpressionList\022J\n\013expressi" + + "ons\030\001 \003(\01325.google.analytics.data.v1alph" + + "a.FunnelFilterExpression\"\315\002\n\014FunnelFilte" + + "r\022\022\n\nfield_name\030\001 \001(\t\022D\n\rstring_filter\030\004" + + " \001(\0132+.google.analytics.data.v1alpha.Str" + + "ingFilterH\000\022E\n\016in_list_filter\030\005 \001(\0132+.go" + + "ogle.analytics.data.v1alpha.InListFilter" + + "H\000\022F\n\016numeric_filter\030\006 \001(\0132,.google.anal" + + "ytics.data.v1alpha.NumericFilterH\000\022F\n\016be" + + "tween_filter\030\007 \001(\0132,.google.analytics.da" + + "ta.v1alpha.BetweenFilterH\000B\014\n\none_filter" + + "\"\323\001\n\021FunnelEventFilter\022\027\n\nevent_name\030\001 \001" + + "(\tH\000\210\001\001\022o\n\"funnel_parameter_filter_expre" + + "ssion\030\002 \001(\0132>.google.analytics.data.v1al" + + "pha.FunnelParameterFilterExpressionH\001\210\001\001" + + "B\r\n\013_event_nameB%\n#_funnel_parameter_fil" + + "ter_expression\"\215\003\n\037FunnelParameterFilter" + + "Expression\022W\n\tand_group\030\001 \001(\0132B.google.a" + + "nalytics.data.v1alpha.FunnelParameterFil" + + "terExpressionListH\000\022V\n\010or_group\030\002 \001(\0132B." + + "google.analytics.data.v1alpha.FunnelPara" + + "meterFilterExpressionListH\000\022X\n\016not_expre" + + "ssion\030\003 \001(\0132>.google.analytics.data.v1al" + + "pha.FunnelParameterFilterExpressionH\000\022W\n" + + "\027funnel_parameter_filter\030\004 \001(\01324.google." + + "analytics.data.v1alpha.FunnelParameterFi" + + "lterH\000B\006\n\004expr\"z\n#FunnelParameterFilterE" + + "xpressionList\022S\n\013expressions\030\001 \003(\0132>.goo" + + "gle.analytics.data.v1alpha.FunnelParamet" + + "erFilterExpression\"\222\003\n\025FunnelParameterFi" + + "lter\022\036\n\024event_parameter_name\030\001 \001(\tH\000\022\035\n\023" + + "item_parameter_name\030\002 \001(\tH\000\022D\n\rstring_fi" + + "lter\030\004 \001(\0132+.google.analytics.data.v1alp" + + "ha.StringFilterH\001\022E\n\016in_list_filter\030\005 \001(" + + "\0132+.google.analytics.data.v1alpha.InList" + + "FilterH\001\022F\n\016numeric_filter\030\006 \001(\0132,.googl" + + "e.analytics.data.v1alpha.NumericFilterH\001" + + "\022F\n\016between_filter\030\007 \001(\0132,.google.analyt" + + "ics.data.v1alpha.BetweenFilterH\001B\017\n\rone_" + + "parameterB\014\n\none_filter\"e\n\026FunnelRespons" + + "eMetadata\022K\n\022sampling_metadatas\030\001 \003(\0132/." + + "google.analytics.data.v1alpha.SamplingMe" + + "tadata\"K\n\020SamplingMetadata\022\032\n\022samples_re" + + "ad_count\030\001 \001(\003\022\033\n\023sampling_space_size\030\002 " + + "\001(\003*\257\001\n\023UserCriteriaScoping\022%\n!USER_CRIT" + + "ERIA_SCOPING_UNSPECIFIED\020\000\022#\n\037USER_CRITE" + + "RIA_WITHIN_SAME_EVENT\020\001\022%\n!USER_CRITERIA" + + "_WITHIN_SAME_SESSION\020\002\022%\n!USER_CRITERIA_" + + "ACROSS_ALL_SESSIONS\020\003*|\n\025UserExclusionDu" + + "ration\022\'\n#USER_EXCLUSION_DURATION_UNSPEC" + + "IFIED\020\000\022\034\n\030USER_EXCLUSION_TEMPORARY\020\001\022\034\n" + + "\030USER_EXCLUSION_PERMANENT\020\002*\224\001\n\026SessionC" + + "riteriaScoping\022(\n$SESSION_CRITERIA_SCOPI" + + "NG_UNSPECIFIED\020\000\022&\n\"SESSION_CRITERIA_WIT" + + "HIN_SAME_EVENT\020\001\022(\n$SESSION_CRITERIA_WIT" + + "HIN_SAME_SESSION\020\002*\210\001\n\030SessionExclusionD" + + "uration\022*\n&SESSION_EXCLUSION_DURATION_UN" + + "SPECIFIED\020\000\022\037\n\033SESSION_EXCLUSION_TEMPORA" + + "RY\020\001\022\037\n\033SESSION_EXCLUSION_PERMANENT\020\002*d\n" + + "\024EventCriteriaScoping\022&\n\"EVENT_CRITERIA_" + + "SCOPING_UNSPECIFIED\020\000\022$\n EVENT_CRITERIA_" + + "WITHIN_SAME_EVENT\020\001*a\n\026EventExclusionDur" + + "ation\022(\n$EVENT_EXCLUSION_DURATION_UNSPEC" + + "IFIED\020\000\022\035\n\031EVENT_EXCLUSION_PERMANENT\020\001*\201" + + "\002\n\nMetricType\022\033\n\027METRIC_TYPE_UNSPECIFIED" + + "\020\000\022\020\n\014TYPE_INTEGER\020\001\022\016\n\nTYPE_FLOAT\020\002\022\020\n\014" + + "TYPE_SECONDS\020\004\022\025\n\021TYPE_MILLISECONDS\020\005\022\020\n" + + "\014TYPE_MINUTES\020\006\022\016\n\nTYPE_HOURS\020\007\022\021\n\rTYPE_" + + "STANDARD\020\010\022\021\n\rTYPE_CURRENCY\020\t\022\r\n\tTYPE_FE" + + "ET\020\n\022\016\n\nTYPE_MILES\020\013\022\017\n\013TYPE_METERS\020\014\022\023\n" + + "\017TYPE_KILOMETERS\020\rB{\n!com.google.analyti" + + "cs.data.v1alphaB\021ReportingApiProtoP\001ZAgo" + + "ogle.golang.org/genproto/googleapis/anal" + + "ytics/data/v1alpha;datab\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.protobuf.DurationProto.getDescriptor(), + }); + internal_static_google_analytics_data_v1alpha_DateRange_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_analytics_data_v1alpha_DateRange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_DateRange_descriptor, + new java.lang.String[] { + "StartDate", "EndDate", "Name", + }); + internal_static_google_analytics_data_v1alpha_Dimension_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_analytics_data_v1alpha_Dimension_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_Dimension_descriptor, + new java.lang.String[] { + "Name", "DimensionExpression", + }); + internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_analytics_data_v1alpha_DimensionExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor, + new java.lang.String[] { + "LowerCase", "UpperCase", "Concatenate", "OneExpression", + }); + internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_descriptor = + internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor + .getNestedTypes() + .get(0); + internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_DimensionExpression_CaseExpression_descriptor, + new java.lang.String[] { + "DimensionName", + }); + internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_descriptor = + internal_static_google_analytics_data_v1alpha_DimensionExpression_descriptor + .getNestedTypes() + .get(1); + internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_DimensionExpression_ConcatenateExpression_descriptor, + new java.lang.String[] { + "DimensionNames", "Delimiter", + }); + internal_static_google_analytics_data_v1alpha_FilterExpression_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_analytics_data_v1alpha_FilterExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FilterExpression_descriptor, + new java.lang.String[] { + "AndGroup", "OrGroup", "NotExpression", "Filter", "Expr", + }); + internal_static_google_analytics_data_v1alpha_FilterExpressionList_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_analytics_data_v1alpha_FilterExpressionList_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FilterExpressionList_descriptor, + new java.lang.String[] { + "Expressions", + }); + internal_static_google_analytics_data_v1alpha_Filter_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_analytics_data_v1alpha_Filter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_Filter_descriptor, + new java.lang.String[] { + "FieldName", + "StringFilter", + "InListFilter", + "NumericFilter", + "BetweenFilter", + "OneFilter", + }); + internal_static_google_analytics_data_v1alpha_StringFilter_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_analytics_data_v1alpha_StringFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_StringFilter_descriptor, + new java.lang.String[] { + "MatchType", "Value", "CaseSensitive", + }); + internal_static_google_analytics_data_v1alpha_InListFilter_descriptor = + getDescriptor().getMessageTypes().get(7); + internal_static_google_analytics_data_v1alpha_InListFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_InListFilter_descriptor, + new java.lang.String[] { + "Values", "CaseSensitive", + }); + internal_static_google_analytics_data_v1alpha_NumericFilter_descriptor = + getDescriptor().getMessageTypes().get(8); + internal_static_google_analytics_data_v1alpha_NumericFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_NumericFilter_descriptor, + new java.lang.String[] { + "Operation", "Value", + }); + internal_static_google_analytics_data_v1alpha_BetweenFilter_descriptor = + getDescriptor().getMessageTypes().get(9); + internal_static_google_analytics_data_v1alpha_BetweenFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_BetweenFilter_descriptor, + new java.lang.String[] { + "FromValue", "ToValue", + }); + internal_static_google_analytics_data_v1alpha_NumericValue_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_analytics_data_v1alpha_NumericValue_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_NumericValue_descriptor, + new java.lang.String[] { + "Int64Value", "DoubleValue", "OneValue", + }); + internal_static_google_analytics_data_v1alpha_DimensionHeader_descriptor = + getDescriptor().getMessageTypes().get(11); + internal_static_google_analytics_data_v1alpha_DimensionHeader_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_DimensionHeader_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_analytics_data_v1alpha_MetricHeader_descriptor = + getDescriptor().getMessageTypes().get(12); + internal_static_google_analytics_data_v1alpha_MetricHeader_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_MetricHeader_descriptor, + new java.lang.String[] { + "Name", "Type", + }); + internal_static_google_analytics_data_v1alpha_Row_descriptor = + getDescriptor().getMessageTypes().get(13); + internal_static_google_analytics_data_v1alpha_Row_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_Row_descriptor, + new java.lang.String[] { + "DimensionValues", "MetricValues", + }); + internal_static_google_analytics_data_v1alpha_DimensionValue_descriptor = + getDescriptor().getMessageTypes().get(14); + internal_static_google_analytics_data_v1alpha_DimensionValue_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_DimensionValue_descriptor, + new java.lang.String[] { + "Value", "OneValue", + }); + internal_static_google_analytics_data_v1alpha_MetricValue_descriptor = + getDescriptor().getMessageTypes().get(15); + internal_static_google_analytics_data_v1alpha_MetricValue_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_MetricValue_descriptor, + new java.lang.String[] { + "Value", "OneValue", + }); + internal_static_google_analytics_data_v1alpha_PropertyQuota_descriptor = + getDescriptor().getMessageTypes().get(16); + internal_static_google_analytics_data_v1alpha_PropertyQuota_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_PropertyQuota_descriptor, + new java.lang.String[] { + "TokensPerDay", + "TokensPerHour", + "ConcurrentRequests", + "ServerErrorsPerProjectPerHour", + "PotentiallyThresholdedRequestsPerHour", + }); + internal_static_google_analytics_data_v1alpha_QuotaStatus_descriptor = + getDescriptor().getMessageTypes().get(17); + internal_static_google_analytics_data_v1alpha_QuotaStatus_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_QuotaStatus_descriptor, + new java.lang.String[] { + "Consumed", "Remaining", + }); + internal_static_google_analytics_data_v1alpha_FunnelBreakdown_descriptor = + getDescriptor().getMessageTypes().get(18); + internal_static_google_analytics_data_v1alpha_FunnelBreakdown_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelBreakdown_descriptor, + new java.lang.String[] { + "BreakdownDimension", "Limit", "Limit", + }); + internal_static_google_analytics_data_v1alpha_FunnelNextAction_descriptor = + getDescriptor().getMessageTypes().get(19); + internal_static_google_analytics_data_v1alpha_FunnelNextAction_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelNextAction_descriptor, + new java.lang.String[] { + "NextActionDimension", "Limit", "Limit", + }); + internal_static_google_analytics_data_v1alpha_Funnel_descriptor = + getDescriptor().getMessageTypes().get(20); + internal_static_google_analytics_data_v1alpha_Funnel_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_Funnel_descriptor, + new java.lang.String[] { + "IsOpenFunnel", "Steps", + }); + internal_static_google_analytics_data_v1alpha_FunnelStep_descriptor = + getDescriptor().getMessageTypes().get(21); + internal_static_google_analytics_data_v1alpha_FunnelStep_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelStep_descriptor, + new java.lang.String[] { + "Name", + "IsDirectlyFollowedBy", + "WithinDurationFromPriorStep", + "FilterExpression", + "WithinDurationFromPriorStep", + }); + internal_static_google_analytics_data_v1alpha_FunnelSubReport_descriptor = + getDescriptor().getMessageTypes().get(22); + internal_static_google_analytics_data_v1alpha_FunnelSubReport_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelSubReport_descriptor, + new java.lang.String[] { + "DimensionHeaders", "MetricHeaders", "Rows", "Metadata", + }); + internal_static_google_analytics_data_v1alpha_UserSegment_descriptor = + getDescriptor().getMessageTypes().get(23); + internal_static_google_analytics_data_v1alpha_UserSegment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_UserSegment_descriptor, + new java.lang.String[] { + "UserInclusionCriteria", "Exclusion", + }); + internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_descriptor = + getDescriptor().getMessageTypes().get(24); + internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_descriptor, + new java.lang.String[] { + "AndConditionGroups", "AndSequenceGroups", + }); + internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_descriptor = + getDescriptor().getMessageTypes().get(25); + internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_descriptor, + new java.lang.String[] { + "ConditionScoping", "SegmentFilterExpression", + }); + internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_descriptor = + getDescriptor().getMessageTypes().get(26); + internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_descriptor, + new java.lang.String[] { + "SequenceScoping", "SequenceMaximumDuration", "UserSequenceSteps", + }); + internal_static_google_analytics_data_v1alpha_UserSequenceStep_descriptor = + getDescriptor().getMessageTypes().get(27); + internal_static_google_analytics_data_v1alpha_UserSequenceStep_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_UserSequenceStep_descriptor, + new java.lang.String[] { + "IsDirectlyFollowedBy", "StepScoping", "SegmentFilterExpression", + }); + internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_descriptor = + getDescriptor().getMessageTypes().get(28); + internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_descriptor, + new java.lang.String[] { + "UserExclusionDuration", "UserExclusionCriteria", + }); + internal_static_google_analytics_data_v1alpha_SessionSegment_descriptor = + getDescriptor().getMessageTypes().get(29); + internal_static_google_analytics_data_v1alpha_SessionSegment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SessionSegment_descriptor, + new java.lang.String[] { + "SessionInclusionCriteria", "Exclusion", + }); + internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_descriptor = + getDescriptor().getMessageTypes().get(30); + internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_descriptor, + new java.lang.String[] { + "AndConditionGroups", + }); + internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_descriptor = + getDescriptor().getMessageTypes().get(31); + internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_descriptor, + new java.lang.String[] { + "ConditionScoping", "SegmentFilterExpression", + }); + internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_descriptor = + getDescriptor().getMessageTypes().get(32); + internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_descriptor, + new java.lang.String[] { + "SessionExclusionDuration", "SessionExclusionCriteria", + }); + internal_static_google_analytics_data_v1alpha_EventSegment_descriptor = + getDescriptor().getMessageTypes().get(33); + internal_static_google_analytics_data_v1alpha_EventSegment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_EventSegment_descriptor, + new java.lang.String[] { + "EventInclusionCriteria", "Exclusion", + }); + internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_descriptor = + getDescriptor().getMessageTypes().get(34); + internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_EventSegmentCriteria_descriptor, + new java.lang.String[] { + "AndConditionGroups", + }); + internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_descriptor = + getDescriptor().getMessageTypes().get(35); + internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_EventSegmentConditionGroup_descriptor, + new java.lang.String[] { + "ConditionScoping", "SegmentFilterExpression", + }); + internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_descriptor = + getDescriptor().getMessageTypes().get(36); + internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_EventSegmentExclusion_descriptor, + new java.lang.String[] { + "EventExclusionDuration", "EventExclusionCriteria", + }); + internal_static_google_analytics_data_v1alpha_Segment_descriptor = + getDescriptor().getMessageTypes().get(37); + internal_static_google_analytics_data_v1alpha_Segment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_Segment_descriptor, + new java.lang.String[] { + "Name", "UserSegment", "SessionSegment", "EventSegment", "OneSegmentScope", + }); + internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_descriptor = + getDescriptor().getMessageTypes().get(38); + internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_descriptor, + new java.lang.String[] { + "AndGroup", "OrGroup", "NotExpression", "SegmentFilter", "SegmentEventFilter", "Expr", + }); + internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_descriptor = + getDescriptor().getMessageTypes().get(39); + internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_descriptor, + new java.lang.String[] { + "Expressions", + }); + internal_static_google_analytics_data_v1alpha_SegmentFilter_descriptor = + getDescriptor().getMessageTypes().get(40); + internal_static_google_analytics_data_v1alpha_SegmentFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentFilter_descriptor, + new java.lang.String[] { + "FieldName", + "StringFilter", + "InListFilter", + "NumericFilter", + "BetweenFilter", + "FilterScoping", + "OneFilter", + }); + internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_descriptor = + getDescriptor().getMessageTypes().get(41); + internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_descriptor, + new java.lang.String[] { + "AtAnyPointInTime", "AtAnyPointInTime", + }); + internal_static_google_analytics_data_v1alpha_SegmentEventFilter_descriptor = + getDescriptor().getMessageTypes().get(42); + internal_static_google_analytics_data_v1alpha_SegmentEventFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentEventFilter_descriptor, + new java.lang.String[] { + "EventName", + "SegmentParameterFilterExpression", + "EventName", + "SegmentParameterFilterExpression", + }); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_descriptor = + getDescriptor().getMessageTypes().get(43); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_descriptor, + new java.lang.String[] { + "AndGroup", "OrGroup", "NotExpression", "SegmentParameterFilter", "Expr", + }); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_descriptor = + getDescriptor().getMessageTypes().get(44); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_descriptor, + new java.lang.String[] { + "Expressions", + }); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_descriptor = + getDescriptor().getMessageTypes().get(45); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_descriptor, + new java.lang.String[] { + "EventParameterName", + "ItemParameterName", + "StringFilter", + "InListFilter", + "NumericFilter", + "BetweenFilter", + "FilterScoping", + "OneParameter", + "OneFilter", + }); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_descriptor = + getDescriptor().getMessageTypes().get(46); + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_descriptor, + new java.lang.String[] { + "InAnyNDayPeriod", "InAnyNDayPeriod", + }); + internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_descriptor = + getDescriptor().getMessageTypes().get(47); + internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelFilterExpression_descriptor, + new java.lang.String[] { + "AndGroup", "OrGroup", "NotExpression", "FunnelFilter", "FunnelEventFilter", "Expr", + }); + internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_descriptor = + getDescriptor().getMessageTypes().get(48); + internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelFilterExpressionList_descriptor, + new java.lang.String[] { + "Expressions", + }); + internal_static_google_analytics_data_v1alpha_FunnelFilter_descriptor = + getDescriptor().getMessageTypes().get(49); + internal_static_google_analytics_data_v1alpha_FunnelFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelFilter_descriptor, + new java.lang.String[] { + "FieldName", + "StringFilter", + "InListFilter", + "NumericFilter", + "BetweenFilter", + "OneFilter", + }); + internal_static_google_analytics_data_v1alpha_FunnelEventFilter_descriptor = + getDescriptor().getMessageTypes().get(50); + internal_static_google_analytics_data_v1alpha_FunnelEventFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelEventFilter_descriptor, + new java.lang.String[] { + "EventName", + "FunnelParameterFilterExpression", + "EventName", + "FunnelParameterFilterExpression", + }); + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_descriptor = + getDescriptor().getMessageTypes().get(51); + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpression_descriptor, + new java.lang.String[] { + "AndGroup", "OrGroup", "NotExpression", "FunnelParameterFilter", "Expr", + }); + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_descriptor = + getDescriptor().getMessageTypes().get(52); + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelParameterFilterExpressionList_descriptor, + new java.lang.String[] { + "Expressions", + }); + internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_descriptor = + getDescriptor().getMessageTypes().get(53); + internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelParameterFilter_descriptor, + new java.lang.String[] { + "EventParameterName", + "ItemParameterName", + "StringFilter", + "InListFilter", + "NumericFilter", + "BetweenFilter", + "OneParameter", + "OneFilter", + }); + internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_descriptor = + getDescriptor().getMessageTypes().get(54); + internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_FunnelResponseMetadata_descriptor, + new java.lang.String[] { + "SamplingMetadatas", + }); + internal_static_google_analytics_data_v1alpha_SamplingMetadata_descriptor = + getDescriptor().getMessageTypes().get(55); + internal_static_google_analytics_data_v1alpha_SamplingMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_analytics_data_v1alpha_SamplingMetadata_descriptor, + new java.lang.String[] { + "SamplesReadCount", "SamplingSpaceSize", + }); + com.google.protobuf.DurationProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Row.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Row.java new file mode 100644 index 00000000..9e8d5452 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Row.java @@ -0,0 +1,1543 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Report data for each row.
+ * For example if RunReportRequest contains:
+ * ```none
+ * "dimensions": [
+ *   {
+ *     "name": "eventName"
+ *   },
+ *   {
+ *     "name": "countryId"
+ *   }
+ * ],
+ * "metrics": [
+ *   {
+ *     "name": "eventCount"
+ *   }
+ * ]
+ * ```
+ * One row with 'in_app_purchase' as the eventName, 'JP' as the countryId, and
+ * 15 as the eventCount, would be:
+ * ```none
+ * "dimensionValues": [
+ *   {
+ *     "value": "in_app_purchase"
+ *   },
+ *   {
+ *     "value": "JP"
+ *   }
+ * ],
+ * "metricValues": [
+ *   {
+ *     "value": "15"
+ *   }
+ * ]
+ * ```
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Row} + */ +public final class Row extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.Row) + RowOrBuilder { + private static final long serialVersionUID = 0L; + // Use Row.newBuilder() to construct. + private Row(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Row() { + dimensionValues_ = java.util.Collections.emptyList(); + metricValues_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Row(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Row( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + dimensionValues_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + dimensionValues_.add( + input.readMessage( + com.google.analytics.data.v1alpha.DimensionValue.parser(), + extensionRegistry)); + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + metricValues_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + metricValues_.add( + input.readMessage( + com.google.analytics.data.v1alpha.MetricValue.parser(), extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + dimensionValues_ = java.util.Collections.unmodifiableList(dimensionValues_); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + metricValues_ = java.util.Collections.unmodifiableList(metricValues_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Row_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Row_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Row.class, + com.google.analytics.data.v1alpha.Row.Builder.class); + } + + public static final int DIMENSION_VALUES_FIELD_NUMBER = 1; + private java.util.List dimensionValues_; + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + @java.lang.Override + public java.util.List getDimensionValuesList() { + return dimensionValues_; + } + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + @java.lang.Override + public java.util.List + getDimensionValuesOrBuilderList() { + return dimensionValues_; + } + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + @java.lang.Override + public int getDimensionValuesCount() { + return dimensionValues_.size(); + } + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionValue getDimensionValues(int index) { + return dimensionValues_.get(index); + } + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DimensionValueOrBuilder getDimensionValuesOrBuilder( + int index) { + return dimensionValues_.get(index); + } + + public static final int METRIC_VALUES_FIELD_NUMBER = 2; + private java.util.List metricValues_; + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + @java.lang.Override + public java.util.List getMetricValuesList() { + return metricValues_; + } + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + @java.lang.Override + public java.util.List + getMetricValuesOrBuilderList() { + return metricValues_; + } + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + @java.lang.Override + public int getMetricValuesCount() { + return metricValues_.size(); + } + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricValue getMetricValues(int index) { + return metricValues_.get(index); + } + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.MetricValueOrBuilder getMetricValuesOrBuilder( + int index) { + return metricValues_.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 < dimensionValues_.size(); i++) { + output.writeMessage(1, dimensionValues_.get(i)); + } + for (int i = 0; i < metricValues_.size(); i++) { + output.writeMessage(2, metricValues_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < dimensionValues_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, dimensionValues_.get(i)); + } + for (int i = 0; i < metricValues_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, metricValues_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.Row)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.Row other = (com.google.analytics.data.v1alpha.Row) obj; + + if (!getDimensionValuesList().equals(other.getDimensionValuesList())) return false; + if (!getMetricValuesList().equals(other.getMetricValuesList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getDimensionValuesCount() > 0) { + hash = (37 * hash) + DIMENSION_VALUES_FIELD_NUMBER; + hash = (53 * hash) + getDimensionValuesList().hashCode(); + } + if (getMetricValuesCount() > 0) { + hash = (37 * hash) + METRIC_VALUES_FIELD_NUMBER; + hash = (53 * hash) + getMetricValuesList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.Row parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Row 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.analytics.data.v1alpha.Row parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Row parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Row parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Row parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.Row 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Report data for each row.
+   * For example if RunReportRequest contains:
+   * ```none
+   * "dimensions": [
+   *   {
+   *     "name": "eventName"
+   *   },
+   *   {
+   *     "name": "countryId"
+   *   }
+   * ],
+   * "metrics": [
+   *   {
+   *     "name": "eventCount"
+   *   }
+   * ]
+   * ```
+   * One row with 'in_app_purchase' as the eventName, 'JP' as the countryId, and
+   * 15 as the eventCount, would be:
+   * ```none
+   * "dimensionValues": [
+   *   {
+   *     "value": "in_app_purchase"
+   *   },
+   *   {
+   *     "value": "JP"
+   *   }
+   * ],
+   * "metricValues": [
+   *   {
+   *     "value": "15"
+   *   }
+   * ]
+   * ```
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Row} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.Row) + com.google.analytics.data.v1alpha.RowOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Row_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Row_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Row.class, + com.google.analytics.data.v1alpha.Row.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.Row.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getDimensionValuesFieldBuilder(); + getMetricValuesFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (dimensionValuesBuilder_ == null) { + dimensionValues_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + dimensionValuesBuilder_.clear(); + } + if (metricValuesBuilder_ == null) { + metricValues_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + metricValuesBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Row_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Row getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.Row.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Row build() { + com.google.analytics.data.v1alpha.Row result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Row buildPartial() { + com.google.analytics.data.v1alpha.Row result = + new com.google.analytics.data.v1alpha.Row(this); + int from_bitField0_ = bitField0_; + if (dimensionValuesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + dimensionValues_ = java.util.Collections.unmodifiableList(dimensionValues_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.dimensionValues_ = dimensionValues_; + } else { + result.dimensionValues_ = dimensionValuesBuilder_.build(); + } + if (metricValuesBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + metricValues_ = java.util.Collections.unmodifiableList(metricValues_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.metricValues_ = metricValues_; + } else { + result.metricValues_ = metricValuesBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.Row) { + return mergeFrom((com.google.analytics.data.v1alpha.Row) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.Row other) { + if (other == com.google.analytics.data.v1alpha.Row.getDefaultInstance()) return this; + if (dimensionValuesBuilder_ == null) { + if (!other.dimensionValues_.isEmpty()) { + if (dimensionValues_.isEmpty()) { + dimensionValues_ = other.dimensionValues_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureDimensionValuesIsMutable(); + dimensionValues_.addAll(other.dimensionValues_); + } + onChanged(); + } + } else { + if (!other.dimensionValues_.isEmpty()) { + if (dimensionValuesBuilder_.isEmpty()) { + dimensionValuesBuilder_.dispose(); + dimensionValuesBuilder_ = null; + dimensionValues_ = other.dimensionValues_; + bitField0_ = (bitField0_ & ~0x00000001); + dimensionValuesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getDimensionValuesFieldBuilder() + : null; + } else { + dimensionValuesBuilder_.addAllMessages(other.dimensionValues_); + } + } + } + if (metricValuesBuilder_ == null) { + if (!other.metricValues_.isEmpty()) { + if (metricValues_.isEmpty()) { + metricValues_ = other.metricValues_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureMetricValuesIsMutable(); + metricValues_.addAll(other.metricValues_); + } + onChanged(); + } + } else { + if (!other.metricValues_.isEmpty()) { + if (metricValuesBuilder_.isEmpty()) { + metricValuesBuilder_.dispose(); + metricValuesBuilder_ = null; + metricValues_ = other.metricValues_; + bitField0_ = (bitField0_ & ~0x00000002); + metricValuesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getMetricValuesFieldBuilder() + : null; + } else { + metricValuesBuilder_.addAllMessages(other.metricValues_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.Row parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.Row) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List dimensionValues_ = + java.util.Collections.emptyList(); + + private void ensureDimensionValuesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + dimensionValues_ = + new java.util.ArrayList( + dimensionValues_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionValue, + com.google.analytics.data.v1alpha.DimensionValue.Builder, + com.google.analytics.data.v1alpha.DimensionValueOrBuilder> + dimensionValuesBuilder_; + + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public java.util.List + getDimensionValuesList() { + if (dimensionValuesBuilder_ == null) { + return java.util.Collections.unmodifiableList(dimensionValues_); + } else { + return dimensionValuesBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public int getDimensionValuesCount() { + if (dimensionValuesBuilder_ == null) { + return dimensionValues_.size(); + } else { + return dimensionValuesBuilder_.getCount(); + } + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public com.google.analytics.data.v1alpha.DimensionValue getDimensionValues(int index) { + if (dimensionValuesBuilder_ == null) { + return dimensionValues_.get(index); + } else { + return dimensionValuesBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder setDimensionValues( + int index, com.google.analytics.data.v1alpha.DimensionValue value) { + if (dimensionValuesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionValuesIsMutable(); + dimensionValues_.set(index, value); + onChanged(); + } else { + dimensionValuesBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder setDimensionValues( + int index, com.google.analytics.data.v1alpha.DimensionValue.Builder builderForValue) { + if (dimensionValuesBuilder_ == null) { + ensureDimensionValuesIsMutable(); + dimensionValues_.set(index, builderForValue.build()); + onChanged(); + } else { + dimensionValuesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder addDimensionValues(com.google.analytics.data.v1alpha.DimensionValue value) { + if (dimensionValuesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionValuesIsMutable(); + dimensionValues_.add(value); + onChanged(); + } else { + dimensionValuesBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder addDimensionValues( + int index, com.google.analytics.data.v1alpha.DimensionValue value) { + if (dimensionValuesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionValuesIsMutable(); + dimensionValues_.add(index, value); + onChanged(); + } else { + dimensionValuesBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder addDimensionValues( + com.google.analytics.data.v1alpha.DimensionValue.Builder builderForValue) { + if (dimensionValuesBuilder_ == null) { + ensureDimensionValuesIsMutable(); + dimensionValues_.add(builderForValue.build()); + onChanged(); + } else { + dimensionValuesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder addDimensionValues( + int index, com.google.analytics.data.v1alpha.DimensionValue.Builder builderForValue) { + if (dimensionValuesBuilder_ == null) { + ensureDimensionValuesIsMutable(); + dimensionValues_.add(index, builderForValue.build()); + onChanged(); + } else { + dimensionValuesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder addAllDimensionValues( + java.lang.Iterable values) { + if (dimensionValuesBuilder_ == null) { + ensureDimensionValuesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, dimensionValues_); + onChanged(); + } else { + dimensionValuesBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder clearDimensionValues() { + if (dimensionValuesBuilder_ == null) { + dimensionValues_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + dimensionValuesBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public Builder removeDimensionValues(int index) { + if (dimensionValuesBuilder_ == null) { + ensureDimensionValuesIsMutable(); + dimensionValues_.remove(index); + onChanged(); + } else { + dimensionValuesBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public com.google.analytics.data.v1alpha.DimensionValue.Builder getDimensionValuesBuilder( + int index) { + return getDimensionValuesFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public com.google.analytics.data.v1alpha.DimensionValueOrBuilder getDimensionValuesOrBuilder( + int index) { + if (dimensionValuesBuilder_ == null) { + return dimensionValues_.get(index); + } else { + return dimensionValuesBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public java.util.List + getDimensionValuesOrBuilderList() { + if (dimensionValuesBuilder_ != null) { + return dimensionValuesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(dimensionValues_); + } + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public com.google.analytics.data.v1alpha.DimensionValue.Builder addDimensionValuesBuilder() { + return getDimensionValuesFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.DimensionValue.getDefaultInstance()); + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public com.google.analytics.data.v1alpha.DimensionValue.Builder addDimensionValuesBuilder( + int index) { + return getDimensionValuesFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.DimensionValue.getDefaultInstance()); + } + /** + * + * + *
+     * List of requested dimension values. In a PivotReport, dimension_values
+     * are only listed for dimensions included in a pivot.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + public java.util.List + getDimensionValuesBuilderList() { + return getDimensionValuesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionValue, + com.google.analytics.data.v1alpha.DimensionValue.Builder, + com.google.analytics.data.v1alpha.DimensionValueOrBuilder> + getDimensionValuesFieldBuilder() { + if (dimensionValuesBuilder_ == null) { + dimensionValuesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DimensionValue, + com.google.analytics.data.v1alpha.DimensionValue.Builder, + com.google.analytics.data.v1alpha.DimensionValueOrBuilder>( + dimensionValues_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + dimensionValues_ = null; + } + return dimensionValuesBuilder_; + } + + private java.util.List metricValues_ = + java.util.Collections.emptyList(); + + private void ensureMetricValuesIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + metricValues_ = + new java.util.ArrayList(metricValues_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.MetricValue, + com.google.analytics.data.v1alpha.MetricValue.Builder, + com.google.analytics.data.v1alpha.MetricValueOrBuilder> + metricValuesBuilder_; + + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public java.util.List getMetricValuesList() { + if (metricValuesBuilder_ == null) { + return java.util.Collections.unmodifiableList(metricValues_); + } else { + return metricValuesBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public int getMetricValuesCount() { + if (metricValuesBuilder_ == null) { + return metricValues_.size(); + } else { + return metricValuesBuilder_.getCount(); + } + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public com.google.analytics.data.v1alpha.MetricValue getMetricValues(int index) { + if (metricValuesBuilder_ == null) { + return metricValues_.get(index); + } else { + return metricValuesBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder setMetricValues(int index, com.google.analytics.data.v1alpha.MetricValue value) { + if (metricValuesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricValuesIsMutable(); + metricValues_.set(index, value); + onChanged(); + } else { + metricValuesBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder setMetricValues( + int index, com.google.analytics.data.v1alpha.MetricValue.Builder builderForValue) { + if (metricValuesBuilder_ == null) { + ensureMetricValuesIsMutable(); + metricValues_.set(index, builderForValue.build()); + onChanged(); + } else { + metricValuesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder addMetricValues(com.google.analytics.data.v1alpha.MetricValue value) { + if (metricValuesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricValuesIsMutable(); + metricValues_.add(value); + onChanged(); + } else { + metricValuesBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder addMetricValues(int index, com.google.analytics.data.v1alpha.MetricValue value) { + if (metricValuesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricValuesIsMutable(); + metricValues_.add(index, value); + onChanged(); + } else { + metricValuesBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder addMetricValues( + com.google.analytics.data.v1alpha.MetricValue.Builder builderForValue) { + if (metricValuesBuilder_ == null) { + ensureMetricValuesIsMutable(); + metricValues_.add(builderForValue.build()); + onChanged(); + } else { + metricValuesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder addMetricValues( + int index, com.google.analytics.data.v1alpha.MetricValue.Builder builderForValue) { + if (metricValuesBuilder_ == null) { + ensureMetricValuesIsMutable(); + metricValues_.add(index, builderForValue.build()); + onChanged(); + } else { + metricValuesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder addAllMetricValues( + java.lang.Iterable values) { + if (metricValuesBuilder_ == null) { + ensureMetricValuesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, metricValues_); + onChanged(); + } else { + metricValuesBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder clearMetricValues() { + if (metricValuesBuilder_ == null) { + metricValues_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + metricValuesBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public Builder removeMetricValues(int index) { + if (metricValuesBuilder_ == null) { + ensureMetricValuesIsMutable(); + metricValues_.remove(index); + onChanged(); + } else { + metricValuesBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public com.google.analytics.data.v1alpha.MetricValue.Builder getMetricValuesBuilder(int index) { + return getMetricValuesFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public com.google.analytics.data.v1alpha.MetricValueOrBuilder getMetricValuesOrBuilder( + int index) { + if (metricValuesBuilder_ == null) { + return metricValues_.get(index); + } else { + return metricValuesBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public java.util.List + getMetricValuesOrBuilderList() { + if (metricValuesBuilder_ != null) { + return metricValuesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(metricValues_); + } + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public com.google.analytics.data.v1alpha.MetricValue.Builder addMetricValuesBuilder() { + return getMetricValuesFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.MetricValue.getDefaultInstance()); + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public com.google.analytics.data.v1alpha.MetricValue.Builder addMetricValuesBuilder(int index) { + return getMetricValuesFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.MetricValue.getDefaultInstance()); + } + /** + * + * + *
+     * List of requested visible metric values.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + public java.util.List + getMetricValuesBuilderList() { + return getMetricValuesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.MetricValue, + com.google.analytics.data.v1alpha.MetricValue.Builder, + com.google.analytics.data.v1alpha.MetricValueOrBuilder> + getMetricValuesFieldBuilder() { + if (metricValuesBuilder_ == null) { + metricValuesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.MetricValue, + com.google.analytics.data.v1alpha.MetricValue.Builder, + com.google.analytics.data.v1alpha.MetricValueOrBuilder>( + metricValues_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + metricValues_ = null; + } + return metricValuesBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.Row) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.Row) + private static final com.google.analytics.data.v1alpha.Row DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.Row(); + } + + public static com.google.analytics.data.v1alpha.Row getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Row parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Row(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.Row getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RowOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RowOrBuilder.java new file mode 100644 index 00000000..822a7fd3 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RowOrBuilder.java @@ -0,0 +1,134 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface RowOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.Row) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + java.util.List getDimensionValuesList(); + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + com.google.analytics.data.v1alpha.DimensionValue getDimensionValues(int index); + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + int getDimensionValuesCount(); + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + java.util.List + getDimensionValuesOrBuilderList(); + /** + * + * + *
+   * List of requested dimension values. In a PivotReport, dimension_values
+   * are only listed for dimensions included in a pivot.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + com.google.analytics.data.v1alpha.DimensionValueOrBuilder getDimensionValuesOrBuilder(int index); + + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + java.util.List getMetricValuesList(); + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + com.google.analytics.data.v1alpha.MetricValue getMetricValues(int index); + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + int getMetricValuesCount(); + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + java.util.List + getMetricValuesOrBuilderList(); + /** + * + * + *
+   * List of requested visible metric values.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + com.google.analytics.data.v1alpha.MetricValueOrBuilder getMetricValuesOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequest.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequest.java new file mode 100644 index 00000000..894352f3 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequest.java @@ -0,0 +1,3672 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/analytics_data_api.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The request for a funnel report.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.RunFunnelReportRequest} + */ +public final class RunFunnelReportRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.RunFunnelReportRequest) + RunFunnelReportRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use RunFunnelReportRequest.newBuilder() to construct. + private RunFunnelReportRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RunFunnelReportRequest() { + property_ = ""; + dateRanges_ = java.util.Collections.emptyList(); + funnelVisualizationType_ = 0; + segments_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RunFunnelReportRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private RunFunnelReportRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + property_ = s; + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + dateRanges_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + dateRanges_.add( + input.readMessage( + com.google.analytics.data.v1alpha.DateRange.parser(), extensionRegistry)); + break; + } + case 26: + { + com.google.analytics.data.v1alpha.Funnel.Builder subBuilder = null; + if (funnel_ != null) { + subBuilder = funnel_.toBuilder(); + } + funnel_ = + input.readMessage( + com.google.analytics.data.v1alpha.Funnel.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(funnel_); + funnel_ = subBuilder.buildPartial(); + } + + break; + } + case 34: + { + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder subBuilder = null; + if (funnelBreakdown_ != null) { + subBuilder = funnelBreakdown_.toBuilder(); + } + funnelBreakdown_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelBreakdown.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(funnelBreakdown_); + funnelBreakdown_ = subBuilder.buildPartial(); + } + + break; + } + case 42: + { + com.google.analytics.data.v1alpha.FunnelNextAction.Builder subBuilder = null; + if (funnelNextAction_ != null) { + subBuilder = funnelNextAction_.toBuilder(); + } + funnelNextAction_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelNextAction.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(funnelNextAction_); + funnelNextAction_ = subBuilder.buildPartial(); + } + + break; + } + case 48: + { + int rawValue = input.readEnum(); + + funnelVisualizationType_ = rawValue; + break; + } + case 58: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + segments_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + segments_.add( + input.readMessage( + com.google.analytics.data.v1alpha.Segment.parser(), extensionRegistry)); + break; + } + case 72: + { + limit_ = input.readInt64(); + break; + } + case 82: + { + com.google.analytics.data.v1alpha.FilterExpression.Builder subBuilder = null; + if (dimensionFilter_ != null) { + subBuilder = dimensionFilter_.toBuilder(); + } + dimensionFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.FilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(dimensionFilter_); + dimensionFilter_ = subBuilder.buildPartial(); + } + + break; + } + case 96: + { + returnPropertyQuota_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + dateRanges_ = java.util.Collections.unmodifiableList(dateRanges_); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + segments_ = java.util.Collections.unmodifiableList(segments_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.RunFunnelReportRequest.class, + com.google.analytics.data.v1alpha.RunFunnelReportRequest.Builder.class); + } + + /** + * + * + *
+   * Controls the dimensions present in the funnel visualization sub report
+   * response.
+   * 
+ * + * Protobuf enum {@code + * google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType} + */ + public enum FunnelVisualizationType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified type.
+     * 
+ * + * FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; + */ + FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * A standard (stepped) funnel. The funnel visualization sub report in the
+     * response will not contain date.
+     * 
+ * + * STANDARD_FUNNEL = 1; + */ + STANDARD_FUNNEL(1), + /** + * + * + *
+     * A trended (line chart) funnel. The funnel visualization sub report in the
+     * response will contain the date dimension.
+     * 
+ * + * TRENDED_FUNNEL = 2; + */ + TRENDED_FUNNEL(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unspecified type.
+     * 
+ * + * FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; + */ + public static final int FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * A standard (stepped) funnel. The funnel visualization sub report in the
+     * response will not contain date.
+     * 
+ * + * STANDARD_FUNNEL = 1; + */ + public static final int STANDARD_FUNNEL_VALUE = 1; + /** + * + * + *
+     * A trended (line chart) funnel. The funnel visualization sub report in the
+     * response will contain the date dimension.
+     * 
+ * + * TRENDED_FUNNEL = 2; + */ + public static final int TRENDED_FUNNEL_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 FunnelVisualizationType 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 FunnelVisualizationType forNumber(int value) { + switch (value) { + case 0: + return FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED; + case 1: + return STANDARD_FUNNEL; + case 2: + return TRENDED_FUNNEL; + 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 FunnelVisualizationType findValueByNumber(int number) { + return FunnelVisualizationType.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.RunFunnelReportRequest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final FunnelVisualizationType[] VALUES = values(); + + public static FunnelVisualizationType 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 FunnelVisualizationType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType) + } + + public static final int PROPERTY_FIELD_NUMBER = 1; + private volatile java.lang.Object property_; + /** + * + * + *
+   * A Google Analytics GA4 property identifier whose events are tracked.
+   * Specified in the URL path and not the body. To learn more, see [where to
+   * find your Property
+   * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+   * Within a batch request, this property should either be unspecified or
+   * consistent with the batch-level property.
+   * Example: properties/1234
+   * 
+ * + * string property = 1; + * + * @return The property. + */ + @java.lang.Override + public java.lang.String getProperty() { + java.lang.Object ref = property_; + 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(); + property_ = s; + return s; + } + } + /** + * + * + *
+   * A Google Analytics GA4 property identifier whose events are tracked.
+   * Specified in the URL path and not the body. To learn more, see [where to
+   * find your Property
+   * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+   * Within a batch request, this property should either be unspecified or
+   * consistent with the batch-level property.
+   * Example: properties/1234
+   * 
+ * + * string property = 1; + * + * @return The bytes for property. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPropertyBytes() { + java.lang.Object ref = property_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + property_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DATE_RANGES_FIELD_NUMBER = 2; + private java.util.List dateRanges_; + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + @java.lang.Override + public java.util.List getDateRangesList() { + return dateRanges_; + } + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + @java.lang.Override + public java.util.List + getDateRangesOrBuilderList() { + return dateRanges_; + } + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + @java.lang.Override + public int getDateRangesCount() { + return dateRanges_.size(); + } + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DateRange getDateRanges(int index) { + return dateRanges_.get(index); + } + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.DateRangeOrBuilder getDateRangesOrBuilder(int index) { + return dateRanges_.get(index); + } + + public static final int FUNNEL_FIELD_NUMBER = 3; + private com.google.analytics.data.v1alpha.Funnel funnel_; + /** + * + * + *
+   * The configuration of this request's funnel. This funnel configuration is
+   * required.
+   * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + * + * @return Whether the funnel field is set. + */ + @java.lang.Override + public boolean hasFunnel() { + return funnel_ != null; + } + /** + * + * + *
+   * The configuration of this request's funnel. This funnel configuration is
+   * required.
+   * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + * + * @return The funnel. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Funnel getFunnel() { + return funnel_ == null + ? com.google.analytics.data.v1alpha.Funnel.getDefaultInstance() + : funnel_; + } + /** + * + * + *
+   * The configuration of this request's funnel. This funnel configuration is
+   * required.
+   * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelOrBuilder getFunnelOrBuilder() { + return getFunnel(); + } + + public static final int FUNNEL_BREAKDOWN_FIELD_NUMBER = 4; + private com.google.analytics.data.v1alpha.FunnelBreakdown funnelBreakdown_; + /** + * + * + *
+   * If specified, this breakdown adds a dimension to the funnel table sub
+   * report response. This breakdown dimension expands each funnel step to the
+   * unique values of the breakdown dimension. For example, a breakdown by the
+   * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+   * `desktop`, and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + * + * @return Whether the funnelBreakdown field is set. + */ + @java.lang.Override + public boolean hasFunnelBreakdown() { + return funnelBreakdown_ != null; + } + /** + * + * + *
+   * If specified, this breakdown adds a dimension to the funnel table sub
+   * report response. This breakdown dimension expands each funnel step to the
+   * unique values of the breakdown dimension. For example, a breakdown by the
+   * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+   * `desktop`, and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + * + * @return The funnelBreakdown. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelBreakdown getFunnelBreakdown() { + return funnelBreakdown_ == null + ? com.google.analytics.data.v1alpha.FunnelBreakdown.getDefaultInstance() + : funnelBreakdown_; + } + /** + * + * + *
+   * If specified, this breakdown adds a dimension to the funnel table sub
+   * report response. This breakdown dimension expands each funnel step to the
+   * unique values of the breakdown dimension. For example, a breakdown by the
+   * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+   * `desktop`, and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder getFunnelBreakdownOrBuilder() { + return getFunnelBreakdown(); + } + + public static final int FUNNEL_NEXT_ACTION_FIELD_NUMBER = 5; + private com.google.analytics.data.v1alpha.FunnelNextAction funnelNextAction_; + /** + * + * + *
+   * If specified, next action adds a dimension to the funnel visualization sub
+   * report response. This next action dimension expands each funnel step to the
+   * unique values of the next action. For example a breakdown by the
+   * `eventName` dimension will create rows for several events (i.e.
+   * `session_start` & `click`) and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + * + * @return Whether the funnelNextAction field is set. + */ + @java.lang.Override + public boolean hasFunnelNextAction() { + return funnelNextAction_ != null; + } + /** + * + * + *
+   * If specified, next action adds a dimension to the funnel visualization sub
+   * report response. This next action dimension expands each funnel step to the
+   * unique values of the next action. For example a breakdown by the
+   * `eventName` dimension will create rows for several events (i.e.
+   * `session_start` & `click`) and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + * + * @return The funnelNextAction. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelNextAction getFunnelNextAction() { + return funnelNextAction_ == null + ? com.google.analytics.data.v1alpha.FunnelNextAction.getDefaultInstance() + : funnelNextAction_; + } + /** + * + * + *
+   * If specified, next action adds a dimension to the funnel visualization sub
+   * report response. This next action dimension expands each funnel step to the
+   * unique values of the next action. For example a breakdown by the
+   * `eventName` dimension will create rows for several events (i.e.
+   * `session_start` & `click`) and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder + getFunnelNextActionOrBuilder() { + return getFunnelNextAction(); + } + + public static final int FUNNEL_VISUALIZATION_TYPE_FIELD_NUMBER = 6; + private int funnelVisualizationType_; + /** + * + * + *
+   * The funnel visualization type controls the dimensions present in the funnel
+   * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+   * used.
+   * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return The enum numeric value on the wire for funnelVisualizationType. + */ + @java.lang.Override + public int getFunnelVisualizationTypeValue() { + return funnelVisualizationType_; + } + /** + * + * + *
+   * The funnel visualization type controls the dimensions present in the funnel
+   * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+   * used.
+   * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return The funnelVisualizationType. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + getFunnelVisualizationType() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType result = + com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType.valueOf( + funnelVisualizationType_); + return result == null + ? com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + .UNRECOGNIZED + : result; + } + + public static final int SEGMENTS_FIELD_NUMBER = 7; + private java.util.List segments_; + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + @java.lang.Override + public java.util.List getSegmentsList() { + return segments_; + } + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + @java.lang.Override + public java.util.List + getSegmentsOrBuilderList() { + return segments_; + } + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + @java.lang.Override + public int getSegmentsCount() { + return segments_.size(); + } + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.Segment getSegments(int index) { + return segments_.get(index); + } + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentOrBuilder getSegmentsOrBuilder(int index) { + return segments_.get(index); + } + + public static final int LIMIT_FIELD_NUMBER = 9; + private long limit_; + /** + * + * + *
+   * The number of rows to return. If unspecified, 10,000 rows are returned. The
+   * API returns a maximum of 100,000 rows per request, no matter how many you
+   * ask for. `limit` must be positive.
+   * The API can also return fewer rows than the requested `limit`, if there
+   * aren't as many dimension values as the `limit`.
+   * 
+ * + * int64 limit = 9; + * + * @return The limit. + */ + @java.lang.Override + public long getLimit() { + return limit_; + } + + public static final int DIMENSION_FILTER_FIELD_NUMBER = 10; + private com.google.analytics.data.v1alpha.FilterExpression dimensionFilter_; + /** + * + * + *
+   * Dimension filters allow you to ask for only specific dimension values in
+   * the report. To learn more, see [Creating a Report: Dimension
+   * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+   * for examples. Metrics cannot be used in this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + * + * @return Whether the dimensionFilter field is set. + */ + @java.lang.Override + public boolean hasDimensionFilter() { + return dimensionFilter_ != null; + } + /** + * + * + *
+   * Dimension filters allow you to ask for only specific dimension values in
+   * the report. To learn more, see [Creating a Report: Dimension
+   * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+   * for examples. Metrics cannot be used in this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + * + * @return The dimensionFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpression getDimensionFilter() { + return dimensionFilter_ == null + ? com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance() + : dimensionFilter_; + } + /** + * + * + *
+   * Dimension filters allow you to ask for only specific dimension values in
+   * the report. To learn more, see [Creating a Report: Dimension
+   * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+   * for examples. Metrics cannot be used in this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getDimensionFilterOrBuilder() { + return getDimensionFilter(); + } + + public static final int RETURN_PROPERTY_QUOTA_FIELD_NUMBER = 12; + private boolean returnPropertyQuota_; + /** + * + * + *
+   * Toggles whether to return the current state of this Analytics Property's
+   * quota. Quota is returned in [PropertyQuota](#PropertyQuota).
+   * 
+ * + * bool return_property_quota = 12; + * + * @return The returnPropertyQuota. + */ + @java.lang.Override + public boolean getReturnPropertyQuota() { + return returnPropertyQuota_; + } + + 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.GeneratedMessageV3.isStringEmpty(property_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, property_); + } + for (int i = 0; i < dateRanges_.size(); i++) { + output.writeMessage(2, dateRanges_.get(i)); + } + if (funnel_ != null) { + output.writeMessage(3, getFunnel()); + } + if (funnelBreakdown_ != null) { + output.writeMessage(4, getFunnelBreakdown()); + } + if (funnelNextAction_ != null) { + output.writeMessage(5, getFunnelNextAction()); + } + if (funnelVisualizationType_ + != com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + .FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(6, funnelVisualizationType_); + } + for (int i = 0; i < segments_.size(); i++) { + output.writeMessage(7, segments_.get(i)); + } + if (limit_ != 0L) { + output.writeInt64(9, limit_); + } + if (dimensionFilter_ != null) { + output.writeMessage(10, getDimensionFilter()); + } + if (returnPropertyQuota_ != false) { + output.writeBool(12, returnPropertyQuota_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(property_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, property_); + } + for (int i = 0; i < dateRanges_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, dateRanges_.get(i)); + } + if (funnel_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFunnel()); + } + if (funnelBreakdown_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getFunnelBreakdown()); + } + if (funnelNextAction_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getFunnelNextAction()); + } + if (funnelVisualizationType_ + != com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + .FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(6, funnelVisualizationType_); + } + for (int i = 0; i < segments_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, segments_.get(i)); + } + if (limit_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(9, limit_); + } + if (dimensionFilter_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getDimensionFilter()); + } + if (returnPropertyQuota_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(12, returnPropertyQuota_); + } + size += unknownFields.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.analytics.data.v1alpha.RunFunnelReportRequest)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.RunFunnelReportRequest other = + (com.google.analytics.data.v1alpha.RunFunnelReportRequest) obj; + + if (!getProperty().equals(other.getProperty())) return false; + if (!getDateRangesList().equals(other.getDateRangesList())) return false; + if (hasFunnel() != other.hasFunnel()) return false; + if (hasFunnel()) { + if (!getFunnel().equals(other.getFunnel())) return false; + } + if (hasFunnelBreakdown() != other.hasFunnelBreakdown()) return false; + if (hasFunnelBreakdown()) { + if (!getFunnelBreakdown().equals(other.getFunnelBreakdown())) return false; + } + if (hasFunnelNextAction() != other.hasFunnelNextAction()) return false; + if (hasFunnelNextAction()) { + if (!getFunnelNextAction().equals(other.getFunnelNextAction())) return false; + } + if (funnelVisualizationType_ != other.funnelVisualizationType_) return false; + if (!getSegmentsList().equals(other.getSegmentsList())) return false; + if (getLimit() != other.getLimit()) return false; + if (hasDimensionFilter() != other.hasDimensionFilter()) return false; + if (hasDimensionFilter()) { + if (!getDimensionFilter().equals(other.getDimensionFilter())) return false; + } + if (getReturnPropertyQuota() != other.getReturnPropertyQuota()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + PROPERTY_FIELD_NUMBER; + hash = (53 * hash) + getProperty().hashCode(); + if (getDateRangesCount() > 0) { + hash = (37 * hash) + DATE_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getDateRangesList().hashCode(); + } + if (hasFunnel()) { + hash = (37 * hash) + FUNNEL_FIELD_NUMBER; + hash = (53 * hash) + getFunnel().hashCode(); + } + if (hasFunnelBreakdown()) { + hash = (37 * hash) + FUNNEL_BREAKDOWN_FIELD_NUMBER; + hash = (53 * hash) + getFunnelBreakdown().hashCode(); + } + if (hasFunnelNextAction()) { + hash = (37 * hash) + FUNNEL_NEXT_ACTION_FIELD_NUMBER; + hash = (53 * hash) + getFunnelNextAction().hashCode(); + } + hash = (37 * hash) + FUNNEL_VISUALIZATION_TYPE_FIELD_NUMBER; + hash = (53 * hash) + funnelVisualizationType_; + if (getSegmentsCount() > 0) { + hash = (37 * hash) + SEGMENTS_FIELD_NUMBER; + hash = (53 * hash) + getSegmentsList().hashCode(); + } + hash = (37 * hash) + LIMIT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getLimit()); + if (hasDimensionFilter()) { + hash = (37 * hash) + DIMENSION_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getDimensionFilter().hashCode(); + } + hash = (37 * hash) + RETURN_PROPERTY_QUOTA_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getReturnPropertyQuota()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest 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.analytics.data.v1alpha.RunFunnelReportRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.RunFunnelReportRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request for a funnel report.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.RunFunnelReportRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.RunFunnelReportRequest) + com.google.analytics.data.v1alpha.RunFunnelReportRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.RunFunnelReportRequest.class, + com.google.analytics.data.v1alpha.RunFunnelReportRequest.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.RunFunnelReportRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getDateRangesFieldBuilder(); + getSegmentsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + property_ = ""; + + if (dateRangesBuilder_ == null) { + dateRanges_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + dateRangesBuilder_.clear(); + } + if (funnelBuilder_ == null) { + funnel_ = null; + } else { + funnel_ = null; + funnelBuilder_ = null; + } + if (funnelBreakdownBuilder_ == null) { + funnelBreakdown_ = null; + } else { + funnelBreakdown_ = null; + funnelBreakdownBuilder_ = null; + } + if (funnelNextActionBuilder_ == null) { + funnelNextAction_ = null; + } else { + funnelNextAction_ = null; + funnelNextActionBuilder_ = null; + } + funnelVisualizationType_ = 0; + + if (segmentsBuilder_ == null) { + segments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + segmentsBuilder_.clear(); + } + limit_ = 0L; + + if (dimensionFilterBuilder_ == null) { + dimensionFilter_ = null; + } else { + dimensionFilter_ = null; + dimensionFilterBuilder_ = null; + } + returnPropertyQuota_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportRequest_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportRequest getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.RunFunnelReportRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportRequest build() { + com.google.analytics.data.v1alpha.RunFunnelReportRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportRequest buildPartial() { + com.google.analytics.data.v1alpha.RunFunnelReportRequest result = + new com.google.analytics.data.v1alpha.RunFunnelReportRequest(this); + int from_bitField0_ = bitField0_; + result.property_ = property_; + if (dateRangesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + dateRanges_ = java.util.Collections.unmodifiableList(dateRanges_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.dateRanges_ = dateRanges_; + } else { + result.dateRanges_ = dateRangesBuilder_.build(); + } + if (funnelBuilder_ == null) { + result.funnel_ = funnel_; + } else { + result.funnel_ = funnelBuilder_.build(); + } + if (funnelBreakdownBuilder_ == null) { + result.funnelBreakdown_ = funnelBreakdown_; + } else { + result.funnelBreakdown_ = funnelBreakdownBuilder_.build(); + } + if (funnelNextActionBuilder_ == null) { + result.funnelNextAction_ = funnelNextAction_; + } else { + result.funnelNextAction_ = funnelNextActionBuilder_.build(); + } + result.funnelVisualizationType_ = funnelVisualizationType_; + if (segmentsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + segments_ = java.util.Collections.unmodifiableList(segments_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.segments_ = segments_; + } else { + result.segments_ = segmentsBuilder_.build(); + } + result.limit_ = limit_; + if (dimensionFilterBuilder_ == null) { + result.dimensionFilter_ = dimensionFilter_; + } else { + result.dimensionFilter_ = dimensionFilterBuilder_.build(); + } + result.returnPropertyQuota_ = returnPropertyQuota_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.RunFunnelReportRequest) { + return mergeFrom((com.google.analytics.data.v1alpha.RunFunnelReportRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.RunFunnelReportRequest other) { + if (other == com.google.analytics.data.v1alpha.RunFunnelReportRequest.getDefaultInstance()) + return this; + if (!other.getProperty().isEmpty()) { + property_ = other.property_; + onChanged(); + } + if (dateRangesBuilder_ == null) { + if (!other.dateRanges_.isEmpty()) { + if (dateRanges_.isEmpty()) { + dateRanges_ = other.dateRanges_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureDateRangesIsMutable(); + dateRanges_.addAll(other.dateRanges_); + } + onChanged(); + } + } else { + if (!other.dateRanges_.isEmpty()) { + if (dateRangesBuilder_.isEmpty()) { + dateRangesBuilder_.dispose(); + dateRangesBuilder_ = null; + dateRanges_ = other.dateRanges_; + bitField0_ = (bitField0_ & ~0x00000001); + dateRangesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getDateRangesFieldBuilder() + : null; + } else { + dateRangesBuilder_.addAllMessages(other.dateRanges_); + } + } + } + if (other.hasFunnel()) { + mergeFunnel(other.getFunnel()); + } + if (other.hasFunnelBreakdown()) { + mergeFunnelBreakdown(other.getFunnelBreakdown()); + } + if (other.hasFunnelNextAction()) { + mergeFunnelNextAction(other.getFunnelNextAction()); + } + if (other.funnelVisualizationType_ != 0) { + setFunnelVisualizationTypeValue(other.getFunnelVisualizationTypeValue()); + } + if (segmentsBuilder_ == null) { + if (!other.segments_.isEmpty()) { + if (segments_.isEmpty()) { + segments_ = other.segments_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureSegmentsIsMutable(); + segments_.addAll(other.segments_); + } + onChanged(); + } + } else { + if (!other.segments_.isEmpty()) { + if (segmentsBuilder_.isEmpty()) { + segmentsBuilder_.dispose(); + segmentsBuilder_ = null; + segments_ = other.segments_; + bitField0_ = (bitField0_ & ~0x00000002); + segmentsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getSegmentsFieldBuilder() + : null; + } else { + segmentsBuilder_.addAllMessages(other.segments_); + } + } + } + if (other.getLimit() != 0L) { + setLimit(other.getLimit()); + } + if (other.hasDimensionFilter()) { + mergeDimensionFilter(other.getDimensionFilter()); + } + if (other.getReturnPropertyQuota() != false) { + setReturnPropertyQuota(other.getReturnPropertyQuota()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.RunFunnelReportRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.RunFunnelReportRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object property_ = ""; + /** + * + * + *
+     * A Google Analytics GA4 property identifier whose events are tracked.
+     * Specified in the URL path and not the body. To learn more, see [where to
+     * find your Property
+     * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+     * Within a batch request, this property should either be unspecified or
+     * consistent with the batch-level property.
+     * Example: properties/1234
+     * 
+ * + * string property = 1; + * + * @return The property. + */ + public java.lang.String getProperty() { + java.lang.Object ref = property_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + property_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * A Google Analytics GA4 property identifier whose events are tracked.
+     * Specified in the URL path and not the body. To learn more, see [where to
+     * find your Property
+     * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+     * Within a batch request, this property should either be unspecified or
+     * consistent with the batch-level property.
+     * Example: properties/1234
+     * 
+ * + * string property = 1; + * + * @return The bytes for property. + */ + public com.google.protobuf.ByteString getPropertyBytes() { + java.lang.Object ref = property_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + property_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * A Google Analytics GA4 property identifier whose events are tracked.
+     * Specified in the URL path and not the body. To learn more, see [where to
+     * find your Property
+     * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+     * Within a batch request, this property should either be unspecified or
+     * consistent with the batch-level property.
+     * Example: properties/1234
+     * 
+ * + * string property = 1; + * + * @param value The property to set. + * @return This builder for chaining. + */ + public Builder setProperty(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + property_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * A Google Analytics GA4 property identifier whose events are tracked.
+     * Specified in the URL path and not the body. To learn more, see [where to
+     * find your Property
+     * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+     * Within a batch request, this property should either be unspecified or
+     * consistent with the batch-level property.
+     * Example: properties/1234
+     * 
+ * + * string property = 1; + * + * @return This builder for chaining. + */ + public Builder clearProperty() { + + property_ = getDefaultInstance().getProperty(); + onChanged(); + return this; + } + /** + * + * + *
+     * A Google Analytics GA4 property identifier whose events are tracked.
+     * Specified in the URL path and not the body. To learn more, see [where to
+     * find your Property
+     * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+     * Within a batch request, this property should either be unspecified or
+     * consistent with the batch-level property.
+     * Example: properties/1234
+     * 
+ * + * string property = 1; + * + * @param value The bytes for property to set. + * @return This builder for chaining. + */ + public Builder setPropertyBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + property_ = value; + onChanged(); + return this; + } + + private java.util.List dateRanges_ = + java.util.Collections.emptyList(); + + private void ensureDateRangesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + dateRanges_ = + new java.util.ArrayList(dateRanges_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DateRange, + com.google.analytics.data.v1alpha.DateRange.Builder, + com.google.analytics.data.v1alpha.DateRangeOrBuilder> + dateRangesBuilder_; + + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public java.util.List getDateRangesList() { + if (dateRangesBuilder_ == null) { + return java.util.Collections.unmodifiableList(dateRanges_); + } else { + return dateRangesBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public int getDateRangesCount() { + if (dateRangesBuilder_ == null) { + return dateRanges_.size(); + } else { + return dateRangesBuilder_.getCount(); + } + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public com.google.analytics.data.v1alpha.DateRange getDateRanges(int index) { + if (dateRangesBuilder_ == null) { + return dateRanges_.get(index); + } else { + return dateRangesBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder setDateRanges(int index, com.google.analytics.data.v1alpha.DateRange value) { + if (dateRangesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDateRangesIsMutable(); + dateRanges_.set(index, value); + onChanged(); + } else { + dateRangesBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder setDateRanges( + int index, com.google.analytics.data.v1alpha.DateRange.Builder builderForValue) { + if (dateRangesBuilder_ == null) { + ensureDateRangesIsMutable(); + dateRanges_.set(index, builderForValue.build()); + onChanged(); + } else { + dateRangesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder addDateRanges(com.google.analytics.data.v1alpha.DateRange value) { + if (dateRangesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDateRangesIsMutable(); + dateRanges_.add(value); + onChanged(); + } else { + dateRangesBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder addDateRanges(int index, com.google.analytics.data.v1alpha.DateRange value) { + if (dateRangesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDateRangesIsMutable(); + dateRanges_.add(index, value); + onChanged(); + } else { + dateRangesBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder addDateRanges( + com.google.analytics.data.v1alpha.DateRange.Builder builderForValue) { + if (dateRangesBuilder_ == null) { + ensureDateRangesIsMutable(); + dateRanges_.add(builderForValue.build()); + onChanged(); + } else { + dateRangesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder addDateRanges( + int index, com.google.analytics.data.v1alpha.DateRange.Builder builderForValue) { + if (dateRangesBuilder_ == null) { + ensureDateRangesIsMutable(); + dateRanges_.add(index, builderForValue.build()); + onChanged(); + } else { + dateRangesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder addAllDateRanges( + java.lang.Iterable values) { + if (dateRangesBuilder_ == null) { + ensureDateRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, dateRanges_); + onChanged(); + } else { + dateRangesBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder clearDateRanges() { + if (dateRangesBuilder_ == null) { + dateRanges_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + dateRangesBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public Builder removeDateRanges(int index) { + if (dateRangesBuilder_ == null) { + ensureDateRangesIsMutable(); + dateRanges_.remove(index); + onChanged(); + } else { + dateRangesBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public com.google.analytics.data.v1alpha.DateRange.Builder getDateRangesBuilder(int index) { + return getDateRangesFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public com.google.analytics.data.v1alpha.DateRangeOrBuilder getDateRangesOrBuilder(int index) { + if (dateRangesBuilder_ == null) { + return dateRanges_.get(index); + } else { + return dateRangesBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public java.util.List + getDateRangesOrBuilderList() { + if (dateRangesBuilder_ != null) { + return dateRangesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(dateRanges_); + } + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public com.google.analytics.data.v1alpha.DateRange.Builder addDateRangesBuilder() { + return getDateRangesFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.DateRange.getDefaultInstance()); + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public com.google.analytics.data.v1alpha.DateRange.Builder addDateRangesBuilder(int index) { + return getDateRangesFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.DateRange.getDefaultInstance()); + } + /** + * + * + *
+     * Date ranges of data to read. If multiple date ranges are requested, each
+     * response row will contain a zero based date range index. If two date
+     * ranges overlap, the event data for the overlapping days is included in the
+     * response rows for both date ranges.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + public java.util.List + getDateRangesBuilderList() { + return getDateRangesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DateRange, + com.google.analytics.data.v1alpha.DateRange.Builder, + com.google.analytics.data.v1alpha.DateRangeOrBuilder> + getDateRangesFieldBuilder() { + if (dateRangesBuilder_ == null) { + dateRangesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.DateRange, + com.google.analytics.data.v1alpha.DateRange.Builder, + com.google.analytics.data.v1alpha.DateRangeOrBuilder>( + dateRanges_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + dateRanges_ = null; + } + return dateRangesBuilder_; + } + + private com.google.analytics.data.v1alpha.Funnel funnel_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Funnel, + com.google.analytics.data.v1alpha.Funnel.Builder, + com.google.analytics.data.v1alpha.FunnelOrBuilder> + funnelBuilder_; + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + * + * @return Whether the funnel field is set. + */ + public boolean hasFunnel() { + return funnelBuilder_ != null || funnel_ != null; + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + * + * @return The funnel. + */ + public com.google.analytics.data.v1alpha.Funnel getFunnel() { + if (funnelBuilder_ == null) { + return funnel_ == null + ? com.google.analytics.data.v1alpha.Funnel.getDefaultInstance() + : funnel_; + } else { + return funnelBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + public Builder setFunnel(com.google.analytics.data.v1alpha.Funnel value) { + if (funnelBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + funnel_ = value; + onChanged(); + } else { + funnelBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + public Builder setFunnel(com.google.analytics.data.v1alpha.Funnel.Builder builderForValue) { + if (funnelBuilder_ == null) { + funnel_ = builderForValue.build(); + onChanged(); + } else { + funnelBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + public Builder mergeFunnel(com.google.analytics.data.v1alpha.Funnel value) { + if (funnelBuilder_ == null) { + if (funnel_ != null) { + funnel_ = + com.google.analytics.data.v1alpha.Funnel.newBuilder(funnel_) + .mergeFrom(value) + .buildPartial(); + } else { + funnel_ = value; + } + onChanged(); + } else { + funnelBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + public Builder clearFunnel() { + if (funnelBuilder_ == null) { + funnel_ = null; + onChanged(); + } else { + funnel_ = null; + funnelBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + public com.google.analytics.data.v1alpha.Funnel.Builder getFunnelBuilder() { + + onChanged(); + return getFunnelFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + public com.google.analytics.data.v1alpha.FunnelOrBuilder getFunnelOrBuilder() { + if (funnelBuilder_ != null) { + return funnelBuilder_.getMessageOrBuilder(); + } else { + return funnel_ == null + ? com.google.analytics.data.v1alpha.Funnel.getDefaultInstance() + : funnel_; + } + } + /** + * + * + *
+     * The configuration of this request's funnel. This funnel configuration is
+     * required.
+     * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Funnel, + com.google.analytics.data.v1alpha.Funnel.Builder, + com.google.analytics.data.v1alpha.FunnelOrBuilder> + getFunnelFieldBuilder() { + if (funnelBuilder_ == null) { + funnelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.Funnel, + com.google.analytics.data.v1alpha.Funnel.Builder, + com.google.analytics.data.v1alpha.FunnelOrBuilder>( + getFunnel(), getParentForChildren(), isClean()); + funnel_ = null; + } + return funnelBuilder_; + } + + private com.google.analytics.data.v1alpha.FunnelBreakdown funnelBreakdown_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelBreakdown, + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder, + com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder> + funnelBreakdownBuilder_; + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + * + * @return Whether the funnelBreakdown field is set. + */ + public boolean hasFunnelBreakdown() { + return funnelBreakdownBuilder_ != null || funnelBreakdown_ != null; + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + * + * @return The funnelBreakdown. + */ + public com.google.analytics.data.v1alpha.FunnelBreakdown getFunnelBreakdown() { + if (funnelBreakdownBuilder_ == null) { + return funnelBreakdown_ == null + ? com.google.analytics.data.v1alpha.FunnelBreakdown.getDefaultInstance() + : funnelBreakdown_; + } else { + return funnelBreakdownBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + public Builder setFunnelBreakdown(com.google.analytics.data.v1alpha.FunnelBreakdown value) { + if (funnelBreakdownBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + funnelBreakdown_ = value; + onChanged(); + } else { + funnelBreakdownBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + public Builder setFunnelBreakdown( + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder builderForValue) { + if (funnelBreakdownBuilder_ == null) { + funnelBreakdown_ = builderForValue.build(); + onChanged(); + } else { + funnelBreakdownBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + public Builder mergeFunnelBreakdown(com.google.analytics.data.v1alpha.FunnelBreakdown value) { + if (funnelBreakdownBuilder_ == null) { + if (funnelBreakdown_ != null) { + funnelBreakdown_ = + com.google.analytics.data.v1alpha.FunnelBreakdown.newBuilder(funnelBreakdown_) + .mergeFrom(value) + .buildPartial(); + } else { + funnelBreakdown_ = value; + } + onChanged(); + } else { + funnelBreakdownBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + public Builder clearFunnelBreakdown() { + if (funnelBreakdownBuilder_ == null) { + funnelBreakdown_ = null; + onChanged(); + } else { + funnelBreakdown_ = null; + funnelBreakdownBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + public com.google.analytics.data.v1alpha.FunnelBreakdown.Builder getFunnelBreakdownBuilder() { + + onChanged(); + return getFunnelBreakdownFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + public com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder + getFunnelBreakdownOrBuilder() { + if (funnelBreakdownBuilder_ != null) { + return funnelBreakdownBuilder_.getMessageOrBuilder(); + } else { + return funnelBreakdown_ == null + ? com.google.analytics.data.v1alpha.FunnelBreakdown.getDefaultInstance() + : funnelBreakdown_; + } + } + /** + * + * + *
+     * If specified, this breakdown adds a dimension to the funnel table sub
+     * report response. This breakdown dimension expands each funnel step to the
+     * unique values of the breakdown dimension. For example, a breakdown by the
+     * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+     * `desktop`, and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelBreakdown, + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder, + com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder> + getFunnelBreakdownFieldBuilder() { + if (funnelBreakdownBuilder_ == null) { + funnelBreakdownBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelBreakdown, + com.google.analytics.data.v1alpha.FunnelBreakdown.Builder, + com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder>( + getFunnelBreakdown(), getParentForChildren(), isClean()); + funnelBreakdown_ = null; + } + return funnelBreakdownBuilder_; + } + + private com.google.analytics.data.v1alpha.FunnelNextAction funnelNextAction_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelNextAction, + com.google.analytics.data.v1alpha.FunnelNextAction.Builder, + com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder> + funnelNextActionBuilder_; + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + * + * @return Whether the funnelNextAction field is set. + */ + public boolean hasFunnelNextAction() { + return funnelNextActionBuilder_ != null || funnelNextAction_ != null; + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + * + * @return The funnelNextAction. + */ + public com.google.analytics.data.v1alpha.FunnelNextAction getFunnelNextAction() { + if (funnelNextActionBuilder_ == null) { + return funnelNextAction_ == null + ? com.google.analytics.data.v1alpha.FunnelNextAction.getDefaultInstance() + : funnelNextAction_; + } else { + return funnelNextActionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + public Builder setFunnelNextAction(com.google.analytics.data.v1alpha.FunnelNextAction value) { + if (funnelNextActionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + funnelNextAction_ = value; + onChanged(); + } else { + funnelNextActionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + public Builder setFunnelNextAction( + com.google.analytics.data.v1alpha.FunnelNextAction.Builder builderForValue) { + if (funnelNextActionBuilder_ == null) { + funnelNextAction_ = builderForValue.build(); + onChanged(); + } else { + funnelNextActionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + public Builder mergeFunnelNextAction(com.google.analytics.data.v1alpha.FunnelNextAction value) { + if (funnelNextActionBuilder_ == null) { + if (funnelNextAction_ != null) { + funnelNextAction_ = + com.google.analytics.data.v1alpha.FunnelNextAction.newBuilder(funnelNextAction_) + .mergeFrom(value) + .buildPartial(); + } else { + funnelNextAction_ = value; + } + onChanged(); + } else { + funnelNextActionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + public Builder clearFunnelNextAction() { + if (funnelNextActionBuilder_ == null) { + funnelNextAction_ = null; + onChanged(); + } else { + funnelNextAction_ = null; + funnelNextActionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + public com.google.analytics.data.v1alpha.FunnelNextAction.Builder getFunnelNextActionBuilder() { + + onChanged(); + return getFunnelNextActionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + public com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder + getFunnelNextActionOrBuilder() { + if (funnelNextActionBuilder_ != null) { + return funnelNextActionBuilder_.getMessageOrBuilder(); + } else { + return funnelNextAction_ == null + ? com.google.analytics.data.v1alpha.FunnelNextAction.getDefaultInstance() + : funnelNextAction_; + } + } + /** + * + * + *
+     * If specified, next action adds a dimension to the funnel visualization sub
+     * report response. This next action dimension expands each funnel step to the
+     * unique values of the next action. For example a breakdown by the
+     * `eventName` dimension will create rows for several events (i.e.
+     * `session_start` & `click`) and the total.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelNextAction, + com.google.analytics.data.v1alpha.FunnelNextAction.Builder, + com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder> + getFunnelNextActionFieldBuilder() { + if (funnelNextActionBuilder_ == null) { + funnelNextActionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelNextAction, + com.google.analytics.data.v1alpha.FunnelNextAction.Builder, + com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder>( + getFunnelNextAction(), getParentForChildren(), isClean()); + funnelNextAction_ = null; + } + return funnelNextActionBuilder_; + } + + private int funnelVisualizationType_ = 0; + /** + * + * + *
+     * The funnel visualization type controls the dimensions present in the funnel
+     * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+     * used.
+     * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return The enum numeric value on the wire for funnelVisualizationType. + */ + @java.lang.Override + public int getFunnelVisualizationTypeValue() { + return funnelVisualizationType_; + } + /** + * + * + *
+     * The funnel visualization type controls the dimensions present in the funnel
+     * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+     * used.
+     * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @param value The enum numeric value on the wire for funnelVisualizationType to set. + * @return This builder for chaining. + */ + public Builder setFunnelVisualizationTypeValue(int value) { + + funnelVisualizationType_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The funnel visualization type controls the dimensions present in the funnel
+     * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+     * used.
+     * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return The funnelVisualizationType. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + getFunnelVisualizationType() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType result = + com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType.valueOf( + funnelVisualizationType_); + return result == null + ? com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + .UNRECOGNIZED + : result; + } + /** + * + * + *
+     * The funnel visualization type controls the dimensions present in the funnel
+     * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+     * used.
+     * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @param value The funnelVisualizationType to set. + * @return This builder for chaining. + */ + public Builder setFunnelVisualizationType( + com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType value) { + if (value == null) { + throw new NullPointerException(); + } + + funnelVisualizationType_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The funnel visualization type controls the dimensions present in the funnel
+     * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+     * used.
+     * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return This builder for chaining. + */ + public Builder clearFunnelVisualizationType() { + + funnelVisualizationType_ = 0; + onChanged(); + return this; + } + + private java.util.List segments_ = + java.util.Collections.emptyList(); + + private void ensureSegmentsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + segments_ = new java.util.ArrayList(segments_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.Segment, + com.google.analytics.data.v1alpha.Segment.Builder, + com.google.analytics.data.v1alpha.SegmentOrBuilder> + segmentsBuilder_; + + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public java.util.List getSegmentsList() { + if (segmentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(segments_); + } else { + return segmentsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public int getSegmentsCount() { + if (segmentsBuilder_ == null) { + return segments_.size(); + } else { + return segmentsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public com.google.analytics.data.v1alpha.Segment getSegments(int index) { + if (segmentsBuilder_ == null) { + return segments_.get(index); + } else { + return segmentsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder setSegments(int index, com.google.analytics.data.v1alpha.Segment value) { + if (segmentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSegmentsIsMutable(); + segments_.set(index, value); + onChanged(); + } else { + segmentsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder setSegments( + int index, com.google.analytics.data.v1alpha.Segment.Builder builderForValue) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.set(index, builderForValue.build()); + onChanged(); + } else { + segmentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder addSegments(com.google.analytics.data.v1alpha.Segment value) { + if (segmentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSegmentsIsMutable(); + segments_.add(value); + onChanged(); + } else { + segmentsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder addSegments(int index, com.google.analytics.data.v1alpha.Segment value) { + if (segmentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSegmentsIsMutable(); + segments_.add(index, value); + onChanged(); + } else { + segmentsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder addSegments(com.google.analytics.data.v1alpha.Segment.Builder builderForValue) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.add(builderForValue.build()); + onChanged(); + } else { + segmentsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder addSegments( + int index, com.google.analytics.data.v1alpha.Segment.Builder builderForValue) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.add(index, builderForValue.build()); + onChanged(); + } else { + segmentsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder addAllSegments( + java.lang.Iterable values) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, segments_); + onChanged(); + } else { + segmentsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder clearSegments() { + if (segmentsBuilder_ == null) { + segments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + segmentsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public Builder removeSegments(int index) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.remove(index); + onChanged(); + } else { + segmentsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public com.google.analytics.data.v1alpha.Segment.Builder getSegmentsBuilder(int index) { + return getSegmentsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public com.google.analytics.data.v1alpha.SegmentOrBuilder getSegmentsOrBuilder(int index) { + if (segmentsBuilder_ == null) { + return segments_.get(index); + } else { + return segmentsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public java.util.List + getSegmentsOrBuilderList() { + if (segmentsBuilder_ != null) { + return segmentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(segments_); + } + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public com.google.analytics.data.v1alpha.Segment.Builder addSegmentsBuilder() { + return getSegmentsFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.Segment.getDefaultInstance()); + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public com.google.analytics.data.v1alpha.Segment.Builder addSegmentsBuilder(int index) { + return getSegmentsFieldBuilder() + .addBuilder(index, com.google.analytics.data.v1alpha.Segment.getDefaultInstance()); + } + /** + * + * + *
+     * The configurations of segments. Segments are subsets of a property's data.
+     * In a funnel report with segments, the funnel is evaluated in each segment.
+     * Each segment specified in this request
+     * produces a separate row in the response; in the response, each segment
+     * identified by its name.
+     * The segments parameter is optional. Requests are limited to 4 segments.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + public java.util.List + getSegmentsBuilderList() { + return getSegmentsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.Segment, + com.google.analytics.data.v1alpha.Segment.Builder, + com.google.analytics.data.v1alpha.SegmentOrBuilder> + getSegmentsFieldBuilder() { + if (segmentsBuilder_ == null) { + segmentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.Segment, + com.google.analytics.data.v1alpha.Segment.Builder, + com.google.analytics.data.v1alpha.SegmentOrBuilder>( + segments_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + segments_ = null; + } + return segmentsBuilder_; + } + + private long limit_; + /** + * + * + *
+     * The number of rows to return. If unspecified, 10,000 rows are returned. The
+     * API returns a maximum of 100,000 rows per request, no matter how many you
+     * ask for. `limit` must be positive.
+     * The API can also return fewer rows than the requested `limit`, if there
+     * aren't as many dimension values as the `limit`.
+     * 
+ * + * int64 limit = 9; + * + * @return The limit. + */ + @java.lang.Override + public long getLimit() { + return limit_; + } + /** + * + * + *
+     * The number of rows to return. If unspecified, 10,000 rows are returned. The
+     * API returns a maximum of 100,000 rows per request, no matter how many you
+     * ask for. `limit` must be positive.
+     * The API can also return fewer rows than the requested `limit`, if there
+     * aren't as many dimension values as the `limit`.
+     * 
+ * + * int64 limit = 9; + * + * @param value The limit to set. + * @return This builder for chaining. + */ + public Builder setLimit(long value) { + + limit_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The number of rows to return. If unspecified, 10,000 rows are returned. The
+     * API returns a maximum of 100,000 rows per request, no matter how many you
+     * ask for. `limit` must be positive.
+     * The API can also return fewer rows than the requested `limit`, if there
+     * aren't as many dimension values as the `limit`.
+     * 
+ * + * int64 limit = 9; + * + * @return This builder for chaining. + */ + public Builder clearLimit() { + + limit_ = 0L; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.FilterExpression dimensionFilter_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder> + dimensionFilterBuilder_; + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + * + * @return Whether the dimensionFilter field is set. + */ + public boolean hasDimensionFilter() { + return dimensionFilterBuilder_ != null || dimensionFilter_ != null; + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + * + * @return The dimensionFilter. + */ + public com.google.analytics.data.v1alpha.FilterExpression getDimensionFilter() { + if (dimensionFilterBuilder_ == null) { + return dimensionFilter_ == null + ? com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance() + : dimensionFilter_; + } else { + return dimensionFilterBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + public Builder setDimensionFilter(com.google.analytics.data.v1alpha.FilterExpression value) { + if (dimensionFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + dimensionFilter_ = value; + onChanged(); + } else { + dimensionFilterBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + public Builder setDimensionFilter( + com.google.analytics.data.v1alpha.FilterExpression.Builder builderForValue) { + if (dimensionFilterBuilder_ == null) { + dimensionFilter_ = builderForValue.build(); + onChanged(); + } else { + dimensionFilterBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + public Builder mergeDimensionFilter(com.google.analytics.data.v1alpha.FilterExpression value) { + if (dimensionFilterBuilder_ == null) { + if (dimensionFilter_ != null) { + dimensionFilter_ = + com.google.analytics.data.v1alpha.FilterExpression.newBuilder(dimensionFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + dimensionFilter_ = value; + } + onChanged(); + } else { + dimensionFilterBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + public Builder clearDimensionFilter() { + if (dimensionFilterBuilder_ == null) { + dimensionFilter_ = null; + onChanged(); + } else { + dimensionFilter_ = null; + dimensionFilterBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + public com.google.analytics.data.v1alpha.FilterExpression.Builder getDimensionFilterBuilder() { + + onChanged(); + return getDimensionFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + public com.google.analytics.data.v1alpha.FilterExpressionOrBuilder + getDimensionFilterOrBuilder() { + if (dimensionFilterBuilder_ != null) { + return dimensionFilterBuilder_.getMessageOrBuilder(); + } else { + return dimensionFilter_ == null + ? com.google.analytics.data.v1alpha.FilterExpression.getDefaultInstance() + : dimensionFilter_; + } + } + /** + * + * + *
+     * Dimension filters allow you to ask for only specific dimension values in
+     * the report. To learn more, see [Creating a Report: Dimension
+     * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+     * for examples. Metrics cannot be used in this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder> + getDimensionFilterFieldBuilder() { + if (dimensionFilterBuilder_ == null) { + dimensionFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FilterExpression, + com.google.analytics.data.v1alpha.FilterExpression.Builder, + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder>( + getDimensionFilter(), getParentForChildren(), isClean()); + dimensionFilter_ = null; + } + return dimensionFilterBuilder_; + } + + private boolean returnPropertyQuota_; + /** + * + * + *
+     * Toggles whether to return the current state of this Analytics Property's
+     * quota. Quota is returned in [PropertyQuota](#PropertyQuota).
+     * 
+ * + * bool return_property_quota = 12; + * + * @return The returnPropertyQuota. + */ + @java.lang.Override + public boolean getReturnPropertyQuota() { + return returnPropertyQuota_; + } + /** + * + * + *
+     * Toggles whether to return the current state of this Analytics Property's
+     * quota. Quota is returned in [PropertyQuota](#PropertyQuota).
+     * 
+ * + * bool return_property_quota = 12; + * + * @param value The returnPropertyQuota to set. + * @return This builder for chaining. + */ + public Builder setReturnPropertyQuota(boolean value) { + + returnPropertyQuota_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Toggles whether to return the current state of this Analytics Property's
+     * quota. Quota is returned in [PropertyQuota](#PropertyQuota).
+     * 
+ * + * bool return_property_quota = 12; + * + * @return This builder for chaining. + */ + public Builder clearReturnPropertyQuota() { + + returnPropertyQuota_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.RunFunnelReportRequest) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.RunFunnelReportRequest) + private static final com.google.analytics.data.v1alpha.RunFunnelReportRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.RunFunnelReportRequest(); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RunFunnelReportRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new RunFunnelReportRequest(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.RunFunnelReportRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequestOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequestOrBuilder.java new file mode 100644 index 00000000..8bdda226 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportRequestOrBuilder.java @@ -0,0 +1,447 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/analytics_data_api.proto + +package com.google.analytics.data.v1alpha; + +public interface RunFunnelReportRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.RunFunnelReportRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A Google Analytics GA4 property identifier whose events are tracked.
+   * Specified in the URL path and not the body. To learn more, see [where to
+   * find your Property
+   * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+   * Within a batch request, this property should either be unspecified or
+   * consistent with the batch-level property.
+   * Example: properties/1234
+   * 
+ * + * string property = 1; + * + * @return The property. + */ + java.lang.String getProperty(); + /** + * + * + *
+   * A Google Analytics GA4 property identifier whose events are tracked.
+   * Specified in the URL path and not the body. To learn more, see [where to
+   * find your Property
+   * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id).
+   * Within a batch request, this property should either be unspecified or
+   * consistent with the batch-level property.
+   * Example: properties/1234
+   * 
+ * + * string property = 1; + * + * @return The bytes for property. + */ + com.google.protobuf.ByteString getPropertyBytes(); + + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + java.util.List getDateRangesList(); + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + com.google.analytics.data.v1alpha.DateRange getDateRanges(int index); + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + int getDateRangesCount(); + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + java.util.List + getDateRangesOrBuilderList(); + /** + * + * + *
+   * Date ranges of data to read. If multiple date ranges are requested, each
+   * response row will contain a zero based date range index. If two date
+   * ranges overlap, the event data for the overlapping days is included in the
+   * response rows for both date ranges.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2; + */ + com.google.analytics.data.v1alpha.DateRangeOrBuilder getDateRangesOrBuilder(int index); + + /** + * + * + *
+   * The configuration of this request's funnel. This funnel configuration is
+   * required.
+   * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + * + * @return Whether the funnel field is set. + */ + boolean hasFunnel(); + /** + * + * + *
+   * The configuration of this request's funnel. This funnel configuration is
+   * required.
+   * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + * + * @return The funnel. + */ + com.google.analytics.data.v1alpha.Funnel getFunnel(); + /** + * + * + *
+   * The configuration of this request's funnel. This funnel configuration is
+   * required.
+   * 
+ * + * .google.analytics.data.v1alpha.Funnel funnel = 3; + */ + com.google.analytics.data.v1alpha.FunnelOrBuilder getFunnelOrBuilder(); + + /** + * + * + *
+   * If specified, this breakdown adds a dimension to the funnel table sub
+   * report response. This breakdown dimension expands each funnel step to the
+   * unique values of the breakdown dimension. For example, a breakdown by the
+   * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+   * `desktop`, and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + * + * @return Whether the funnelBreakdown field is set. + */ + boolean hasFunnelBreakdown(); + /** + * + * + *
+   * If specified, this breakdown adds a dimension to the funnel table sub
+   * report response. This breakdown dimension expands each funnel step to the
+   * unique values of the breakdown dimension. For example, a breakdown by the
+   * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+   * `desktop`, and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + * + * @return The funnelBreakdown. + */ + com.google.analytics.data.v1alpha.FunnelBreakdown getFunnelBreakdown(); + /** + * + * + *
+   * If specified, this breakdown adds a dimension to the funnel table sub
+   * report response. This breakdown dimension expands each funnel step to the
+   * unique values of the breakdown dimension. For example, a breakdown by the
+   * `deviceCategory` dimension will create rows for `mobile`, `tablet`,
+   * `desktop`, and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4; + */ + com.google.analytics.data.v1alpha.FunnelBreakdownOrBuilder getFunnelBreakdownOrBuilder(); + + /** + * + * + *
+   * If specified, next action adds a dimension to the funnel visualization sub
+   * report response. This next action dimension expands each funnel step to the
+   * unique values of the next action. For example a breakdown by the
+   * `eventName` dimension will create rows for several events (i.e.
+   * `session_start` & `click`) and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + * + * @return Whether the funnelNextAction field is set. + */ + boolean hasFunnelNextAction(); + /** + * + * + *
+   * If specified, next action adds a dimension to the funnel visualization sub
+   * report response. This next action dimension expands each funnel step to the
+   * unique values of the next action. For example a breakdown by the
+   * `eventName` dimension will create rows for several events (i.e.
+   * `session_start` & `click`) and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + * + * @return The funnelNextAction. + */ + com.google.analytics.data.v1alpha.FunnelNextAction getFunnelNextAction(); + /** + * + * + *
+   * If specified, next action adds a dimension to the funnel visualization sub
+   * report response. This next action dimension expands each funnel step to the
+   * unique values of the next action. For example a breakdown by the
+   * `eventName` dimension will create rows for several events (i.e.
+   * `session_start` & `click`) and the total.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5; + */ + com.google.analytics.data.v1alpha.FunnelNextActionOrBuilder getFunnelNextActionOrBuilder(); + + /** + * + * + *
+   * The funnel visualization type controls the dimensions present in the funnel
+   * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+   * used.
+   * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return The enum numeric value on the wire for funnelVisualizationType. + */ + int getFunnelVisualizationTypeValue(); + /** + * + * + *
+   * The funnel visualization type controls the dimensions present in the funnel
+   * visualization sub report response. If not specified, `STANDARD_FUNNEL` is
+   * used.
+   * 
+ * + * + * .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6; + * + * + * @return The funnelVisualizationType. + */ + com.google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + getFunnelVisualizationType(); + + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + java.util.List getSegmentsList(); + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + com.google.analytics.data.v1alpha.Segment getSegments(int index); + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + int getSegmentsCount(); + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + java.util.List + getSegmentsOrBuilderList(); + /** + * + * + *
+   * The configurations of segments. Segments are subsets of a property's data.
+   * In a funnel report with segments, the funnel is evaluated in each segment.
+   * Each segment specified in this request
+   * produces a separate row in the response; in the response, each segment
+   * identified by its name.
+   * The segments parameter is optional. Requests are limited to 4 segments.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.Segment segments = 7; + */ + com.google.analytics.data.v1alpha.SegmentOrBuilder getSegmentsOrBuilder(int index); + + /** + * + * + *
+   * The number of rows to return. If unspecified, 10,000 rows are returned. The
+   * API returns a maximum of 100,000 rows per request, no matter how many you
+   * ask for. `limit` must be positive.
+   * The API can also return fewer rows than the requested `limit`, if there
+   * aren't as many dimension values as the `limit`.
+   * 
+ * + * int64 limit = 9; + * + * @return The limit. + */ + long getLimit(); + + /** + * + * + *
+   * Dimension filters allow you to ask for only specific dimension values in
+   * the report. To learn more, see [Creating a Report: Dimension
+   * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+   * for examples. Metrics cannot be used in this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + * + * @return Whether the dimensionFilter field is set. + */ + boolean hasDimensionFilter(); + /** + * + * + *
+   * Dimension filters allow you to ask for only specific dimension values in
+   * the report. To learn more, see [Creating a Report: Dimension
+   * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+   * for examples. Metrics cannot be used in this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + * + * @return The dimensionFilter. + */ + com.google.analytics.data.v1alpha.FilterExpression getDimensionFilter(); + /** + * + * + *
+   * Dimension filters allow you to ask for only specific dimension values in
+   * the report. To learn more, see [Creating a Report: Dimension
+   * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters)
+   * for examples. Metrics cannot be used in this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10; + */ + com.google.analytics.data.v1alpha.FilterExpressionOrBuilder getDimensionFilterOrBuilder(); + + /** + * + * + *
+   * Toggles whether to return the current state of this Analytics Property's
+   * quota. Quota is returned in [PropertyQuota](#PropertyQuota).
+   * 
+ * + * bool return_property_quota = 12; + * + * @return The returnPropertyQuota. + */ + boolean getReturnPropertyQuota(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponse.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponse.java new file mode 100644 index 00000000..226bd180 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponse.java @@ -0,0 +1,1615 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/analytics_data_api.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The funnel report response contains two sub reports. The two sub reports are
+ * different combinations of dimensions and metrics.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.RunFunnelReportResponse} + */ +public final class RunFunnelReportResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.RunFunnelReportResponse) + RunFunnelReportResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use RunFunnelReportResponse.newBuilder() to construct. + private RunFunnelReportResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RunFunnelReportResponse() { + kind_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RunFunnelReportResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private RunFunnelReportResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.FunnelSubReport.Builder subBuilder = null; + if (funnelTable_ != null) { + subBuilder = funnelTable_.toBuilder(); + } + funnelTable_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelSubReport.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(funnelTable_); + funnelTable_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.analytics.data.v1alpha.FunnelSubReport.Builder subBuilder = null; + if (funnelVisualization_ != null) { + subBuilder = funnelVisualization_.toBuilder(); + } + funnelVisualization_ = + input.readMessage( + com.google.analytics.data.v1alpha.FunnelSubReport.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(funnelVisualization_); + funnelVisualization_ = subBuilder.buildPartial(); + } + + break; + } + case 26: + { + com.google.analytics.data.v1alpha.PropertyQuota.Builder subBuilder = null; + if (propertyQuota_ != null) { + subBuilder = propertyQuota_.toBuilder(); + } + propertyQuota_ = + input.readMessage( + com.google.analytics.data.v1alpha.PropertyQuota.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(propertyQuota_); + propertyQuota_ = subBuilder.buildPartial(); + } + + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + kind_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.RunFunnelReportResponse.class, + com.google.analytics.data.v1alpha.RunFunnelReportResponse.Builder.class); + } + + public static final int FUNNEL_TABLE_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.FunnelSubReport funnelTable_; + /** + * + * + *
+   * The funnel table is a report with the funnel step, segment, breakdown
+   * dimension, active users, completion rate, abandonments, and abandonments
+   * rate.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The breakdown dimension is only present in this response if it
+   * was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * + * @return Whether the funnelTable field is set. + */ + @java.lang.Override + public boolean hasFunnelTable() { + return funnelTable_ != null; + } + /** + * + * + *
+   * The funnel table is a report with the funnel step, segment, breakdown
+   * dimension, active users, completion rate, abandonments, and abandonments
+   * rate.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The breakdown dimension is only present in this response if it
+   * was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * + * @return The funnelTable. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReport getFunnelTable() { + return funnelTable_ == null + ? com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance() + : funnelTable_; + } + /** + * + * + *
+   * The funnel table is a report with the funnel step, segment, breakdown
+   * dimension, active users, completion rate, abandonments, and abandonments
+   * rate.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The breakdown dimension is only present in this response if it
+   * was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder getFunnelTableOrBuilder() { + return getFunnelTable(); + } + + public static final int FUNNEL_VISUALIZATION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.FunnelSubReport funnelVisualization_; + /** + * + * + *
+   * The funnel visualization is a report with the funnel step, segment, date,
+   * next action dimension, and active users.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The date dimension is only present in this response if it was
+   * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+   * is only present in the response if it was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * + * @return Whether the funnelVisualization field is set. + */ + @java.lang.Override + public boolean hasFunnelVisualization() { + return funnelVisualization_ != null; + } + /** + * + * + *
+   * The funnel visualization is a report with the funnel step, segment, date,
+   * next action dimension, and active users.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The date dimension is only present in this response if it was
+   * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+   * is only present in the response if it was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * + * @return The funnelVisualization. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReport getFunnelVisualization() { + return funnelVisualization_ == null + ? com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance() + : funnelVisualization_; + } + /** + * + * + *
+   * The funnel visualization is a report with the funnel step, segment, date,
+   * next action dimension, and active users.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The date dimension is only present in this response if it was
+   * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+   * is only present in the response if it was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder + getFunnelVisualizationOrBuilder() { + return getFunnelVisualization(); + } + + public static final int PROPERTY_QUOTA_FIELD_NUMBER = 3; + private com.google.analytics.data.v1alpha.PropertyQuota propertyQuota_; + /** + * + * + *
+   * This Analytics Property's quota state including this request.
+   * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * + * @return Whether the propertyQuota field is set. + */ + @java.lang.Override + public boolean hasPropertyQuota() { + return propertyQuota_ != null; + } + /** + * + * + *
+   * This Analytics Property's quota state including this request.
+   * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * + * @return The propertyQuota. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.PropertyQuota getPropertyQuota() { + return propertyQuota_ == null + ? com.google.analytics.data.v1alpha.PropertyQuota.getDefaultInstance() + : propertyQuota_; + } + /** + * + * + *
+   * This Analytics Property's quota state including this request.
+   * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder getPropertyQuotaOrBuilder() { + return getPropertyQuota(); + } + + public static final int KIND_FIELD_NUMBER = 4; + private volatile java.lang.Object kind_; + /** + * + * + *
+   * Identifies what kind of resource this message is. This `kind` is always the
+   * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+   * response types in JSON.
+   * 
+ * + * string kind = 4; + * + * @return The kind. + */ + @java.lang.Override + public java.lang.String getKind() { + java.lang.Object ref = kind_; + 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(); + kind_ = s; + return s; + } + } + /** + * + * + *
+   * Identifies what kind of resource this message is. This `kind` is always the
+   * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+   * response types in JSON.
+   * 
+ * + * string kind = 4; + * + * @return The bytes for kind. + */ + @java.lang.Override + public com.google.protobuf.ByteString getKindBytes() { + java.lang.Object ref = kind_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + kind_ = 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 (funnelTable_ != null) { + output.writeMessage(1, getFunnelTable()); + } + if (funnelVisualization_ != null) { + output.writeMessage(2, getFunnelVisualization()); + } + if (propertyQuota_ != null) { + output.writeMessage(3, getPropertyQuota()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, kind_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (funnelTable_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getFunnelTable()); + } + if (funnelVisualization_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getFunnelVisualization()); + } + if (propertyQuota_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getPropertyQuota()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, kind_); + } + size += unknownFields.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.analytics.data.v1alpha.RunFunnelReportResponse)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.RunFunnelReportResponse other = + (com.google.analytics.data.v1alpha.RunFunnelReportResponse) obj; + + if (hasFunnelTable() != other.hasFunnelTable()) return false; + if (hasFunnelTable()) { + if (!getFunnelTable().equals(other.getFunnelTable())) return false; + } + if (hasFunnelVisualization() != other.hasFunnelVisualization()) return false; + if (hasFunnelVisualization()) { + if (!getFunnelVisualization().equals(other.getFunnelVisualization())) return false; + } + if (hasPropertyQuota() != other.hasPropertyQuota()) return false; + if (hasPropertyQuota()) { + if (!getPropertyQuota().equals(other.getPropertyQuota())) return false; + } + if (!getKind().equals(other.getKind())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasFunnelTable()) { + hash = (37 * hash) + FUNNEL_TABLE_FIELD_NUMBER; + hash = (53 * hash) + getFunnelTable().hashCode(); + } + if (hasFunnelVisualization()) { + hash = (37 * hash) + FUNNEL_VISUALIZATION_FIELD_NUMBER; + hash = (53 * hash) + getFunnelVisualization().hashCode(); + } + if (hasPropertyQuota()) { + hash = (37 * hash) + PROPERTY_QUOTA_FIELD_NUMBER; + hash = (53 * hash) + getPropertyQuota().hashCode(); + } + hash = (37 * hash) + KIND_FIELD_NUMBER; + hash = (53 * hash) + getKind().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse 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.analytics.data.v1alpha.RunFunnelReportResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.RunFunnelReportResponse 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The funnel report response contains two sub reports. The two sub reports are
+   * different combinations of dimensions and metrics.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.RunFunnelReportResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.RunFunnelReportResponse) + com.google.analytics.data.v1alpha.RunFunnelReportResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.RunFunnelReportResponse.class, + com.google.analytics.data.v1alpha.RunFunnelReportResponse.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.RunFunnelReportResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (funnelTableBuilder_ == null) { + funnelTable_ = null; + } else { + funnelTable_ = null; + funnelTableBuilder_ = null; + } + if (funnelVisualizationBuilder_ == null) { + funnelVisualization_ = null; + } else { + funnelVisualization_ = null; + funnelVisualizationBuilder_ = null; + } + if (propertyQuotaBuilder_ == null) { + propertyQuota_ = null; + } else { + propertyQuota_ = null; + propertyQuotaBuilder_ = null; + } + kind_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.AnalyticsDataApiProto + .internal_static_google_analytics_data_v1alpha_RunFunnelReportResponse_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportResponse getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.RunFunnelReportResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportResponse build() { + com.google.analytics.data.v1alpha.RunFunnelReportResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.RunFunnelReportResponse buildPartial() { + com.google.analytics.data.v1alpha.RunFunnelReportResponse result = + new com.google.analytics.data.v1alpha.RunFunnelReportResponse(this); + if (funnelTableBuilder_ == null) { + result.funnelTable_ = funnelTable_; + } else { + result.funnelTable_ = funnelTableBuilder_.build(); + } + if (funnelVisualizationBuilder_ == null) { + result.funnelVisualization_ = funnelVisualization_; + } else { + result.funnelVisualization_ = funnelVisualizationBuilder_.build(); + } + if (propertyQuotaBuilder_ == null) { + result.propertyQuota_ = propertyQuota_; + } else { + result.propertyQuota_ = propertyQuotaBuilder_.build(); + } + result.kind_ = kind_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.RunFunnelReportResponse) { + return mergeFrom((com.google.analytics.data.v1alpha.RunFunnelReportResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.RunFunnelReportResponse other) { + if (other == com.google.analytics.data.v1alpha.RunFunnelReportResponse.getDefaultInstance()) + return this; + if (other.hasFunnelTable()) { + mergeFunnelTable(other.getFunnelTable()); + } + if (other.hasFunnelVisualization()) { + mergeFunnelVisualization(other.getFunnelVisualization()); + } + if (other.hasPropertyQuota()) { + mergePropertyQuota(other.getPropertyQuota()); + } + if (!other.getKind().isEmpty()) { + kind_ = other.kind_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.RunFunnelReportResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.RunFunnelReportResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.analytics.data.v1alpha.FunnelSubReport funnelTable_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelSubReport, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder, + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder> + funnelTableBuilder_; + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * + * @return Whether the funnelTable field is set. + */ + public boolean hasFunnelTable() { + return funnelTableBuilder_ != null || funnelTable_ != null; + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * + * @return The funnelTable. + */ + public com.google.analytics.data.v1alpha.FunnelSubReport getFunnelTable() { + if (funnelTableBuilder_ == null) { + return funnelTable_ == null + ? com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance() + : funnelTable_; + } else { + return funnelTableBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + public Builder setFunnelTable(com.google.analytics.data.v1alpha.FunnelSubReport value) { + if (funnelTableBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + funnelTable_ = value; + onChanged(); + } else { + funnelTableBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + public Builder setFunnelTable( + com.google.analytics.data.v1alpha.FunnelSubReport.Builder builderForValue) { + if (funnelTableBuilder_ == null) { + funnelTable_ = builderForValue.build(); + onChanged(); + } else { + funnelTableBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + public Builder mergeFunnelTable(com.google.analytics.data.v1alpha.FunnelSubReport value) { + if (funnelTableBuilder_ == null) { + if (funnelTable_ != null) { + funnelTable_ = + com.google.analytics.data.v1alpha.FunnelSubReport.newBuilder(funnelTable_) + .mergeFrom(value) + .buildPartial(); + } else { + funnelTable_ = value; + } + onChanged(); + } else { + funnelTableBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + public Builder clearFunnelTable() { + if (funnelTableBuilder_ == null) { + funnelTable_ = null; + onChanged(); + } else { + funnelTable_ = null; + funnelTableBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + public com.google.analytics.data.v1alpha.FunnelSubReport.Builder getFunnelTableBuilder() { + + onChanged(); + return getFunnelTableFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + public com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder getFunnelTableOrBuilder() { + if (funnelTableBuilder_ != null) { + return funnelTableBuilder_.getMessageOrBuilder(); + } else { + return funnelTable_ == null + ? com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance() + : funnelTable_; + } + } + /** + * + * + *
+     * The funnel table is a report with the funnel step, segment, breakdown
+     * dimension, active users, completion rate, abandonments, and abandonments
+     * rate.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The breakdown dimension is only present in this response if it
+     * was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelSubReport, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder, + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder> + getFunnelTableFieldBuilder() { + if (funnelTableBuilder_ == null) { + funnelTableBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelSubReport, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder, + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder>( + getFunnelTable(), getParentForChildren(), isClean()); + funnelTable_ = null; + } + return funnelTableBuilder_; + } + + private com.google.analytics.data.v1alpha.FunnelSubReport funnelVisualization_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelSubReport, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder, + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder> + funnelVisualizationBuilder_; + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * + * @return Whether the funnelVisualization field is set. + */ + public boolean hasFunnelVisualization() { + return funnelVisualizationBuilder_ != null || funnelVisualization_ != null; + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * + * @return The funnelVisualization. + */ + public com.google.analytics.data.v1alpha.FunnelSubReport getFunnelVisualization() { + if (funnelVisualizationBuilder_ == null) { + return funnelVisualization_ == null + ? com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance() + : funnelVisualization_; + } else { + return funnelVisualizationBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + public Builder setFunnelVisualization(com.google.analytics.data.v1alpha.FunnelSubReport value) { + if (funnelVisualizationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + funnelVisualization_ = value; + onChanged(); + } else { + funnelVisualizationBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + public Builder setFunnelVisualization( + com.google.analytics.data.v1alpha.FunnelSubReport.Builder builderForValue) { + if (funnelVisualizationBuilder_ == null) { + funnelVisualization_ = builderForValue.build(); + onChanged(); + } else { + funnelVisualizationBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + public Builder mergeFunnelVisualization( + com.google.analytics.data.v1alpha.FunnelSubReport value) { + if (funnelVisualizationBuilder_ == null) { + if (funnelVisualization_ != null) { + funnelVisualization_ = + com.google.analytics.data.v1alpha.FunnelSubReport.newBuilder(funnelVisualization_) + .mergeFrom(value) + .buildPartial(); + } else { + funnelVisualization_ = value; + } + onChanged(); + } else { + funnelVisualizationBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + public Builder clearFunnelVisualization() { + if (funnelVisualizationBuilder_ == null) { + funnelVisualization_ = null; + onChanged(); + } else { + funnelVisualization_ = null; + funnelVisualizationBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + public com.google.analytics.data.v1alpha.FunnelSubReport.Builder + getFunnelVisualizationBuilder() { + + onChanged(); + return getFunnelVisualizationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + public com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder + getFunnelVisualizationOrBuilder() { + if (funnelVisualizationBuilder_ != null) { + return funnelVisualizationBuilder_.getMessageOrBuilder(); + } else { + return funnelVisualization_ == null + ? com.google.analytics.data.v1alpha.FunnelSubReport.getDefaultInstance() + : funnelVisualization_; + } + } + /** + * + * + *
+     * The funnel visualization is a report with the funnel step, segment, date,
+     * next action dimension, and active users.
+     * The segment dimension is only present in this response if a segment was
+     * requested. The date dimension is only present in this response if it was
+     * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+     * is only present in the response if it was requested.
+     * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelSubReport, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder, + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder> + getFunnelVisualizationFieldBuilder() { + if (funnelVisualizationBuilder_ == null) { + funnelVisualizationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.FunnelSubReport, + com.google.analytics.data.v1alpha.FunnelSubReport.Builder, + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder>( + getFunnelVisualization(), getParentForChildren(), isClean()); + funnelVisualization_ = null; + } + return funnelVisualizationBuilder_; + } + + private com.google.analytics.data.v1alpha.PropertyQuota propertyQuota_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.PropertyQuota, + com.google.analytics.data.v1alpha.PropertyQuota.Builder, + com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder> + propertyQuotaBuilder_; + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * + * @return Whether the propertyQuota field is set. + */ + public boolean hasPropertyQuota() { + return propertyQuotaBuilder_ != null || propertyQuota_ != null; + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * + * @return The propertyQuota. + */ + public com.google.analytics.data.v1alpha.PropertyQuota getPropertyQuota() { + if (propertyQuotaBuilder_ == null) { + return propertyQuota_ == null + ? com.google.analytics.data.v1alpha.PropertyQuota.getDefaultInstance() + : propertyQuota_; + } else { + return propertyQuotaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + public Builder setPropertyQuota(com.google.analytics.data.v1alpha.PropertyQuota value) { + if (propertyQuotaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + propertyQuota_ = value; + onChanged(); + } else { + propertyQuotaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + public Builder setPropertyQuota( + com.google.analytics.data.v1alpha.PropertyQuota.Builder builderForValue) { + if (propertyQuotaBuilder_ == null) { + propertyQuota_ = builderForValue.build(); + onChanged(); + } else { + propertyQuotaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + public Builder mergePropertyQuota(com.google.analytics.data.v1alpha.PropertyQuota value) { + if (propertyQuotaBuilder_ == null) { + if (propertyQuota_ != null) { + propertyQuota_ = + com.google.analytics.data.v1alpha.PropertyQuota.newBuilder(propertyQuota_) + .mergeFrom(value) + .buildPartial(); + } else { + propertyQuota_ = value; + } + onChanged(); + } else { + propertyQuotaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + public Builder clearPropertyQuota() { + if (propertyQuotaBuilder_ == null) { + propertyQuota_ = null; + onChanged(); + } else { + propertyQuota_ = null; + propertyQuotaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + public com.google.analytics.data.v1alpha.PropertyQuota.Builder getPropertyQuotaBuilder() { + + onChanged(); + return getPropertyQuotaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + public com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder getPropertyQuotaOrBuilder() { + if (propertyQuotaBuilder_ != null) { + return propertyQuotaBuilder_.getMessageOrBuilder(); + } else { + return propertyQuota_ == null + ? com.google.analytics.data.v1alpha.PropertyQuota.getDefaultInstance() + : propertyQuota_; + } + } + /** + * + * + *
+     * This Analytics Property's quota state including this request.
+     * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.PropertyQuota, + com.google.analytics.data.v1alpha.PropertyQuota.Builder, + com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder> + getPropertyQuotaFieldBuilder() { + if (propertyQuotaBuilder_ == null) { + propertyQuotaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.PropertyQuota, + com.google.analytics.data.v1alpha.PropertyQuota.Builder, + com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder>( + getPropertyQuota(), getParentForChildren(), isClean()); + propertyQuota_ = null; + } + return propertyQuotaBuilder_; + } + + private java.lang.Object kind_ = ""; + /** + * + * + *
+     * Identifies what kind of resource this message is. This `kind` is always the
+     * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+     * response types in JSON.
+     * 
+ * + * string kind = 4; + * + * @return The kind. + */ + public java.lang.String getKind() { + java.lang.Object ref = kind_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + kind_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Identifies what kind of resource this message is. This `kind` is always the
+     * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+     * response types in JSON.
+     * 
+ * + * string kind = 4; + * + * @return The bytes for kind. + */ + public com.google.protobuf.ByteString getKindBytes() { + java.lang.Object ref = kind_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + kind_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Identifies what kind of resource this message is. This `kind` is always the
+     * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+     * response types in JSON.
+     * 
+ * + * string kind = 4; + * + * @param value The kind to set. + * @return This builder for chaining. + */ + public Builder setKind(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + kind_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Identifies what kind of resource this message is. This `kind` is always the
+     * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+     * response types in JSON.
+     * 
+ * + * string kind = 4; + * + * @return This builder for chaining. + */ + public Builder clearKind() { + + kind_ = getDefaultInstance().getKind(); + onChanged(); + return this; + } + /** + * + * + *
+     * Identifies what kind of resource this message is. This `kind` is always the
+     * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+     * response types in JSON.
+     * 
+ * + * string kind = 4; + * + * @param value The bytes for kind to set. + * @return This builder for chaining. + */ + public Builder setKindBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + kind_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.RunFunnelReportResponse) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.RunFunnelReportResponse) + private static final com.google.analytics.data.v1alpha.RunFunnelReportResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.RunFunnelReportResponse(); + } + + public static com.google.analytics.data.v1alpha.RunFunnelReportResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RunFunnelReportResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new RunFunnelReportResponse(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.RunFunnelReportResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponseOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponseOrBuilder.java new file mode 100644 index 00000000..56815995 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/RunFunnelReportResponseOrBuilder.java @@ -0,0 +1,189 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/analytics_data_api.proto + +package com.google.analytics.data.v1alpha; + +public interface RunFunnelReportResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.RunFunnelReportResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The funnel table is a report with the funnel step, segment, breakdown
+   * dimension, active users, completion rate, abandonments, and abandonments
+   * rate.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The breakdown dimension is only present in this response if it
+   * was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * + * @return Whether the funnelTable field is set. + */ + boolean hasFunnelTable(); + /** + * + * + *
+   * The funnel table is a report with the funnel step, segment, breakdown
+   * dimension, active users, completion rate, abandonments, and abandonments
+   * rate.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The breakdown dimension is only present in this response if it
+   * was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * + * @return The funnelTable. + */ + com.google.analytics.data.v1alpha.FunnelSubReport getFunnelTable(); + /** + * + * + *
+   * The funnel table is a report with the funnel step, segment, breakdown
+   * dimension, active users, completion rate, abandonments, and abandonments
+   * rate.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The breakdown dimension is only present in this response if it
+   * was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder getFunnelTableOrBuilder(); + + /** + * + * + *
+   * The funnel visualization is a report with the funnel step, segment, date,
+   * next action dimension, and active users.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The date dimension is only present in this response if it was
+   * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+   * is only present in the response if it was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * + * @return Whether the funnelVisualization field is set. + */ + boolean hasFunnelVisualization(); + /** + * + * + *
+   * The funnel visualization is a report with the funnel step, segment, date,
+   * next action dimension, and active users.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The date dimension is only present in this response if it was
+   * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+   * is only present in the response if it was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * + * @return The funnelVisualization. + */ + com.google.analytics.data.v1alpha.FunnelSubReport getFunnelVisualization(); + /** + * + * + *
+   * The funnel visualization is a report with the funnel step, segment, date,
+   * next action dimension, and active users.
+   * The segment dimension is only present in this response if a segment was
+   * requested. The date dimension is only present in this response if it was
+   * requested via the `TRENDED_FUNNEL` funnel type. The next action dimension
+   * is only present in the response if it was requested.
+   * 
+ * + * .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + com.google.analytics.data.v1alpha.FunnelSubReportOrBuilder getFunnelVisualizationOrBuilder(); + + /** + * + * + *
+   * This Analytics Property's quota state including this request.
+   * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * + * @return Whether the propertyQuota field is set. + */ + boolean hasPropertyQuota(); + /** + * + * + *
+   * This Analytics Property's quota state including this request.
+   * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * + * @return The propertyQuota. + */ + com.google.analytics.data.v1alpha.PropertyQuota getPropertyQuota(); + /** + * + * + *
+   * This Analytics Property's quota state including this request.
+   * 
+ * + * .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + com.google.analytics.data.v1alpha.PropertyQuotaOrBuilder getPropertyQuotaOrBuilder(); + + /** + * + * + *
+   * Identifies what kind of resource this message is. This `kind` is always the
+   * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+   * response types in JSON.
+   * 
+ * + * string kind = 4; + * + * @return The kind. + */ + java.lang.String getKind(); + /** + * + * + *
+   * Identifies what kind of resource this message is. This `kind` is always the
+   * fixed string "analyticsData#runFunnelReport". Useful to distinguish between
+   * response types in JSON.
+   * 
+ * + * string kind = 4; + * + * @return The bytes for kind. + */ + com.google.protobuf.ByteString getKindBytes(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadata.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadata.java new file mode 100644 index 00000000..120c1be0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadata.java @@ -0,0 +1,676 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * If funnel report results are
+ * [sampled](https://support.google.com/analytics/answer/2637192), this
+ * metadata describes what percentage of events were used in this funnel
+ * report for a date range. Sampling is the practice of analyzing a subset of
+ * all data in order to uncover the meaningful information in the larger data
+ * set.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SamplingMetadata} + */ +public final class SamplingMetadata extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SamplingMetadata) + SamplingMetadataOrBuilder { + private static final long serialVersionUID = 0L; + // Use SamplingMetadata.newBuilder() to construct. + private SamplingMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SamplingMetadata() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SamplingMetadata(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SamplingMetadata( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + samplesReadCount_ = input.readInt64(); + break; + } + case 16: + { + samplingSpaceSize_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SamplingMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SamplingMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SamplingMetadata.class, + com.google.analytics.data.v1alpha.SamplingMetadata.Builder.class); + } + + public static final int SAMPLES_READ_COUNT_FIELD_NUMBER = 1; + private long samplesReadCount_; + /** + * + * + *
+   * The total number of events read in this sampled report for a date range.
+   * This is the size of the subset this property's data that was analyzed in
+   * this funnel report.
+   * 
+ * + * int64 samples_read_count = 1; + * + * @return The samplesReadCount. + */ + @java.lang.Override + public long getSamplesReadCount() { + return samplesReadCount_; + } + + public static final int SAMPLING_SPACE_SIZE_FIELD_NUMBER = 2; + private long samplingSpaceSize_; + /** + * + * + *
+   * The total number of events present in this property's data that could
+   * have been analyzed in this funnel report for a date range. Sampling
+   * uncovers the meaningful information about the larger data set, and this
+   * is the size of the larger data set.
+   * To calculate the percentage of available data that was used in this
+   * funnel report, compute `samplesReadCount/samplingSpaceSize`.
+   * 
+ * + * int64 sampling_space_size = 2; + * + * @return The samplingSpaceSize. + */ + @java.lang.Override + public long getSamplingSpaceSize() { + return samplingSpaceSize_; + } + + 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 (samplesReadCount_ != 0L) { + output.writeInt64(1, samplesReadCount_); + } + if (samplingSpaceSize_ != 0L) { + output.writeInt64(2, samplingSpaceSize_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (samplesReadCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, samplesReadCount_); + } + if (samplingSpaceSize_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, samplingSpaceSize_); + } + size += unknownFields.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.analytics.data.v1alpha.SamplingMetadata)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SamplingMetadata other = + (com.google.analytics.data.v1alpha.SamplingMetadata) obj; + + if (getSamplesReadCount() != other.getSamplesReadCount()) return false; + if (getSamplingSpaceSize() != other.getSamplingSpaceSize()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + SAMPLES_READ_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSamplesReadCount()); + hash = (37 * hash) + SAMPLING_SPACE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSamplingSpaceSize()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata 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.analytics.data.v1alpha.SamplingMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SamplingMetadata 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * If funnel report results are
+   * [sampled](https://support.google.com/analytics/answer/2637192), this
+   * metadata describes what percentage of events were used in this funnel
+   * report for a date range. Sampling is the practice of analyzing a subset of
+   * all data in order to uncover the meaningful information in the larger data
+   * set.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SamplingMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SamplingMetadata) + com.google.analytics.data.v1alpha.SamplingMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SamplingMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SamplingMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SamplingMetadata.class, + com.google.analytics.data.v1alpha.SamplingMetadata.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SamplingMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + samplesReadCount_ = 0L; + + samplingSpaceSize_ = 0L; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SamplingMetadata_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SamplingMetadata getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SamplingMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SamplingMetadata build() { + com.google.analytics.data.v1alpha.SamplingMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SamplingMetadata buildPartial() { + com.google.analytics.data.v1alpha.SamplingMetadata result = + new com.google.analytics.data.v1alpha.SamplingMetadata(this); + result.samplesReadCount_ = samplesReadCount_; + result.samplingSpaceSize_ = samplingSpaceSize_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SamplingMetadata) { + return mergeFrom((com.google.analytics.data.v1alpha.SamplingMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SamplingMetadata other) { + if (other == com.google.analytics.data.v1alpha.SamplingMetadata.getDefaultInstance()) + return this; + if (other.getSamplesReadCount() != 0L) { + setSamplesReadCount(other.getSamplesReadCount()); + } + if (other.getSamplingSpaceSize() != 0L) { + setSamplingSpaceSize(other.getSamplingSpaceSize()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SamplingMetadata parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SamplingMetadata) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private long samplesReadCount_; + /** + * + * + *
+     * The total number of events read in this sampled report for a date range.
+     * This is the size of the subset this property's data that was analyzed in
+     * this funnel report.
+     * 
+ * + * int64 samples_read_count = 1; + * + * @return The samplesReadCount. + */ + @java.lang.Override + public long getSamplesReadCount() { + return samplesReadCount_; + } + /** + * + * + *
+     * The total number of events read in this sampled report for a date range.
+     * This is the size of the subset this property's data that was analyzed in
+     * this funnel report.
+     * 
+ * + * int64 samples_read_count = 1; + * + * @param value The samplesReadCount to set. + * @return This builder for chaining. + */ + public Builder setSamplesReadCount(long value) { + + samplesReadCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The total number of events read in this sampled report for a date range.
+     * This is the size of the subset this property's data that was analyzed in
+     * this funnel report.
+     * 
+ * + * int64 samples_read_count = 1; + * + * @return This builder for chaining. + */ + public Builder clearSamplesReadCount() { + + samplesReadCount_ = 0L; + onChanged(); + return this; + } + + private long samplingSpaceSize_; + /** + * + * + *
+     * The total number of events present in this property's data that could
+     * have been analyzed in this funnel report for a date range. Sampling
+     * uncovers the meaningful information about the larger data set, and this
+     * is the size of the larger data set.
+     * To calculate the percentage of available data that was used in this
+     * funnel report, compute `samplesReadCount/samplingSpaceSize`.
+     * 
+ * + * int64 sampling_space_size = 2; + * + * @return The samplingSpaceSize. + */ + @java.lang.Override + public long getSamplingSpaceSize() { + return samplingSpaceSize_; + } + /** + * + * + *
+     * The total number of events present in this property's data that could
+     * have been analyzed in this funnel report for a date range. Sampling
+     * uncovers the meaningful information about the larger data set, and this
+     * is the size of the larger data set.
+     * To calculate the percentage of available data that was used in this
+     * funnel report, compute `samplesReadCount/samplingSpaceSize`.
+     * 
+ * + * int64 sampling_space_size = 2; + * + * @param value The samplingSpaceSize to set. + * @return This builder for chaining. + */ + public Builder setSamplingSpaceSize(long value) { + + samplingSpaceSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The total number of events present in this property's data that could
+     * have been analyzed in this funnel report for a date range. Sampling
+     * uncovers the meaningful information about the larger data set, and this
+     * is the size of the larger data set.
+     * To calculate the percentage of available data that was used in this
+     * funnel report, compute `samplesReadCount/samplingSpaceSize`.
+     * 
+ * + * int64 sampling_space_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearSamplingSpaceSize() { + + samplingSpaceSize_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SamplingMetadata) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SamplingMetadata) + private static final com.google.analytics.data.v1alpha.SamplingMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SamplingMetadata(); + } + + public static com.google.analytics.data.v1alpha.SamplingMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SamplingMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SamplingMetadata(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SamplingMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadataOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadataOrBuilder.java new file mode 100644 index 00000000..72f910d4 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SamplingMetadataOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SamplingMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SamplingMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The total number of events read in this sampled report for a date range.
+   * This is the size of the subset this property's data that was analyzed in
+   * this funnel report.
+   * 
+ * + * int64 samples_read_count = 1; + * + * @return The samplesReadCount. + */ + long getSamplesReadCount(); + + /** + * + * + *
+   * The total number of events present in this property's data that could
+   * have been analyzed in this funnel report for a date range. Sampling
+   * uncovers the meaningful information about the larger data set, and this
+   * is the size of the larger data set.
+   * To calculate the percentage of available data that was used in this
+   * funnel report, compute `samplesReadCount/samplingSpaceSize`.
+   * 
+ * + * int64 sampling_space_size = 2; + * + * @return The samplingSpaceSize. + */ + long getSamplingSpaceSize(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Segment.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Segment.java new file mode 100644 index 00000000..55ada788 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/Segment.java @@ -0,0 +1,1695 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A segment is a subset of your Analytics data. For example, of your entire set
+ * of users, one segment might be users from a particular country or city.
+ * Another segment might be users who purchase a particular line of products or
+ * who visit a specific part of your site or trigger certain events in your app.
+ * To learn more, see [GA4 Segment
+ * Builder](https://support.google.com/analytics/answer/9304353).
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Segment} + */ +public final class Segment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.Segment) + SegmentOrBuilder { + private static final long serialVersionUID = 0L; + // Use Segment.newBuilder() to construct. + private Segment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Segment() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Segment(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Segment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + name_ = s; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.UserSegment.Builder subBuilder = null; + if (oneSegmentScopeCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_).toBuilder(); + } + oneSegmentScope_ = + input.readMessage( + com.google.analytics.data.v1alpha.UserSegment.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_); + oneSegmentScope_ = subBuilder.buildPartial(); + } + oneSegmentScopeCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.SessionSegment.Builder subBuilder = null; + if (oneSegmentScopeCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_) + .toBuilder(); + } + oneSegmentScope_ = + input.readMessage( + com.google.analytics.data.v1alpha.SessionSegment.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_); + oneSegmentScope_ = subBuilder.buildPartial(); + } + oneSegmentScopeCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.EventSegment.Builder subBuilder = null; + if (oneSegmentScopeCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_).toBuilder(); + } + oneSegmentScope_ = + input.readMessage( + com.google.analytics.data.v1alpha.EventSegment.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_); + oneSegmentScope_ = subBuilder.buildPartial(); + } + oneSegmentScopeCase_ = 4; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Segment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Segment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Segment.class, + com.google.analytics.data.v1alpha.Segment.Builder.class); + } + + private int oneSegmentScopeCase_ = 0; + private java.lang.Object oneSegmentScope_; + + public enum OneSegmentScopeCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + USER_SEGMENT(2), + SESSION_SEGMENT(3), + EVENT_SEGMENT(4), + ONESEGMENTSCOPE_NOT_SET(0); + private final int value; + + private OneSegmentScopeCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneSegmentScopeCase valueOf(int value) { + return forNumber(value); + } + + public static OneSegmentScopeCase forNumber(int value) { + switch (value) { + case 2: + return USER_SEGMENT; + case 3: + return SESSION_SEGMENT; + case 4: + return EVENT_SEGMENT; + case 0: + return ONESEGMENTSCOPE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneSegmentScopeCase getOneSegmentScopeCase() { + return OneSegmentScopeCase.forNumber(oneSegmentScopeCase_); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The name for this segment. If unspecified, segments are named "Segment".
+   * This name defines string value returned by the `segment` dimension. The
+   * `segment` dimension prefixes segment names by the 1-based index number of
+   * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+   * 
+ * + * 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 name for this segment. If unspecified, segments are named "Segment".
+   * This name defines string value returned by the `segment` dimension. The
+   * `segment` dimension prefixes segment names by the 1-based index number of
+   * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+   * 
+ * + * 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 USER_SEGMENT_FIELD_NUMBER = 2; + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * + * @return Whether the userSegment field is set. + */ + @java.lang.Override + public boolean hasUserSegment() { + return oneSegmentScopeCase_ == 2; + } + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * + * @return The userSegment. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegment getUserSegment() { + if (oneSegmentScopeCase_ == 2) { + return (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentOrBuilder getUserSegmentOrBuilder() { + if (oneSegmentScopeCase_ == 2) { + return (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } + + public static final int SESSION_SEGMENT_FIELD_NUMBER = 3; + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site
+   * or app.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * + * @return Whether the sessionSegment field is set. + */ + @java.lang.Override + public boolean hasSessionSegment() { + return oneSegmentScopeCase_ == 3; + } + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site
+   * or app.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * + * @return The sessionSegment. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegment getSessionSegment() { + if (oneSegmentScopeCase_ == 3) { + return (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site
+   * or app.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentOrBuilder getSessionSegmentOrBuilder() { + if (oneSegmentScopeCase_ == 3) { + return (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } + + public static final int EVENT_SEGMENT_FIELD_NUMBER = 4; + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or
+   * app.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * + * @return Whether the eventSegment field is set. + */ + @java.lang.Override + public boolean hasEventSegment() { + return oneSegmentScopeCase_ == 4; + } + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or
+   * app.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * + * @return The eventSegment. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegment getEventSegment() { + if (oneSegmentScopeCase_ == 4) { + return (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or
+   * app.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentOrBuilder getEventSegmentOrBuilder() { + if (oneSegmentScopeCase_ == 4) { + return (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (oneSegmentScopeCase_ == 2) { + output.writeMessage(2, (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_); + } + if (oneSegmentScopeCase_ == 3) { + output.writeMessage(3, (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_); + } + if (oneSegmentScopeCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (oneSegmentScopeCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_); + } + if (oneSegmentScopeCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_); + } + if (oneSegmentScopeCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_); + } + size += unknownFields.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.analytics.data.v1alpha.Segment)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.Segment other = + (com.google.analytics.data.v1alpha.Segment) obj; + + if (!getName().equals(other.getName())) return false; + if (!getOneSegmentScopeCase().equals(other.getOneSegmentScopeCase())) return false; + switch (oneSegmentScopeCase_) { + case 2: + if (!getUserSegment().equals(other.getUserSegment())) return false; + break; + case 3: + if (!getSessionSegment().equals(other.getSessionSegment())) return false; + break; + case 4: + if (!getEventSegment().equals(other.getEventSegment())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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(); + switch (oneSegmentScopeCase_) { + case 2: + hash = (37 * hash) + USER_SEGMENT_FIELD_NUMBER; + hash = (53 * hash) + getUserSegment().hashCode(); + break; + case 3: + hash = (37 * hash) + SESSION_SEGMENT_FIELD_NUMBER; + hash = (53 * hash) + getSessionSegment().hashCode(); + break; + case 4: + hash = (37 * hash) + EVENT_SEGMENT_FIELD_NUMBER; + hash = (53 * hash) + getEventSegment().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Segment 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.analytics.data.v1alpha.Segment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Segment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Segment parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.Segment parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.Segment 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A segment is a subset of your Analytics data. For example, of your entire set
+   * of users, one segment might be users from a particular country or city.
+   * Another segment might be users who purchase a particular line of products or
+   * who visit a specific part of your site or trigger certain events in your app.
+   * To learn more, see [GA4 Segment
+   * Builder](https://support.google.com/analytics/answer/9304353).
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.Segment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.Segment) + com.google.analytics.data.v1alpha.SegmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Segment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Segment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.Segment.class, + com.google.analytics.data.v1alpha.Segment.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.Segment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_Segment_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Segment getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.Segment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Segment build() { + com.google.analytics.data.v1alpha.Segment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.Segment buildPartial() { + com.google.analytics.data.v1alpha.Segment result = + new com.google.analytics.data.v1alpha.Segment(this); + result.name_ = name_; + if (oneSegmentScopeCase_ == 2) { + if (userSegmentBuilder_ == null) { + result.oneSegmentScope_ = oneSegmentScope_; + } else { + result.oneSegmentScope_ = userSegmentBuilder_.build(); + } + } + if (oneSegmentScopeCase_ == 3) { + if (sessionSegmentBuilder_ == null) { + result.oneSegmentScope_ = oneSegmentScope_; + } else { + result.oneSegmentScope_ = sessionSegmentBuilder_.build(); + } + } + if (oneSegmentScopeCase_ == 4) { + if (eventSegmentBuilder_ == null) { + result.oneSegmentScope_ = oneSegmentScope_; + } else { + result.oneSegmentScope_ = eventSegmentBuilder_.build(); + } + } + result.oneSegmentScopeCase_ = oneSegmentScopeCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.Segment) { + return mergeFrom((com.google.analytics.data.v1alpha.Segment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.Segment other) { + if (other == com.google.analytics.data.v1alpha.Segment.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + switch (other.getOneSegmentScopeCase()) { + case USER_SEGMENT: + { + mergeUserSegment(other.getUserSegment()); + break; + } + case SESSION_SEGMENT: + { + mergeSessionSegment(other.getSessionSegment()); + break; + } + case EVENT_SEGMENT: + { + mergeEventSegment(other.getEventSegment()); + break; + } + case ONESEGMENTSCOPE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.Segment parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.Segment) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneSegmentScopeCase_ = 0; + private java.lang.Object oneSegmentScope_; + + public OneSegmentScopeCase getOneSegmentScopeCase() { + return OneSegmentScopeCase.forNumber(oneSegmentScopeCase_); + } + + public Builder clearOneSegmentScope() { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + onChanged(); + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The name for this segment. If unspecified, segments are named "Segment".
+     * This name defines string value returned by the `segment` dimension. The
+     * `segment` dimension prefixes segment names by the 1-based index number of
+     * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+     * 
+ * + * 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 name for this segment. If unspecified, segments are named "Segment".
+     * This name defines string value returned by the `segment` dimension. The
+     * `segment` dimension prefixes segment names by the 1-based index number of
+     * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+     * 
+ * + * 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 name for this segment. If unspecified, segments are named "Segment".
+     * This name defines string value returned by the `segment` dimension. The
+     * `segment` dimension prefixes segment names by the 1-based index number of
+     * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The name for this segment. If unspecified, segments are named "Segment".
+     * This name defines string value returned by the `segment` dimension. The
+     * `segment` dimension prefixes segment names by the 1-based index number of
+     * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The name for this segment. If unspecified, segments are named "Segment".
+     * This name defines string value returned by the `segment` dimension. The
+     * `segment` dimension prefixes segment names by the 1-based index number of
+     * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegment, + com.google.analytics.data.v1alpha.UserSegment.Builder, + com.google.analytics.data.v1alpha.UserSegmentOrBuilder> + userSegmentBuilder_; + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * + * @return Whether the userSegment field is set. + */ + @java.lang.Override + public boolean hasUserSegment() { + return oneSegmentScopeCase_ == 2; + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * + * @return The userSegment. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegment getUserSegment() { + if (userSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 2) { + return (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } else { + if (oneSegmentScopeCase_ == 2) { + return userSegmentBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + public Builder setUserSegment(com.google.analytics.data.v1alpha.UserSegment value) { + if (userSegmentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneSegmentScope_ = value; + onChanged(); + } else { + userSegmentBuilder_.setMessage(value); + } + oneSegmentScopeCase_ = 2; + return this; + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + public Builder setUserSegment( + com.google.analytics.data.v1alpha.UserSegment.Builder builderForValue) { + if (userSegmentBuilder_ == null) { + oneSegmentScope_ = builderForValue.build(); + onChanged(); + } else { + userSegmentBuilder_.setMessage(builderForValue.build()); + } + oneSegmentScopeCase_ = 2; + return this; + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + public Builder mergeUserSegment(com.google.analytics.data.v1alpha.UserSegment value) { + if (userSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 2 + && oneSegmentScope_ + != com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance()) { + oneSegmentScope_ = + com.google.analytics.data.v1alpha.UserSegment.newBuilder( + (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_) + .mergeFrom(value) + .buildPartial(); + } else { + oneSegmentScope_ = value; + } + onChanged(); + } else { + if (oneSegmentScopeCase_ == 2) { + userSegmentBuilder_.mergeFrom(value); + } else { + userSegmentBuilder_.setMessage(value); + } + } + oneSegmentScopeCase_ = 2; + return this; + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + public Builder clearUserSegment() { + if (userSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 2) { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + onChanged(); + } + } else { + if (oneSegmentScopeCase_ == 2) { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + } + userSegmentBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + public com.google.analytics.data.v1alpha.UserSegment.Builder getUserSegmentBuilder() { + return getUserSegmentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentOrBuilder getUserSegmentOrBuilder() { + if ((oneSegmentScopeCase_ == 2) && (userSegmentBuilder_ != null)) { + return userSegmentBuilder_.getMessageOrBuilder(); + } else { + if (oneSegmentScopeCase_ == 2) { + return (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } + } + /** + * + * + *
+     * User segments are subsets of users who engaged with your site or app.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegment, + com.google.analytics.data.v1alpha.UserSegment.Builder, + com.google.analytics.data.v1alpha.UserSegmentOrBuilder> + getUserSegmentFieldBuilder() { + if (userSegmentBuilder_ == null) { + if (!(oneSegmentScopeCase_ == 2)) { + oneSegmentScope_ = com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } + userSegmentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegment, + com.google.analytics.data.v1alpha.UserSegment.Builder, + com.google.analytics.data.v1alpha.UserSegmentOrBuilder>( + (com.google.analytics.data.v1alpha.UserSegment) oneSegmentScope_, + getParentForChildren(), + isClean()); + oneSegmentScope_ = null; + } + oneSegmentScopeCase_ = 2; + onChanged(); + ; + return userSegmentBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegment, + com.google.analytics.data.v1alpha.SessionSegment.Builder, + com.google.analytics.data.v1alpha.SessionSegmentOrBuilder> + sessionSegmentBuilder_; + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * + * @return Whether the sessionSegment field is set. + */ + @java.lang.Override + public boolean hasSessionSegment() { + return oneSegmentScopeCase_ == 3; + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * + * @return The sessionSegment. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegment getSessionSegment() { + if (sessionSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 3) { + return (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } else { + if (oneSegmentScopeCase_ == 3) { + return sessionSegmentBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + public Builder setSessionSegment(com.google.analytics.data.v1alpha.SessionSegment value) { + if (sessionSegmentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneSegmentScope_ = value; + onChanged(); + } else { + sessionSegmentBuilder_.setMessage(value); + } + oneSegmentScopeCase_ = 3; + return this; + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + public Builder setSessionSegment( + com.google.analytics.data.v1alpha.SessionSegment.Builder builderForValue) { + if (sessionSegmentBuilder_ == null) { + oneSegmentScope_ = builderForValue.build(); + onChanged(); + } else { + sessionSegmentBuilder_.setMessage(builderForValue.build()); + } + oneSegmentScopeCase_ = 3; + return this; + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + public Builder mergeSessionSegment(com.google.analytics.data.v1alpha.SessionSegment value) { + if (sessionSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 3 + && oneSegmentScope_ + != com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance()) { + oneSegmentScope_ = + com.google.analytics.data.v1alpha.SessionSegment.newBuilder( + (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_) + .mergeFrom(value) + .buildPartial(); + } else { + oneSegmentScope_ = value; + } + onChanged(); + } else { + if (oneSegmentScopeCase_ == 3) { + sessionSegmentBuilder_.mergeFrom(value); + } else { + sessionSegmentBuilder_.setMessage(value); + } + } + oneSegmentScopeCase_ = 3; + return this; + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + public Builder clearSessionSegment() { + if (sessionSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 3) { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + onChanged(); + } + } else { + if (oneSegmentScopeCase_ == 3) { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + } + sessionSegmentBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + public com.google.analytics.data.v1alpha.SessionSegment.Builder getSessionSegmentBuilder() { + return getSessionSegmentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentOrBuilder getSessionSegmentOrBuilder() { + if ((oneSegmentScopeCase_ == 3) && (sessionSegmentBuilder_ != null)) { + return sessionSegmentBuilder_.getMessageOrBuilder(); + } else { + if (oneSegmentScopeCase_ == 3) { + return (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } + } + /** + * + * + *
+     * Session segments are subsets of the sessions that occurred on your site
+     * or app.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegment, + com.google.analytics.data.v1alpha.SessionSegment.Builder, + com.google.analytics.data.v1alpha.SessionSegmentOrBuilder> + getSessionSegmentFieldBuilder() { + if (sessionSegmentBuilder_ == null) { + if (!(oneSegmentScopeCase_ == 3)) { + oneSegmentScope_ = com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } + sessionSegmentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegment, + com.google.analytics.data.v1alpha.SessionSegment.Builder, + com.google.analytics.data.v1alpha.SessionSegmentOrBuilder>( + (com.google.analytics.data.v1alpha.SessionSegment) oneSegmentScope_, + getParentForChildren(), + isClean()); + oneSegmentScope_ = null; + } + oneSegmentScopeCase_ = 3; + onChanged(); + ; + return sessionSegmentBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegment, + com.google.analytics.data.v1alpha.EventSegment.Builder, + com.google.analytics.data.v1alpha.EventSegmentOrBuilder> + eventSegmentBuilder_; + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * + * @return Whether the eventSegment field is set. + */ + @java.lang.Override + public boolean hasEventSegment() { + return oneSegmentScopeCase_ == 4; + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * + * @return The eventSegment. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegment getEventSegment() { + if (eventSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 4) { + return (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } else { + if (oneSegmentScopeCase_ == 4) { + return eventSegmentBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + public Builder setEventSegment(com.google.analytics.data.v1alpha.EventSegment value) { + if (eventSegmentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneSegmentScope_ = value; + onChanged(); + } else { + eventSegmentBuilder_.setMessage(value); + } + oneSegmentScopeCase_ = 4; + return this; + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + public Builder setEventSegment( + com.google.analytics.data.v1alpha.EventSegment.Builder builderForValue) { + if (eventSegmentBuilder_ == null) { + oneSegmentScope_ = builderForValue.build(); + onChanged(); + } else { + eventSegmentBuilder_.setMessage(builderForValue.build()); + } + oneSegmentScopeCase_ = 4; + return this; + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + public Builder mergeEventSegment(com.google.analytics.data.v1alpha.EventSegment value) { + if (eventSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 4 + && oneSegmentScope_ + != com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance()) { + oneSegmentScope_ = + com.google.analytics.data.v1alpha.EventSegment.newBuilder( + (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_) + .mergeFrom(value) + .buildPartial(); + } else { + oneSegmentScope_ = value; + } + onChanged(); + } else { + if (oneSegmentScopeCase_ == 4) { + eventSegmentBuilder_.mergeFrom(value); + } else { + eventSegmentBuilder_.setMessage(value); + } + } + oneSegmentScopeCase_ = 4; + return this; + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + public Builder clearEventSegment() { + if (eventSegmentBuilder_ == null) { + if (oneSegmentScopeCase_ == 4) { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + onChanged(); + } + } else { + if (oneSegmentScopeCase_ == 4) { + oneSegmentScopeCase_ = 0; + oneSegmentScope_ = null; + } + eventSegmentBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + public com.google.analytics.data.v1alpha.EventSegment.Builder getEventSegmentBuilder() { + return getEventSegmentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.EventSegmentOrBuilder getEventSegmentOrBuilder() { + if ((oneSegmentScopeCase_ == 4) && (eventSegmentBuilder_ != null)) { + return eventSegmentBuilder_.getMessageOrBuilder(); + } else { + if (oneSegmentScopeCase_ == 4) { + return (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_; + } + return com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } + } + /** + * + * + *
+     * Event segments are subsets of events that were triggered on your site or
+     * app.
+     * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegment, + com.google.analytics.data.v1alpha.EventSegment.Builder, + com.google.analytics.data.v1alpha.EventSegmentOrBuilder> + getEventSegmentFieldBuilder() { + if (eventSegmentBuilder_ == null) { + if (!(oneSegmentScopeCase_ == 4)) { + oneSegmentScope_ = com.google.analytics.data.v1alpha.EventSegment.getDefaultInstance(); + } + eventSegmentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.EventSegment, + com.google.analytics.data.v1alpha.EventSegment.Builder, + com.google.analytics.data.v1alpha.EventSegmentOrBuilder>( + (com.google.analytics.data.v1alpha.EventSegment) oneSegmentScope_, + getParentForChildren(), + isClean()); + oneSegmentScope_ = null; + } + oneSegmentScopeCase_ = 4; + onChanged(); + ; + return eventSegmentBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.Segment) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.Segment) + private static final com.google.analytics.data.v1alpha.Segment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.Segment(); + } + + public static com.google.analytics.data.v1alpha.Segment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Segment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Segment(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.Segment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilter.java new file mode 100644 index 00000000..c1813e67 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilter.java @@ -0,0 +1,1066 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Creates a filter that matches events of a single event name. If a parameter
+ * filter expression is specified, only the subset of events that match both the
+ * single event name and the parameter filter expressions match this event
+ * filter.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentEventFilter} + */ +public final class SegmentEventFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentEventFilter) + SegmentEventFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentEventFilter.newBuilder() to construct. + private SegmentEventFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentEventFilter() { + eventName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentEventFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentEventFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + bitField0_ |= 0x00000001; + eventName_ = s; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + subBuilder = null; + if (((bitField0_ & 0x00000002) != 0)) { + subBuilder = segmentParameterFilterExpression_.toBuilder(); + } + segmentParameterFilterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(segmentParameterFilterExpression_); + segmentParameterFilterExpression_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000002; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentEventFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentEventFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentEventFilter.class, + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder.class); + } + + private int bitField0_; + public static final int EVENT_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object eventName_; + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return Whether the eventName field is set. + */ + @java.lang.Override + public boolean hasEventName() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The eventName. + */ + @java.lang.Override + public java.lang.String getEventName() { + java.lang.Object ref = eventName_; + 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(); + eventName_ = s; + return s; + } + } + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The bytes for eventName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEventNameBytes() { + java.lang.Object ref = eventName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + eventName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SEGMENT_PARAMETER_FILTER_EXPRESSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + segmentParameterFilterExpression_; + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + * + * @return Whether the segmentParameterFilterExpression field is set. + */ + @java.lang.Override + public boolean hasSegmentParameterFilterExpression() { + return ((bitField0_ & 0x00000002) != 0); + } + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + * + * @return The segmentParameterFilterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + getSegmentParameterFilterExpression() { + return segmentParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.getDefaultInstance() + : segmentParameterFilterExpression_; + } + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getSegmentParameterFilterExpressionOrBuilder() { + return segmentParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.getDefaultInstance() + : segmentParameterFilterExpression_; + } + + 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)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, eventName_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getSegmentParameterFilterExpression()); + } + unknownFields.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.GeneratedMessageV3.computeStringSize(1, eventName_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, getSegmentParameterFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentEventFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentEventFilter other = + (com.google.analytics.data.v1alpha.SegmentEventFilter) obj; + + if (hasEventName() != other.hasEventName()) return false; + if (hasEventName()) { + if (!getEventName().equals(other.getEventName())) return false; + } + if (hasSegmentParameterFilterExpression() != other.hasSegmentParameterFilterExpression()) + return false; + if (hasSegmentParameterFilterExpression()) { + if (!getSegmentParameterFilterExpression() + .equals(other.getSegmentParameterFilterExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasEventName()) { + hash = (37 * hash) + EVENT_NAME_FIELD_NUMBER; + hash = (53 * hash) + getEventName().hashCode(); + } + if (hasSegmentParameterFilterExpression()) { + hash = (37 * hash) + SEGMENT_PARAMETER_FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getSegmentParameterFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter 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.analytics.data.v1alpha.SegmentEventFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentEventFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a parameter
+   * filter expression is specified, only the subset of events that match both the
+   * single event name and the parameter filter expressions match this event
+   * filter.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentEventFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentEventFilter) + com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentEventFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentEventFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentEventFilter.class, + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentEventFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getSegmentParameterFilterExpressionFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + eventName_ = ""; + bitField0_ = (bitField0_ & ~0x00000001); + if (segmentParameterFilterExpressionBuilder_ == null) { + segmentParameterFilterExpression_ = null; + } else { + segmentParameterFilterExpressionBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentEventFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilter build() { + com.google.analytics.data.v1alpha.SegmentEventFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilter buildPartial() { + com.google.analytics.data.v1alpha.SegmentEventFilter result = + new com.google.analytics.data.v1alpha.SegmentEventFilter(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + to_bitField0_ |= 0x00000001; + } + result.eventName_ = eventName_; + if (((from_bitField0_ & 0x00000002) != 0)) { + if (segmentParameterFilterExpressionBuilder_ == null) { + result.segmentParameterFilterExpression_ = segmentParameterFilterExpression_; + } else { + result.segmentParameterFilterExpression_ = + segmentParameterFilterExpressionBuilder_.build(); + } + to_bitField0_ |= 0x00000002; + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentEventFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentEventFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SegmentEventFilter other) { + if (other == com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance()) + return this; + if (other.hasEventName()) { + bitField0_ |= 0x00000001; + eventName_ = other.eventName_; + onChanged(); + } + if (other.hasSegmentParameterFilterExpression()) { + mergeSegmentParameterFilterExpression(other.getSegmentParameterFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentEventFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentEventFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object eventName_ = ""; + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return Whether the eventName field is set. + */ + public boolean hasEventName() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return The eventName. + */ + public java.lang.String getEventName() { + java.lang.Object ref = eventName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + eventName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return The bytes for eventName. + */ + public com.google.protobuf.ByteString getEventNameBytes() { + java.lang.Object ref = eventName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + eventName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @param value The eventName to set. + * @return This builder for chaining. + */ + public Builder setEventName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + eventName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearEventName() { + bitField0_ = (bitField0_ & ~0x00000001); + eventName_ = getDefaultInstance().getEventName(); + onChanged(); + return this; + } + /** + * + * + *
+     * This filter matches events of this single event name. Event name is
+     * required.
+     * 
+ * + * optional string event_name = 1; + * + * @param value The bytes for eventName to set. + * @return This builder for chaining. + */ + public Builder setEventNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + bitField0_ |= 0x00000001; + eventName_ = value; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + segmentParameterFilterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + segmentParameterFilterExpressionBuilder_; + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + * + * @return Whether the segmentParameterFilterExpression field is set. + */ + public boolean hasSegmentParameterFilterExpression() { + return ((bitField0_ & 0x00000002) != 0); + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + * + * @return The segmentParameterFilterExpression. + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + getSegmentParameterFilterExpression() { + if (segmentParameterFilterExpressionBuilder_ == null) { + return segmentParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance() + : segmentParameterFilterExpression_; + } else { + return segmentParameterFilterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + public Builder setSegmentParameterFilterExpression( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (segmentParameterFilterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + segmentParameterFilterExpression_ = value; + onChanged(); + } else { + segmentParameterFilterExpressionBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + public Builder setSegmentParameterFilterExpression( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + builderForValue) { + if (segmentParameterFilterExpressionBuilder_ == null) { + segmentParameterFilterExpression_ = builderForValue.build(); + onChanged(); + } else { + segmentParameterFilterExpressionBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + public Builder mergeSegmentParameterFilterExpression( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (segmentParameterFilterExpressionBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && segmentParameterFilterExpression_ != null + && segmentParameterFilterExpression_ + != com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance()) { + segmentParameterFilterExpression_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.newBuilder( + segmentParameterFilterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + segmentParameterFilterExpression_ = value; + } + onChanged(); + } else { + segmentParameterFilterExpressionBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + public Builder clearSegmentParameterFilterExpression() { + if (segmentParameterFilterExpressionBuilder_ == null) { + segmentParameterFilterExpression_ = null; + onChanged(); + } else { + segmentParameterFilterExpressionBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + getSegmentParameterFilterExpressionBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return getSegmentParameterFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getSegmentParameterFilterExpressionOrBuilder() { + if (segmentParameterFilterExpressionBuilder_ != null) { + return segmentParameterFilterExpressionBuilder_.getMessageOrBuilder(); + } else { + return segmentParameterFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance() + : segmentParameterFilterExpression_; + } + } + /** + * + * + *
+     * If specified, this filter matches events that match both the single event
+     * name and the parameter filter expressions.
+     * Inside the parameter filter expression, only parameter filters are
+     * available.
+     * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + getSegmentParameterFilterExpressionFieldBuilder() { + if (segmentParameterFilterExpressionBuilder_ == null) { + segmentParameterFilterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder>( + getSegmentParameterFilterExpression(), getParentForChildren(), isClean()); + segmentParameterFilterExpression_ = null; + } + return segmentParameterFilterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentEventFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentEventFilter) + private static final com.google.analytics.data.v1alpha.SegmentEventFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentEventFilter(); + } + + public static com.google.analytics.data.v1alpha.SegmentEventFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentEventFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentEventFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentEventFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilterOrBuilder.java new file mode 100644 index 00000000..2b3e0e89 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentEventFilterOrBuilder.java @@ -0,0 +1,117 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentEventFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentEventFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return Whether the eventName field is set. + */ + boolean hasEventName(); + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The eventName. + */ + java.lang.String getEventName(); + /** + * + * + *
+   * This filter matches events of this single event name. Event name is
+   * required.
+   * 
+ * + * optional string event_name = 1; + * + * @return The bytes for eventName. + */ + com.google.protobuf.ByteString getEventNameBytes(); + + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + * + * @return Whether the segmentParameterFilterExpression field is set. + */ + boolean hasSegmentParameterFilterExpression(); + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + * + * @return The segmentParameterFilterExpression. + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + getSegmentParameterFilterExpression(); + /** + * + * + *
+   * If specified, this filter matches events that match both the single event
+   * name and the parameter filter expressions.
+   * Inside the parameter filter expression, only parameter filters are
+   * available.
+   * 
+ * + * + * optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getSegmentParameterFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilter.java new file mode 100644 index 00000000..fc4cec18 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilter.java @@ -0,0 +1,2225 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * An expression to filter dimension or metric values.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilter} + */ +public final class SegmentFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentFilter) + SegmentFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentFilter.newBuilder() to construct. + private SegmentFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentFilter() { + fieldName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + + fieldName_ = s; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.StringFilter.Builder subBuilder = null; + if (oneFilterCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.StringFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.StringFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.InListFilter.Builder subBuilder = null; + if (oneFilterCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.InListFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.InListFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 5; + break; + } + case 50: + { + com.google.analytics.data.v1alpha.NumericFilter.Builder subBuilder = null; + if (oneFilterCase_ == 6) { + subBuilder = + ((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 6; + break; + } + case 58: + { + com.google.analytics.data.v1alpha.BetweenFilter.Builder subBuilder = null; + if (oneFilterCase_ == 7) { + subBuilder = + ((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.BetweenFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 7; + break; + } + case 66: + { + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder subBuilder = null; + if (filterScoping_ != null) { + subBuilder = filterScoping_.toBuilder(); + } + filterScoping_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterScoping.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(filterScoping_); + filterScoping_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilter.class, + com.google.analytics.data.v1alpha.SegmentFilter.Builder.class); + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public enum OneFilterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + STRING_FILTER(4), + IN_LIST_FILTER(5), + NUMERIC_FILTER(6), + BETWEEN_FILTER(7), + ONEFILTER_NOT_SET(0); + private final int value; + + private OneFilterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneFilterCase valueOf(int value) { + return forNumber(value); + } + + public static OneFilterCase forNumber(int value) { + switch (value) { + case 4: + return STRING_FILTER; + case 5: + return IN_LIST_FILTER; + case 6: + return NUMERIC_FILTER; + case 7: + return BETWEEN_FILTER; + case 0: + return ONEFILTER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public static final int FIELD_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object fieldName_; + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + @java.lang.Override + public java.lang.String getFieldName() { + java.lang.Object ref = fieldName_; + 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(); + fieldName_ = s; + return s; + } + } + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFieldNameBytes() { + java.lang.Object ref = fieldName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STRING_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + + public static final int IN_LIST_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + + public static final int NUMERIC_FILTER_FIELD_NUMBER = 6; + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + + public static final int BETWEEN_FILTER_FIELD_NUMBER = 7; + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + + public static final int FILTER_SCOPING_FIELD_NUMBER = 8; + private com.google.analytics.data.v1alpha.SegmentFilterScoping filterScoping_; + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * + * @return Whether the filterScoping field is set. + */ + @java.lang.Override + public boolean hasFilterScoping() { + return filterScoping_ != null; + } + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * + * @return The filterScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterScoping getFilterScoping() { + return filterScoping_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterScoping.getDefaultInstance() + : filterScoping_; + } + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder + getFilterScopingOrBuilder() { + return getFilterScoping(); + } + + 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.GeneratedMessageV3.isStringEmpty(fieldName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, fieldName_); + } + if (oneFilterCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + output.writeMessage(6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + output.writeMessage(7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + if (filterScoping_ != null) { + output.writeMessage(8, getFilterScoping()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(fieldName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, fieldName_); + } + if (oneFilterCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + if (filterScoping_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getFilterScoping()); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentFilter other = + (com.google.analytics.data.v1alpha.SegmentFilter) obj; + + if (!getFieldName().equals(other.getFieldName())) return false; + if (hasFilterScoping() != other.hasFilterScoping()) return false; + if (hasFilterScoping()) { + if (!getFilterScoping().equals(other.getFilterScoping())) return false; + } + if (!getOneFilterCase().equals(other.getOneFilterCase())) return false; + switch (oneFilterCase_) { + case 4: + if (!getStringFilter().equals(other.getStringFilter())) return false; + break; + case 5: + if (!getInListFilter().equals(other.getInListFilter())) return false; + break; + case 6: + if (!getNumericFilter().equals(other.getNumericFilter())) return false; + break; + case 7: + if (!getBetweenFilter().equals(other.getBetweenFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + FIELD_NAME_FIELD_NUMBER; + hash = (53 * hash) + getFieldName().hashCode(); + if (hasFilterScoping()) { + hash = (37 * hash) + FILTER_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + getFilterScoping().hashCode(); + } + switch (oneFilterCase_) { + case 4: + hash = (37 * hash) + STRING_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getStringFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + IN_LIST_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getInListFilter().hashCode(); + break; + case 6: + hash = (37 * hash) + NUMERIC_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getNumericFilter().hashCode(); + break; + case 7: + hash = (37 * hash) + BETWEEN_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getBetweenFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter 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.analytics.data.v1alpha.SegmentFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * An expression to filter dimension or metric values.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentFilter) + com.google.analytics.data.v1alpha.SegmentFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilter.class, + com.google.analytics.data.v1alpha.SegmentFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + fieldName_ = ""; + + if (filterScopingBuilder_ == null) { + filterScoping_ = null; + } else { + filterScoping_ = null; + filterScopingBuilder_ = null; + } + oneFilterCase_ = 0; + oneFilter_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilter build() { + com.google.analytics.data.v1alpha.SegmentFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilter buildPartial() { + com.google.analytics.data.v1alpha.SegmentFilter result = + new com.google.analytics.data.v1alpha.SegmentFilter(this); + result.fieldName_ = fieldName_; + if (oneFilterCase_ == 4) { + if (stringFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = stringFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 5) { + if (inListFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = inListFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 6) { + if (numericFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = numericFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 7) { + if (betweenFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = betweenFilterBuilder_.build(); + } + } + if (filterScopingBuilder_ == null) { + result.filterScoping_ = filterScoping_; + } else { + result.filterScoping_ = filterScopingBuilder_.build(); + } + result.oneFilterCase_ = oneFilterCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SegmentFilter other) { + if (other == com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance()) + return this; + if (!other.getFieldName().isEmpty()) { + fieldName_ = other.fieldName_; + onChanged(); + } + if (other.hasFilterScoping()) { + mergeFilterScoping(other.getFilterScoping()); + } + switch (other.getOneFilterCase()) { + case STRING_FILTER: + { + mergeStringFilter(other.getStringFilter()); + break; + } + case IN_LIST_FILTER: + { + mergeInListFilter(other.getInListFilter()); + break; + } + case NUMERIC_FILTER: + { + mergeNumericFilter(other.getNumericFilter()); + break; + } + case BETWEEN_FILTER: + { + mergeBetweenFilter(other.getBetweenFilter()); + break; + } + case ONEFILTER_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.SegmentFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public Builder clearOneFilter() { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + return this; + } + + private java.lang.Object fieldName_ = ""; + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + public java.lang.String getFieldName() { + java.lang.Object ref = fieldName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + fieldName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + public com.google.protobuf.ByteString getFieldNameBytes() { + java.lang.Object ref = fieldName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @param value The fieldName to set. + * @return This builder for chaining. + */ + public Builder setFieldName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + fieldName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearFieldName() { + + fieldName_ = getDefaultInstance().getFieldName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The dimension name or metric name.
+     * 
+ * + * string field_name = 1; + * + * @param value The bytes for fieldName to set. + * @return This builder for chaining. + */ + public Builder setFieldNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + fieldName_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + stringFilterBuilder_; + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 4) { + return stringFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + stringFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter( + com.google.analytics.data.v1alpha.StringFilter.Builder builderForValue) { + if (stringFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + stringFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder mergeStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4 + && oneFilter_ != com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.StringFilter.newBuilder( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 4) { + stringFilterBuilder_.mergeFrom(value); + } else { + stringFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder clearStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + stringFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public com.google.analytics.data.v1alpha.StringFilter.Builder getStringFilterBuilder() { + return getStringFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if ((oneFilterCase_ == 4) && (stringFilterBuilder_ != null)) { + return stringFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + getStringFilterFieldBuilder() { + if (stringFilterBuilder_ == null) { + if (!(oneFilterCase_ == 4)) { + oneFilter_ = com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + stringFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder>( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 4; + onChanged(); + ; + return stringFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + inListFilterBuilder_; + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 5) { + return inListFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + inListFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter( + com.google.analytics.data.v1alpha.InListFilter.Builder builderForValue) { + if (inListFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + inListFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder mergeInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5 + && oneFilter_ != com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.InListFilter.newBuilder( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 5) { + inListFilterBuilder_.mergeFrom(value); + } else { + inListFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder clearInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + inListFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public com.google.analytics.data.v1alpha.InListFilter.Builder getInListFilterBuilder() { + return getInListFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if ((oneFilterCase_ == 5) && (inListFilterBuilder_ != null)) { + return inListFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + getInListFilterFieldBuilder() { + if (inListFilterBuilder_ == null) { + if (!(oneFilterCase_ == 5)) { + oneFilter_ = com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + inListFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder>( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 5; + onChanged(); + ; + return inListFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + numericFilterBuilder_; + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 6) { + return numericFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + numericFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter( + com.google.analytics.data.v1alpha.NumericFilter.Builder builderForValue) { + if (numericFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + numericFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder mergeNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6 + && oneFilter_ != com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.NumericFilter.newBuilder( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 6) { + numericFilterBuilder_.mergeFrom(value); + } else { + numericFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder clearNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + numericFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public com.google.analytics.data.v1alpha.NumericFilter.Builder getNumericFilterBuilder() { + return getNumericFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if ((oneFilterCase_ == 6) && (numericFilterBuilder_ != null)) { + return numericFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + getNumericFilterFieldBuilder() { + if (numericFilterBuilder_ == null) { + if (!(oneFilterCase_ == 6)) { + oneFilter_ = com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + numericFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder>( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 6; + onChanged(); + ; + return numericFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + betweenFilterBuilder_; + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 7) { + return betweenFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + betweenFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter( + com.google.analytics.data.v1alpha.BetweenFilter.Builder builderForValue) { + if (betweenFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + betweenFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder mergeBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7 + && oneFilter_ != com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.BetweenFilter.newBuilder( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 7) { + betweenFilterBuilder_.mergeFrom(value); + } else { + betweenFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder clearBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + betweenFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public com.google.analytics.data.v1alpha.BetweenFilter.Builder getBetweenFilterBuilder() { + return getBetweenFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if ((oneFilterCase_ == 7) && (betweenFilterBuilder_ != null)) { + return betweenFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + getBetweenFilterFieldBuilder() { + if (betweenFilterBuilder_ == null) { + if (!(oneFilterCase_ == 7)) { + oneFilter_ = com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + betweenFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder>( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 7; + onChanged(); + ; + return betweenFilterBuilder_; + } + + private com.google.analytics.data.v1alpha.SegmentFilterScoping filterScoping_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterScoping, + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder, + com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder> + filterScopingBuilder_; + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * + * @return Whether the filterScoping field is set. + */ + public boolean hasFilterScoping() { + return filterScopingBuilder_ != null || filterScoping_ != null; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * + * @return The filterScoping. + */ + public com.google.analytics.data.v1alpha.SegmentFilterScoping getFilterScoping() { + if (filterScopingBuilder_ == null) { + return filterScoping_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterScoping.getDefaultInstance() + : filterScoping_; + } else { + return filterScopingBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + public Builder setFilterScoping(com.google.analytics.data.v1alpha.SegmentFilterScoping value) { + if (filterScopingBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + filterScoping_ = value; + onChanged(); + } else { + filterScopingBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + public Builder setFilterScoping( + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder builderForValue) { + if (filterScopingBuilder_ == null) { + filterScoping_ = builderForValue.build(); + onChanged(); + } else { + filterScopingBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + public Builder mergeFilterScoping( + com.google.analytics.data.v1alpha.SegmentFilterScoping value) { + if (filterScopingBuilder_ == null) { + if (filterScoping_ != null) { + filterScoping_ = + com.google.analytics.data.v1alpha.SegmentFilterScoping.newBuilder(filterScoping_) + .mergeFrom(value) + .buildPartial(); + } else { + filterScoping_ = value; + } + onChanged(); + } else { + filterScopingBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + public Builder clearFilterScoping() { + if (filterScopingBuilder_ == null) { + filterScoping_ = null; + onChanged(); + } else { + filterScoping_ = null; + filterScopingBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + public com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder + getFilterScopingBuilder() { + + onChanged(); + return getFilterScopingFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + public com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder + getFilterScopingOrBuilder() { + if (filterScopingBuilder_ != null) { + return filterScopingBuilder_.getMessageOrBuilder(); + } else { + return filterScoping_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterScoping.getDefaultInstance() + : filterScoping_; + } + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterScoping, + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder, + com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder> + getFilterScopingFieldBuilder() { + if (filterScopingBuilder_ == null) { + filterScopingBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterScoping, + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder, + com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder>( + getFilterScoping(), getParentForChildren(), isClean()); + filterScoping_ = null; + } + return filterScopingBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentFilter) + private static final com.google.analytics.data.v1alpha.SegmentFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentFilter(); + } + + public static com.google.analytics.data.v1alpha.SegmentFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpression.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpression.java new file mode 100644 index 00000000..1bec940c --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpression.java @@ -0,0 +1,2144 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Expresses combinations of segment filters.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilterExpression} + */ +public final class SegmentFilterExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentFilterExpression) + SegmentFilterExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentFilterExpression.newBuilder() to construct. + private SegmentFilterExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentFilterExpression() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentFilterExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentFilterExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder subBuilder = + null; + if (exprCase_ == 1) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 1; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder subBuilder = + null; + if (exprCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder subBuilder = null; + if (exprCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.SegmentFilter.Builder subBuilder = null; + if (exprCase_ == 4) { + subBuilder = ((com.google.analytics.data.v1alpha.SegmentFilter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.SegmentFilter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder subBuilder = null; + if (exprCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentEventFilter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentEventFilter.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.SegmentEventFilter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 5; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilterExpression.class, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder.class); + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public enum ExprCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AND_GROUP(1), + OR_GROUP(2), + NOT_EXPRESSION(3), + SEGMENT_FILTER(4), + SEGMENT_EVENT_FILTER(5), + EXPR_NOT_SET(0); + private final int value; + + private ExprCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ExprCase valueOf(int value) { + return forNumber(value); + } + + public static ExprCase forNumber(int value) { + switch (value) { + case 1: + return AND_GROUP; + case 2: + return OR_GROUP; + case 3: + return NOT_EXPRESSION; + case 4: + return SEGMENT_FILTER; + case 5: + return SEGMENT_EVENT_FILTER; + case 0: + return EXPR_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public static final int AND_GROUP_FIELD_NUMBER = 1; + /** + * + * + *
+   * The SegmentFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+   * The SegmentFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList getAndGroup() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + /** + * + * + *
+   * The SegmentFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + + public static final int OR_GROUP_FIELD_NUMBER = 2; + /** + * + * + *
+   * The SegmentFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+   * The SegmentFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList getOrGroup() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + /** + * + * + *
+   * The SegmentFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + + public static final int NOT_EXPRESSION_FIELD_NUMBER = 3; + /** + * + * + *
+   * The SegmentFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+   * The SegmentFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getNotExpression() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } + /** + * + * + *
+   * The SegmentFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } + + public static final int SEGMENT_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * A primitive segment filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * + * @return Whether the segmentFilter field is set. + */ + @java.lang.Override + public boolean hasSegmentFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+   * A primitive segment filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * + * @return The segmentFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilter getSegmentFilter() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A primitive segment filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterOrBuilder getSegmentFilterOrBuilder() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } + + public static final int SEGMENT_EVENT_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * + * @return Whether the segmentEventFilter field is set. + */ + @java.lang.Override + public boolean hasSegmentEventFilter() { + return exprCase_ == 5; + } + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * + * @return The segmentEventFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilter getSegmentEventFilter() { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder + getSegmentEventFilterOrBuilder() { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } + + 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 (exprCase_ == 1) { + output.writeMessage(1, (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + output.writeMessage(2, (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + output.writeMessage(3, (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_); + } + if (exprCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.SegmentFilter) expr_); + } + if (exprCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (exprCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_); + } + if (exprCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.SegmentFilter) expr_); + } + if (exprCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentFilterExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentFilterExpression other = + (com.google.analytics.data.v1alpha.SegmentFilterExpression) obj; + + if (!getExprCase().equals(other.getExprCase())) return false; + switch (exprCase_) { + case 1: + if (!getAndGroup().equals(other.getAndGroup())) return false; + break; + case 2: + if (!getOrGroup().equals(other.getOrGroup())) return false; + break; + case 3: + if (!getNotExpression().equals(other.getNotExpression())) return false; + break; + case 4: + if (!getSegmentFilter().equals(other.getSegmentFilter())) return false; + break; + case 5: + if (!getSegmentEventFilter().equals(other.getSegmentEventFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (exprCase_) { + case 1: + hash = (37 * hash) + AND_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getAndGroup().hashCode(); + break; + case 2: + hash = (37 * hash) + OR_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getOrGroup().hashCode(); + break; + case 3: + hash = (37 * hash) + NOT_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getNotExpression().hashCode(); + break; + case 4: + hash = (37 * hash) + SEGMENT_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getSegmentFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + SEGMENT_EVENT_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getSegmentEventFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression 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.analytics.data.v1alpha.SegmentFilterExpression parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentFilterExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Expresses combinations of segment filters.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilterExpression} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentFilterExpression) + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilterExpression.class, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentFilterExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + exprCase_ = 0; + expr_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression build() { + com.google.analytics.data.v1alpha.SegmentFilterExpression result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression buildPartial() { + com.google.analytics.data.v1alpha.SegmentFilterExpression result = + new com.google.analytics.data.v1alpha.SegmentFilterExpression(this); + if (exprCase_ == 1) { + if (andGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = andGroupBuilder_.build(); + } + } + if (exprCase_ == 2) { + if (orGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = orGroupBuilder_.build(); + } + } + if (exprCase_ == 3) { + if (notExpressionBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = notExpressionBuilder_.build(); + } + } + if (exprCase_ == 4) { + if (segmentFilterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = segmentFilterBuilder_.build(); + } + } + if (exprCase_ == 5) { + if (segmentEventFilterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = segmentEventFilterBuilder_.build(); + } + } + result.exprCase_ = exprCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentFilterExpression) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentFilterExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SegmentFilterExpression other) { + if (other == com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance()) + return this; + switch (other.getExprCase()) { + case AND_GROUP: + { + mergeAndGroup(other.getAndGroup()); + break; + } + case OR_GROUP: + { + mergeOrGroup(other.getOrGroup()); + break; + } + case NOT_EXPRESSION: + { + mergeNotExpression(other.getNotExpression()); + break; + } + case SEGMENT_FILTER: + { + mergeSegmentFilter(other.getSegmentFilter()); + break; + } + case SEGMENT_EVENT_FILTER: + { + mergeSegmentEventFilter(other.getSegmentEventFilter()); + break; + } + case EXPR_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentFilterExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentFilterExpression) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public Builder clearExpr() { + exprCase_ = 0; + expr_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder> + andGroupBuilder_; + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList getAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } else { + if (exprCase_ == 1) { + return andGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + andGroupBuilder_.setMessage(value); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder builderForValue) { + if (andGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + andGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + public Builder mergeAndGroup( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1 + && expr_ + != com.google.analytics.data.v1alpha.SegmentFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 1) { + andGroupBuilder_.mergeFrom(value); + } else { + andGroupBuilder_.setMessage(value); + } + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + public Builder clearAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + } + andGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder + getAndGroupBuilder() { + return getAndGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if ((exprCase_ == 1) && (andGroupBuilder_ != null)) { + return andGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentFilterExpression in `andGroup` have an AND relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder> + getAndGroupFieldBuilder() { + if (andGroupBuilder_ == null) { + if (!(exprCase_ == 1)) { + expr_ = + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + andGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 1; + onChanged(); + ; + return andGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder> + orGroupBuilder_; + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList getOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } else { + if (exprCase_ == 2) { + return orGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + public Builder setOrGroup(com.google.analytics.data.v1alpha.SegmentFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + orGroupBuilder_.setMessage(value); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder builderForValue) { + if (orGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + orGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + public Builder mergeOrGroup( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2 + && expr_ + != com.google.analytics.data.v1alpha.SegmentFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 2) { + orGroupBuilder_.mergeFrom(value); + } else { + orGroupBuilder_.setMessage(value); + } + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + public Builder clearOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + } + orGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder + getOrGroupBuilder() { + return getOrGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if ((exprCase_ == 2) && (orGroupBuilder_ != null)) { + return orGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentFilterExpression in `orGroup` have an OR relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder> + getOrGroupFieldBuilder() { + if (orGroupBuilder_ == null) { + if (!(exprCase_ == 2)) { + expr_ = + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + orGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 2; + onChanged(); + ; + return orGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + notExpressionBuilder_; + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } else { + if (exprCase_ == 3) { + return notExpressionBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + notExpressionBuilder_.setMessage(value); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (notExpressionBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + notExpressionBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + public Builder mergeNotExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3 + && expr_ + != com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentFilterExpression.newBuilder( + (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 3) { + notExpressionBuilder_.mergeFrom(value); + } else { + notExpressionBuilder_.setMessage(value); + } + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + public Builder clearNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + } + notExpressionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder + getNotExpressionBuilder() { + return getNotExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if ((exprCase_ == 3) && (notExpressionBuilder_ != null)) { + return notExpressionBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getNotExpressionFieldBuilder() { + if (notExpressionBuilder_ == null) { + if (!(exprCase_ == 3)) { + expr_ = com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance(); + } + notExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentFilterExpression) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 3; + onChanged(); + ; + return notExpressionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilter, + com.google.analytics.data.v1alpha.SegmentFilter.Builder, + com.google.analytics.data.v1alpha.SegmentFilterOrBuilder> + segmentFilterBuilder_; + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * + * @return Whether the segmentFilter field is set. + */ + @java.lang.Override + public boolean hasSegmentFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * + * @return The segmentFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilter getSegmentFilter() { + if (segmentFilterBuilder_ == null) { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } else { + if (exprCase_ == 4) { + return segmentFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + public Builder setSegmentFilter(com.google.analytics.data.v1alpha.SegmentFilter value) { + if (segmentFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + segmentFilterBuilder_.setMessage(value); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + public Builder setSegmentFilter( + com.google.analytics.data.v1alpha.SegmentFilter.Builder builderForValue) { + if (segmentFilterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + segmentFilterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + public Builder mergeSegmentFilter(com.google.analytics.data.v1alpha.SegmentFilter value) { + if (segmentFilterBuilder_ == null) { + if (exprCase_ == 4 + && expr_ != com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentFilter.newBuilder( + (com.google.analytics.data.v1alpha.SegmentFilter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 4) { + segmentFilterBuilder_.mergeFrom(value); + } else { + segmentFilterBuilder_.setMessage(value); + } + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + public Builder clearSegmentFilter() { + if (segmentFilterBuilder_ == null) { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + } + segmentFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + public com.google.analytics.data.v1alpha.SegmentFilter.Builder getSegmentFilterBuilder() { + return getSegmentFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterOrBuilder getSegmentFilterOrBuilder() { + if ((exprCase_ == 4) && (segmentFilterBuilder_ != null)) { + return segmentFilterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive segment filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilter, + com.google.analytics.data.v1alpha.SegmentFilter.Builder, + com.google.analytics.data.v1alpha.SegmentFilterOrBuilder> + getSegmentFilterFieldBuilder() { + if (segmentFilterBuilder_ == null) { + if (!(exprCase_ == 4)) { + expr_ = com.google.analytics.data.v1alpha.SegmentFilter.getDefaultInstance(); + } + segmentFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilter, + com.google.analytics.data.v1alpha.SegmentFilter.Builder, + com.google.analytics.data.v1alpha.SegmentFilterOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentFilter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 4; + onChanged(); + ; + return segmentFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentEventFilter, + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder, + com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder> + segmentEventFilterBuilder_; + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * + * @return Whether the segmentEventFilter field is set. + */ + @java.lang.Override + public boolean hasSegmentEventFilter() { + return exprCase_ == 5; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * + * @return The segmentEventFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilter getSegmentEventFilter() { + if (segmentEventFilterBuilder_ == null) { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } else { + if (exprCase_ == 5) { + return segmentEventFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + public Builder setSegmentEventFilter( + com.google.analytics.data.v1alpha.SegmentEventFilter value) { + if (segmentEventFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + segmentEventFilterBuilder_.setMessage(value); + } + exprCase_ = 5; + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + public Builder setSegmentEventFilter( + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder builderForValue) { + if (segmentEventFilterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + segmentEventFilterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 5; + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + public Builder mergeSegmentEventFilter( + com.google.analytics.data.v1alpha.SegmentEventFilter value) { + if (segmentEventFilterBuilder_ == null) { + if (exprCase_ == 5 + && expr_ != com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentEventFilter.newBuilder( + (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 5) { + segmentEventFilterBuilder_.mergeFrom(value); + } else { + segmentEventFilterBuilder_.setMessage(value); + } + } + exprCase_ = 5; + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + public Builder clearSegmentEventFilter() { + if (segmentEventFilterBuilder_ == null) { + if (exprCase_ == 5) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 5) { + exprCase_ = 0; + expr_ = null; + } + segmentEventFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + public com.google.analytics.data.v1alpha.SegmentEventFilter.Builder + getSegmentEventFilterBuilder() { + return getSegmentEventFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder + getSegmentEventFilterOrBuilder() { + if ((exprCase_ == 5) && (segmentEventFilterBuilder_ != null)) { + return segmentEventFilterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 5) { + return (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Creates a filter that matches events of a single event name. If a
+     * parameter filter expression is specified, only the subset of events that
+     * match both the single event name and the parameter filter expressions
+     * match this event filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentEventFilter, + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder, + com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder> + getSegmentEventFilterFieldBuilder() { + if (segmentEventFilterBuilder_ == null) { + if (!(exprCase_ == 5)) { + expr_ = com.google.analytics.data.v1alpha.SegmentEventFilter.getDefaultInstance(); + } + segmentEventFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentEventFilter, + com.google.analytics.data.v1alpha.SegmentEventFilter.Builder, + com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentEventFilter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 5; + onChanged(); + ; + return segmentEventFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentFilterExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentFilterExpression) + private static final com.google.analytics.data.v1alpha.SegmentFilterExpression DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentFilterExpression(); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpression getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentFilterExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentFilterExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentFilterExpression getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionList.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionList.java new file mode 100644 index 00000000..a54e845a --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionList.java @@ -0,0 +1,979 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A list of segment filter expressions.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilterExpressionList} + */ +public final class SegmentFilterExpressionList extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentFilterExpressionList) + SegmentFilterExpressionListOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentFilterExpressionList.newBuilder() to construct. + private SegmentFilterExpressionList(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentFilterExpressionList() { + expressions_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentFilterExpressionList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentFilterExpressionList( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.SegmentFilterExpression>(); + mutable_bitField0_ |= 0x00000001; + } + expressions_.add( + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpression.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.class, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder.class); + } + + public static final int EXPRESSIONS_FIELD_NUMBER = 1; + private java.util.List expressions_; + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + @java.lang.Override + public java.util.List + getExpressionsList() { + return expressions_; + } + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + return expressions_; + } + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + @java.lang.Override + public int getExpressionsCount() { + return expressions_.size(); + } + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getExpressions(int index) { + return expressions_.get(index); + } + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder getExpressionsOrBuilder( + int index) { + return expressions_.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 < expressions_.size(); i++) { + output.writeMessage(1, expressions_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < expressions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, expressions_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentFilterExpressionList)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentFilterExpressionList other = + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) obj; + + if (!getExpressionsList().equals(other.getExpressionsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExpressionsCount() > 0) { + hash = (37 * hash) + EXPRESSIONS_FIELD_NUMBER; + hash = (53 * hash) + getExpressionsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList 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.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentFilterExpressionList 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A list of segment filter expressions.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilterExpressionList} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentFilterExpressionList) + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.class, + com.google.analytics.data.v1alpha.SegmentFilterExpressionList.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentFilterExpressionList.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExpressionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + expressionsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterExpressionList_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList build() { + com.google.analytics.data.v1alpha.SegmentFilterExpressionList result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionList buildPartial() { + com.google.analytics.data.v1alpha.SegmentFilterExpressionList result = + new com.google.analytics.data.v1alpha.SegmentFilterExpressionList(this); + int from_bitField0_ = bitField0_; + if (expressionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.expressions_ = expressions_; + } else { + result.expressions_ = expressionsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentFilterExpressionList) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentFilterExpressionList) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SegmentFilterExpressionList other) { + if (other + == com.google.analytics.data.v1alpha.SegmentFilterExpressionList.getDefaultInstance()) + return this; + if (expressionsBuilder_ == null) { + if (!other.expressions_.isEmpty()) { + if (expressions_.isEmpty()) { + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExpressionsIsMutable(); + expressions_.addAll(other.expressions_); + } + onChanged(); + } + } else { + if (!other.expressions_.isEmpty()) { + if (expressionsBuilder_.isEmpty()) { + expressionsBuilder_.dispose(); + expressionsBuilder_ = null; + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + expressionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExpressionsFieldBuilder() + : null; + } else { + expressionsBuilder_.addAllMessages(other.expressions_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentFilterExpressionList parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentFilterExpressionList) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List expressions_ = + java.util.Collections.emptyList(); + + private void ensureExpressionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList( + expressions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + expressionsBuilder_; + + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public java.util.List + getExpressionsList() { + if (expressionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(expressions_); + } else { + return expressionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public int getExpressionsCount() { + if (expressionsBuilder_ == null) { + return expressions_.size(); + } else { + return expressionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression getExpressions(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder setExpressions( + int index, com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.set(index, value); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder setExpressions( + int index, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.set(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder addExpressions(com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(value); + onChanged(); + } else { + expressionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder addExpressions( + int index, com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(index, value); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder addExpressions( + int index, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder addAllExpressions( + java.lang.Iterable + values) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, expressions_); + onChanged(); + } else { + expressionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder clearExpressions() { + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + expressionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public Builder removeExpressions(int index) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.remove(index); + onChanged(); + } else { + expressionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder getExpressionsBuilder( + int index) { + return getExpressionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getExpressionsOrBuilder(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + if (expressionsBuilder_ != null) { + return expressionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(expressions_); + } + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder + addExpressionsBuilder() { + return getExpressionsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance()); + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder addExpressionsBuilder( + int index) { + return getExpressionsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance()); + } + /** + * + * + *
+     * The list of segment filter expressions
+     * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + public java.util.List + getExpressionsBuilderList() { + return getExpressionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getExpressionsFieldBuilder() { + if (expressionsBuilder_ == null) { + expressionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder>( + expressions_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + expressions_ = null; + } + return expressionsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentFilterExpressionList) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentFilterExpressionList) + private static final com.google.analytics.data.v1alpha.SegmentFilterExpressionList + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentFilterExpressionList(); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterExpressionList getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentFilterExpressionList parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentFilterExpressionList(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentFilterExpressionList getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionListOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionListOrBuilder.java new file mode 100644 index 00000000..a8d7c53a --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionListOrBuilder.java @@ -0,0 +1,78 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentFilterExpressionListOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentFilterExpressionList) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + java.util.List getExpressionsList(); + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + com.google.analytics.data.v1alpha.SegmentFilterExpression getExpressions(int index); + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + int getExpressionsCount(); + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + java.util.List + getExpressionsOrBuilderList(); + /** + * + * + *
+   * The list of segment filter expressions
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder getExpressionsOrBuilder( + int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionOrBuilder.java new file mode 100644 index 00000000..0038ca54 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterExpressionOrBuilder.java @@ -0,0 +1,211 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentFilterExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentFilterExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The SegmentFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + boolean hasAndGroup(); + /** + * + * + *
+   * The SegmentFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionList getAndGroup(); + /** + * + * + *
+   * The SegmentFilterExpression in `andGroup` have an AND relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder getAndGroupOrBuilder(); + + /** + * + * + *
+   * The SegmentFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + boolean hasOrGroup(); + /** + * + * + *
+   * The SegmentFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionList getOrGroup(); + /** + * + * + *
+   * The SegmentFilterExpression in `orGroup` have an OR relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionListOrBuilder getOrGroupOrBuilder(); + + /** + * + * + *
+   * The SegmentFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * + * @return Whether the notExpression field is set. + */ + boolean hasNotExpression(); + /** + * + * + *
+   * The SegmentFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * + * @return The notExpression. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpression getNotExpression(); + /** + * + * + *
+   * The SegmentFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder getNotExpressionOrBuilder(); + + /** + * + * + *
+   * A primitive segment filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * + * @return Whether the segmentFilter field is set. + */ + boolean hasSegmentFilter(); + /** + * + * + *
+   * A primitive segment filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * + * @return The segmentFilter. + */ + com.google.analytics.data.v1alpha.SegmentFilter getSegmentFilter(); + /** + * + * + *
+   * A primitive segment filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + */ + com.google.analytics.data.v1alpha.SegmentFilterOrBuilder getSegmentFilterOrBuilder(); + + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * + * @return Whether the segmentEventFilter field is set. + */ + boolean hasSegmentEventFilter(); + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * + * @return The segmentEventFilter. + */ + com.google.analytics.data.v1alpha.SegmentEventFilter getSegmentEventFilter(); + /** + * + * + *
+   * Creates a filter that matches events of a single event name. If a
+   * parameter filter expression is specified, only the subset of events that
+   * match both the single event name and the parameter filter expressions
+   * match this event filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + */ + com.google.analytics.data.v1alpha.SegmentEventFilterOrBuilder getSegmentEventFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.SegmentFilterExpression.ExprCase getExprCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterOrBuilder.java new file mode 100644 index 00000000..1a1f1f18 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterOrBuilder.java @@ -0,0 +1,227 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The fieldName. + */ + java.lang.String getFieldName(); + /** + * + * + *
+   * The dimension name or metric name.
+   * 
+ * + * string field_name = 1; + * + * @return The bytes for fieldName. + */ + com.google.protobuf.ByteString getFieldNameBytes(); + + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + boolean hasStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + com.google.analytics.data.v1alpha.StringFilter getStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder(); + + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + boolean hasInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + com.google.analytics.data.v1alpha.InListFilter getInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder(); + + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + boolean hasNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + com.google.analytics.data.v1alpha.NumericFilter getNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder(); + + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + boolean hasBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder(); + + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * + * @return Whether the filterScoping field is set. + */ + boolean hasFilterScoping(); + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * + * @return The filterScoping. + */ + com.google.analytics.data.v1alpha.SegmentFilterScoping getFilterScoping(); + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder getFilterScopingOrBuilder(); + + public com.google.analytics.data.v1alpha.SegmentFilter.OneFilterCase getOneFilterCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScoping.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScoping.java new file mode 100644 index 00000000..2aa3bf96 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScoping.java @@ -0,0 +1,657 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Scopings specify how the dimensions & metrics of multiple events
+ * should be considered when evaluating a segment filter.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilterScoping} + */ +public final class SegmentFilterScoping extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentFilterScoping) + SegmentFilterScopingOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentFilterScoping.newBuilder() to construct. + private SegmentFilterScoping(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentFilterScoping() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentFilterScoping(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentFilterScoping( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + bitField0_ |= 0x00000001; + atAnyPointInTime_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilterScoping.class, + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder.class); + } + + private int bitField0_; + public static final int AT_ANY_POINT_IN_TIME_FIELD_NUMBER = 1; + private boolean atAnyPointInTime_; + /** + * + * + *
+   * If `atAnyPointInTime` is true, this filter evaluates to true for all
+   * events if it evaluates to true for any event in the date range of the
+   * request.
+   * This `atAnyPointInTime` parameter does not extend the date range of
+   * events in the report. If `atAnyPointInTime` is true, only events within
+   * the report's date range are considered when evaluating this filter.
+   * This `atAnyPointInTime` is only able to be specified if the criteria
+   * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+   * sequences.
+   * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+   * false is used if unspecified.
+   * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return Whether the atAnyPointInTime field is set. + */ + @java.lang.Override + public boolean hasAtAnyPointInTime() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * If `atAnyPointInTime` is true, this filter evaluates to true for all
+   * events if it evaluates to true for any event in the date range of the
+   * request.
+   * This `atAnyPointInTime` parameter does not extend the date range of
+   * events in the report. If `atAnyPointInTime` is true, only events within
+   * the report's date range are considered when evaluating this filter.
+   * This `atAnyPointInTime` is only able to be specified if the criteria
+   * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+   * sequences.
+   * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+   * false is used if unspecified.
+   * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return The atAnyPointInTime. + */ + @java.lang.Override + public boolean getAtAnyPointInTime() { + return atAnyPointInTime_; + } + + 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.writeBool(1, atAnyPointInTime_); + } + unknownFields.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.computeBoolSize(1, atAnyPointInTime_); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentFilterScoping)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentFilterScoping other = + (com.google.analytics.data.v1alpha.SegmentFilterScoping) obj; + + if (hasAtAnyPointInTime() != other.hasAtAnyPointInTime()) return false; + if (hasAtAnyPointInTime()) { + if (getAtAnyPointInTime() != other.getAtAnyPointInTime()) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasAtAnyPointInTime()) { + hash = (37 * hash) + AT_ANY_POINT_IN_TIME_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAtAnyPointInTime()); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping 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.analytics.data.v1alpha.SegmentFilterScoping parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentFilterScoping 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Scopings specify how the dimensions & metrics of multiple events
+   * should be considered when evaluating a segment filter.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentFilterScoping} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentFilterScoping) + com.google.analytics.data.v1alpha.SegmentFilterScopingOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentFilterScoping.class, + com.google.analytics.data.v1alpha.SegmentFilterScoping.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentFilterScoping.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + atAnyPointInTime_ = false; + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentFilterScoping_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterScoping getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentFilterScoping.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterScoping build() { + com.google.analytics.data.v1alpha.SegmentFilterScoping result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterScoping buildPartial() { + com.google.analytics.data.v1alpha.SegmentFilterScoping result = + new com.google.analytics.data.v1alpha.SegmentFilterScoping(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.atAnyPointInTime_ = atAnyPointInTime_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentFilterScoping) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentFilterScoping) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SegmentFilterScoping other) { + if (other == com.google.analytics.data.v1alpha.SegmentFilterScoping.getDefaultInstance()) + return this; + if (other.hasAtAnyPointInTime()) { + setAtAnyPointInTime(other.getAtAnyPointInTime()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentFilterScoping parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentFilterScoping) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private boolean atAnyPointInTime_; + /** + * + * + *
+     * If `atAnyPointInTime` is true, this filter evaluates to true for all
+     * events if it evaluates to true for any event in the date range of the
+     * request.
+     * This `atAnyPointInTime` parameter does not extend the date range of
+     * events in the report. If `atAnyPointInTime` is true, only events within
+     * the report's date range are considered when evaluating this filter.
+     * This `atAnyPointInTime` is only able to be specified if the criteria
+     * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+     * sequences.
+     * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+     * false is used if unspecified.
+     * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return Whether the atAnyPointInTime field is set. + */ + @java.lang.Override + public boolean hasAtAnyPointInTime() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * If `atAnyPointInTime` is true, this filter evaluates to true for all
+     * events if it evaluates to true for any event in the date range of the
+     * request.
+     * This `atAnyPointInTime` parameter does not extend the date range of
+     * events in the report. If `atAnyPointInTime` is true, only events within
+     * the report's date range are considered when evaluating this filter.
+     * This `atAnyPointInTime` is only able to be specified if the criteria
+     * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+     * sequences.
+     * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+     * false is used if unspecified.
+     * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return The atAnyPointInTime. + */ + @java.lang.Override + public boolean getAtAnyPointInTime() { + return atAnyPointInTime_; + } + /** + * + * + *
+     * If `atAnyPointInTime` is true, this filter evaluates to true for all
+     * events if it evaluates to true for any event in the date range of the
+     * request.
+     * This `atAnyPointInTime` parameter does not extend the date range of
+     * events in the report. If `atAnyPointInTime` is true, only events within
+     * the report's date range are considered when evaluating this filter.
+     * This `atAnyPointInTime` is only able to be specified if the criteria
+     * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+     * sequences.
+     * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+     * false is used if unspecified.
+     * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @param value The atAnyPointInTime to set. + * @return This builder for chaining. + */ + public Builder setAtAnyPointInTime(boolean value) { + bitField0_ |= 0x00000001; + atAnyPointInTime_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If `atAnyPointInTime` is true, this filter evaluates to true for all
+     * events if it evaluates to true for any event in the date range of the
+     * request.
+     * This `atAnyPointInTime` parameter does not extend the date range of
+     * events in the report. If `atAnyPointInTime` is true, only events within
+     * the report's date range are considered when evaluating this filter.
+     * This `atAnyPointInTime` is only able to be specified if the criteria
+     * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+     * sequences.
+     * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+     * false is used if unspecified.
+     * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return This builder for chaining. + */ + public Builder clearAtAnyPointInTime() { + bitField0_ = (bitField0_ & ~0x00000001); + atAnyPointInTime_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentFilterScoping) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentFilterScoping) + private static final com.google.analytics.data.v1alpha.SegmentFilterScoping DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentFilterScoping(); + } + + public static com.google.analytics.data.v1alpha.SegmentFilterScoping getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentFilterScoping parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentFilterScoping(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentFilterScoping getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScopingOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScopingOrBuilder.java new file mode 100644 index 00000000..fd4a67f0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentFilterScopingOrBuilder.java @@ -0,0 +1,70 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentFilterScopingOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentFilterScoping) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * If `atAnyPointInTime` is true, this filter evaluates to true for all
+   * events if it evaluates to true for any event in the date range of the
+   * request.
+   * This `atAnyPointInTime` parameter does not extend the date range of
+   * events in the report. If `atAnyPointInTime` is true, only events within
+   * the report's date range are considered when evaluating this filter.
+   * This `atAnyPointInTime` is only able to be specified if the criteria
+   * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+   * sequences.
+   * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+   * false is used if unspecified.
+   * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return Whether the atAnyPointInTime field is set. + */ + boolean hasAtAnyPointInTime(); + /** + * + * + *
+   * If `atAnyPointInTime` is true, this filter evaluates to true for all
+   * events if it evaluates to true for any event in the date range of the
+   * request.
+   * This `atAnyPointInTime` parameter does not extend the date range of
+   * events in the report. If `atAnyPointInTime` is true, only events within
+   * the report's date range are considered when evaluating this filter.
+   * This `atAnyPointInTime` is only able to be specified if the criteria
+   * scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in
+   * sequences.
+   * If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` =
+   * false is used if unspecified.
+   * 
+ * + * optional bool at_any_point_in_time = 1; + * + * @return The atAnyPointInTime. + */ + boolean getAtAnyPointInTime(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentOrBuilder.java new file mode 100644 index 00000000..bc9e0195 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentOrBuilder.java @@ -0,0 +1,169 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.Segment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The name for this segment. If unspecified, segments are named "Segment".
+   * This name defines string value returned by the `segment` dimension. The
+   * `segment` dimension prefixes segment names by the 1-based index number of
+   * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The name for this segment. If unspecified, segments are named "Segment".
+   * This name defines string value returned by the `segment` dimension. The
+   * `segment` dimension prefixes segment names by the 1-based index number of
+   * the segment in the request (i.e. "1. Segment", "2. Segment", etc.).
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * + * @return Whether the userSegment field is set. + */ + boolean hasUserSegment(); + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * + * @return The userSegment. + */ + com.google.analytics.data.v1alpha.UserSegment getUserSegment(); + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegment user_segment = 2; + */ + com.google.analytics.data.v1alpha.UserSegmentOrBuilder getUserSegmentOrBuilder(); + + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site
+   * or app.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * + * @return Whether the sessionSegment field is set. + */ + boolean hasSessionSegment(); + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site
+   * or app.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * + * @return The sessionSegment. + */ + com.google.analytics.data.v1alpha.SessionSegment getSessionSegment(); + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site
+   * or app.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + */ + com.google.analytics.data.v1alpha.SessionSegmentOrBuilder getSessionSegmentOrBuilder(); + + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or
+   * app.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * + * @return Whether the eventSegment field is set. + */ + boolean hasEventSegment(); + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or
+   * app.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * + * @return The eventSegment. + */ + com.google.analytics.data.v1alpha.EventSegment getEventSegment(); + /** + * + * + *
+   * Event segments are subsets of events that were triggered on your site or
+   * app.
+   * 
+ * + * .google.analytics.data.v1alpha.EventSegment event_segment = 4; + */ + com.google.analytics.data.v1alpha.EventSegmentOrBuilder getEventSegmentOrBuilder(); + + public com.google.analytics.data.v1alpha.Segment.OneSegmentScopeCase getOneSegmentScopeCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilter.java new file mode 100644 index 00000000..7016948b --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilter.java @@ -0,0 +1,2723 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * An expression to filter parameter values in a segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilter} + */ +public final class SegmentParameterFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentParameterFilter) + SegmentParameterFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentParameterFilter.newBuilder() to construct. + private SegmentParameterFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentParameterFilter() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentParameterFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentParameterFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + 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(); + oneParameterCase_ = 1; + oneParameter_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + oneParameterCase_ = 2; + oneParameter_ = s; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.StringFilter.Builder subBuilder = null; + if (oneFilterCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.StringFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.StringFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 4; + break; + } + case 42: + { + com.google.analytics.data.v1alpha.InListFilter.Builder subBuilder = null; + if (oneFilterCase_ == 5) { + subBuilder = + ((com.google.analytics.data.v1alpha.InListFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.InListFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 5; + break; + } + case 50: + { + com.google.analytics.data.v1alpha.NumericFilter.Builder subBuilder = null; + if (oneFilterCase_ == 6) { + subBuilder = + ((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.NumericFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 6; + break; + } + case 58: + { + com.google.analytics.data.v1alpha.BetweenFilter.Builder subBuilder = null; + if (oneFilterCase_ == 7) { + subBuilder = + ((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_).toBuilder(); + } + oneFilter_ = + input.readMessage( + com.google.analytics.data.v1alpha.BetweenFilter.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + oneFilter_ = subBuilder.buildPartial(); + } + oneFilterCase_ = 7; + break; + } + case 66: + { + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder subBuilder = + null; + if (filterScoping_ != null) { + subBuilder = filterScoping_.toBuilder(); + } + filterScoping_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(filterScoping_); + filterScoping_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilter.class, + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder.class); + } + + private int oneParameterCase_ = 0; + private java.lang.Object oneParameter_; + + public enum OneParameterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + EVENT_PARAMETER_NAME(1), + ITEM_PARAMETER_NAME(2), + ONEPARAMETER_NOT_SET(0); + private final int value; + + private OneParameterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneParameterCase valueOf(int value) { + return forNumber(value); + } + + public static OneParameterCase forNumber(int value) { + switch (value) { + case 1: + return EVENT_PARAMETER_NAME; + case 2: + return ITEM_PARAMETER_NAME; + case 0: + return ONEPARAMETER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneParameterCase getOneParameterCase() { + return OneParameterCase.forNumber(oneParameterCase_); + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public enum OneFilterCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + STRING_FILTER(4), + IN_LIST_FILTER(5), + NUMERIC_FILTER(6), + BETWEEN_FILTER(7), + ONEFILTER_NOT_SET(0); + private final int value; + + private OneFilterCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OneFilterCase valueOf(int value) { + return forNumber(value); + } + + public static OneFilterCase forNumber(int value) { + switch (value) { + case 4: + return STRING_FILTER; + case 5: + return IN_LIST_FILTER; + case 6: + return NUMERIC_FILTER; + case 7: + return BETWEEN_FILTER; + case 0: + return ONEFILTER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public static final int EVENT_PARAMETER_NAME_FIELD_NUMBER = 1; + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return Whether the eventParameterName field is set. + */ + public boolean hasEventParameterName() { + return oneParameterCase_ == 1; + } + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The eventParameterName. + */ + public java.lang.String getEventParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + 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(); + if (oneParameterCase_ == 1) { + oneParameter_ = s; + } + return s; + } + } + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The bytes for eventParameterName. + */ + public com.google.protobuf.ByteString getEventParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 1) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ITEM_PARAMETER_NAME_FIELD_NUMBER = 2; + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return Whether the itemParameterName field is set. + */ + public boolean hasItemParameterName() { + return oneParameterCase_ == 2; + } + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The itemParameterName. + */ + public java.lang.String getItemParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + 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(); + if (oneParameterCase_ == 2) { + oneParameter_ = s; + } + return s; + } + } + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The bytes for itemParameterName. + */ + public com.google.protobuf.ByteString getItemParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 2) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STRING_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + + public static final int IN_LIST_FILTER_FIELD_NUMBER = 5; + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + + public static final int NUMERIC_FILTER_FIELD_NUMBER = 6; + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + + public static final int BETWEEN_FILTER_FIELD_NUMBER = 7; + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + + public static final int FILTER_SCOPING_FIELD_NUMBER = 8; + private com.google.analytics.data.v1alpha.SegmentParameterFilterScoping filterScoping_; + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * + * @return Whether the filterScoping field is set. + */ + @java.lang.Override + public boolean hasFilterScoping() { + return filterScoping_ != null; + } + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * + * @return The filterScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterScoping getFilterScoping() { + return filterScoping_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.getDefaultInstance() + : filterScoping_; + } + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder + getFilterScopingOrBuilder() { + return getFilterScoping(); + } + + 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 (oneParameterCase_ == 1) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, oneParameter_); + } + if (oneParameterCase_ == 2) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, oneParameter_); + } + if (oneFilterCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + output.writeMessage(5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + output.writeMessage(6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + output.writeMessage(7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + if (filterScoping_ != null) { + output.writeMessage(8, getFilterScoping()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (oneParameterCase_ == 1) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, oneParameter_); + } + if (oneParameterCase_ == 2) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, oneParameter_); + } + if (oneFilterCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.StringFilter) oneFilter_); + } + if (oneFilterCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.analytics.data.v1alpha.InListFilter) oneFilter_); + } + if (oneFilterCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_); + } + if (oneFilterCase_ == 7) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 7, (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_); + } + if (filterScoping_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getFilterScoping()); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentParameterFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentParameterFilter other = + (com.google.analytics.data.v1alpha.SegmentParameterFilter) obj; + + if (hasFilterScoping() != other.hasFilterScoping()) return false; + if (hasFilterScoping()) { + if (!getFilterScoping().equals(other.getFilterScoping())) return false; + } + if (!getOneParameterCase().equals(other.getOneParameterCase())) return false; + switch (oneParameterCase_) { + case 1: + if (!getEventParameterName().equals(other.getEventParameterName())) return false; + break; + case 2: + if (!getItemParameterName().equals(other.getItemParameterName())) return false; + break; + case 0: + default: + } + if (!getOneFilterCase().equals(other.getOneFilterCase())) return false; + switch (oneFilterCase_) { + case 4: + if (!getStringFilter().equals(other.getStringFilter())) return false; + break; + case 5: + if (!getInListFilter().equals(other.getInListFilter())) return false; + break; + case 6: + if (!getNumericFilter().equals(other.getNumericFilter())) return false; + break; + case 7: + if (!getBetweenFilter().equals(other.getBetweenFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasFilterScoping()) { + hash = (37 * hash) + FILTER_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + getFilterScoping().hashCode(); + } + switch (oneParameterCase_) { + case 1: + hash = (37 * hash) + EVENT_PARAMETER_NAME_FIELD_NUMBER; + hash = (53 * hash) + getEventParameterName().hashCode(); + break; + case 2: + hash = (37 * hash) + ITEM_PARAMETER_NAME_FIELD_NUMBER; + hash = (53 * hash) + getItemParameterName().hashCode(); + break; + case 0: + default: + } + switch (oneFilterCase_) { + case 4: + hash = (37 * hash) + STRING_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getStringFilter().hashCode(); + break; + case 5: + hash = (37 * hash) + IN_LIST_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getInListFilter().hashCode(); + break; + case 6: + hash = (37 * hash) + NUMERIC_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getNumericFilter().hashCode(); + break; + case 7: + hash = (37 * hash) + BETWEEN_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getBetweenFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter 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.analytics.data.v1alpha.SegmentParameterFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentParameterFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * An expression to filter parameter values in a segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentParameterFilter) + com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilter.class, + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentParameterFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (filterScopingBuilder_ == null) { + filterScoping_ = null; + } else { + filterScoping_ = null; + filterScopingBuilder_ = null; + } + oneParameterCase_ = 0; + oneParameter_ = null; + oneFilterCase_ = 0; + oneFilter_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilter build() { + com.google.analytics.data.v1alpha.SegmentParameterFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilter buildPartial() { + com.google.analytics.data.v1alpha.SegmentParameterFilter result = + new com.google.analytics.data.v1alpha.SegmentParameterFilter(this); + if (oneParameterCase_ == 1) { + result.oneParameter_ = oneParameter_; + } + if (oneParameterCase_ == 2) { + result.oneParameter_ = oneParameter_; + } + if (oneFilterCase_ == 4) { + if (stringFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = stringFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 5) { + if (inListFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = inListFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 6) { + if (numericFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = numericFilterBuilder_.build(); + } + } + if (oneFilterCase_ == 7) { + if (betweenFilterBuilder_ == null) { + result.oneFilter_ = oneFilter_; + } else { + result.oneFilter_ = betweenFilterBuilder_.build(); + } + } + if (filterScopingBuilder_ == null) { + result.filterScoping_ = filterScoping_; + } else { + result.filterScoping_ = filterScopingBuilder_.build(); + } + result.oneParameterCase_ = oneParameterCase_; + result.oneFilterCase_ = oneFilterCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentParameterFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentParameterFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SegmentParameterFilter other) { + if (other == com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance()) + return this; + if (other.hasFilterScoping()) { + mergeFilterScoping(other.getFilterScoping()); + } + switch (other.getOneParameterCase()) { + case EVENT_PARAMETER_NAME: + { + oneParameterCase_ = 1; + oneParameter_ = other.oneParameter_; + onChanged(); + break; + } + case ITEM_PARAMETER_NAME: + { + oneParameterCase_ = 2; + oneParameter_ = other.oneParameter_; + onChanged(); + break; + } + case ONEPARAMETER_NOT_SET: + { + break; + } + } + switch (other.getOneFilterCase()) { + case STRING_FILTER: + { + mergeStringFilter(other.getStringFilter()); + break; + } + case IN_LIST_FILTER: + { + mergeInListFilter(other.getInListFilter()); + break; + } + case NUMERIC_FILTER: + { + mergeNumericFilter(other.getNumericFilter()); + break; + } + case BETWEEN_FILTER: + { + mergeBetweenFilter(other.getBetweenFilter()); + break; + } + case ONEFILTER_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentParameterFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentParameterFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int oneParameterCase_ = 0; + private java.lang.Object oneParameter_; + + public OneParameterCase getOneParameterCase() { + return OneParameterCase.forNumber(oneParameterCase_); + } + + public Builder clearOneParameter() { + oneParameterCase_ = 0; + oneParameter_ = null; + onChanged(); + return this; + } + + private int oneFilterCase_ = 0; + private java.lang.Object oneFilter_; + + public OneFilterCase getOneFilterCase() { + return OneFilterCase.forNumber(oneFilterCase_); + } + + public Builder clearOneFilter() { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + return this; + } + + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return Whether the eventParameterName field is set. + */ + @java.lang.Override + public boolean hasEventParameterName() { + return oneParameterCase_ == 1; + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return The eventParameterName. + */ + @java.lang.Override + public java.lang.String getEventParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (oneParameterCase_ == 1) { + oneParameter_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return The bytes for eventParameterName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEventParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 1) { + ref = oneParameter_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 1) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @param value The eventParameterName to set. + * @return This builder for chaining. + */ + public Builder setEventParameterName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + oneParameterCase_ = 1; + oneParameter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearEventParameterName() { + if (oneParameterCase_ == 1) { + oneParameterCase_ = 0; + oneParameter_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified event parameter. Event
+     * parameters are logged as parameters of the event. Event parameters
+     * include fields like "firebase_screen" & "currency".
+     * Event parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * 
+ * + * string event_parameter_name = 1; + * + * @param value The bytes for eventParameterName to set. + * @return This builder for chaining. + */ + public Builder setEventParameterNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + oneParameterCase_ = 1; + oneParameter_ = value; + onChanged(); + return this; + } + + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return Whether the itemParameterName field is set. + */ + @java.lang.Override + public boolean hasItemParameterName() { + return oneParameterCase_ == 2; + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return The itemParameterName. + */ + @java.lang.Override + public java.lang.String getItemParameterName() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (oneParameterCase_ == 2) { + oneParameter_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return The bytes for itemParameterName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getItemParameterNameBytes() { + java.lang.Object ref = ""; + if (oneParameterCase_ == 2) { + ref = oneParameter_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (oneParameterCase_ == 2) { + oneParameter_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @param value The itemParameterName to set. + * @return This builder for chaining. + */ + public Builder setItemParameterName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + oneParameterCase_ = 2; + oneParameter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearItemParameterName() { + if (oneParameterCase_ == 2) { + oneParameterCase_ = 0; + oneParameter_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * This filter will be evaluated on the specified item parameter. Item
+     * parameters are logged as parameters in the item array. Item parameters
+     * include fields like "item_name" & "item_category".
+     * Item parameters can only be used in segments & funnels and can only be
+     * used in a descendent filter from an EventFilter. In a descendent filter
+     * from an EventFilter either event or item parameters should be used.
+     * Item parameters are only available in ecommerce events. To learn more
+     * about ecommerce events, see the [Measure ecommerce]
+     * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+     * guide.
+     * 
+ * + * string item_parameter_name = 2; + * + * @param value The bytes for itemParameterName to set. + * @return This builder for chaining. + */ + public Builder setItemParameterNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + oneParameterCase_ = 2; + oneParameter_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + stringFilterBuilder_; + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + @java.lang.Override + public boolean hasStringFilter() { + return oneFilterCase_ == 4; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 4) { + return stringFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + stringFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder setStringFilter( + com.google.analytics.data.v1alpha.StringFilter.Builder builderForValue) { + if (stringFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + stringFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder mergeStringFilter(com.google.analytics.data.v1alpha.StringFilter value) { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4 + && oneFilter_ != com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.StringFilter.newBuilder( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 4) { + stringFilterBuilder_.mergeFrom(value); + } else { + stringFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 4; + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public Builder clearStringFilter() { + if (stringFilterBuilder_ == null) { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 4) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + stringFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + public com.google.analytics.data.v1alpha.StringFilter.Builder getStringFilterBuilder() { + return getStringFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder() { + if ((oneFilterCase_ == 4) && (stringFilterBuilder_ != null)) { + return stringFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 4) { + return (com.google.analytics.data.v1alpha.StringFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * Strings related filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder> + getStringFilterFieldBuilder() { + if (stringFilterBuilder_ == null) { + if (!(oneFilterCase_ == 4)) { + oneFilter_ = com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + stringFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.StringFilter, + com.google.analytics.data.v1alpha.StringFilter.Builder, + com.google.analytics.data.v1alpha.StringFilterOrBuilder>( + (com.google.analytics.data.v1alpha.StringFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 4; + onChanged(); + ; + return stringFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + inListFilterBuilder_; + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + @java.lang.Override + public boolean hasInListFilter() { + return oneFilterCase_ == 5; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilter getInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 5) { + return inListFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + inListFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder setInListFilter( + com.google.analytics.data.v1alpha.InListFilter.Builder builderForValue) { + if (inListFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + inListFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder mergeInListFilter(com.google.analytics.data.v1alpha.InListFilter value) { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5 + && oneFilter_ != com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.InListFilter.newBuilder( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 5) { + inListFilterBuilder_.mergeFrom(value); + } else { + inListFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 5; + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public Builder clearInListFilter() { + if (inListFilterBuilder_ == null) { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 5) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + inListFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + public com.google.analytics.data.v1alpha.InListFilter.Builder getInListFilterBuilder() { + return getInListFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder() { + if ((oneFilterCase_ == 5) && (inListFilterBuilder_ != null)) { + return inListFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 5) { + return (com.google.analytics.data.v1alpha.InListFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for in list values.
+     * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder> + getInListFilterFieldBuilder() { + if (inListFilterBuilder_ == null) { + if (!(oneFilterCase_ == 5)) { + oneFilter_ = com.google.analytics.data.v1alpha.InListFilter.getDefaultInstance(); + } + inListFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.InListFilter, + com.google.analytics.data.v1alpha.InListFilter.Builder, + com.google.analytics.data.v1alpha.InListFilterOrBuilder>( + (com.google.analytics.data.v1alpha.InListFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 5; + onChanged(); + ; + return inListFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + numericFilterBuilder_; + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + @java.lang.Override + public boolean hasNumericFilter() { + return oneFilterCase_ == 6; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilter getNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 6) { + return numericFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + numericFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder setNumericFilter( + com.google.analytics.data.v1alpha.NumericFilter.Builder builderForValue) { + if (numericFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + numericFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder mergeNumericFilter(com.google.analytics.data.v1alpha.NumericFilter value) { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6 + && oneFilter_ != com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.NumericFilter.newBuilder( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 6) { + numericFilterBuilder_.mergeFrom(value); + } else { + numericFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 6; + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public Builder clearNumericFilter() { + if (numericFilterBuilder_ == null) { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 6) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + numericFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + public com.google.analytics.data.v1alpha.NumericFilter.Builder getNumericFilterBuilder() { + return getNumericFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder() { + if ((oneFilterCase_ == 6) && (numericFilterBuilder_ != null)) { + return numericFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 6) { + return (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for numeric or date values.
+     * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder> + getNumericFilterFieldBuilder() { + if (numericFilterBuilder_ == null) { + if (!(oneFilterCase_ == 6)) { + oneFilter_ = com.google.analytics.data.v1alpha.NumericFilter.getDefaultInstance(); + } + numericFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.NumericFilter, + com.google.analytics.data.v1alpha.NumericFilter.Builder, + com.google.analytics.data.v1alpha.NumericFilterOrBuilder>( + (com.google.analytics.data.v1alpha.NumericFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 6; + onChanged(); + ; + return numericFilterBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + betweenFilterBuilder_; + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + @java.lang.Override + public boolean hasBetweenFilter() { + return oneFilterCase_ == 7; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } else { + if (oneFilterCase_ == 7) { + return betweenFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + oneFilter_ = value; + onChanged(); + } else { + betweenFilterBuilder_.setMessage(value); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder setBetweenFilter( + com.google.analytics.data.v1alpha.BetweenFilter.Builder builderForValue) { + if (betweenFilterBuilder_ == null) { + oneFilter_ = builderForValue.build(); + onChanged(); + } else { + betweenFilterBuilder_.setMessage(builderForValue.build()); + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder mergeBetweenFilter(com.google.analytics.data.v1alpha.BetweenFilter value) { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7 + && oneFilter_ != com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance()) { + oneFilter_ = + com.google.analytics.data.v1alpha.BetweenFilter.newBuilder( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_) + .mergeFrom(value) + .buildPartial(); + } else { + oneFilter_ = value; + } + onChanged(); + } else { + if (oneFilterCase_ == 7) { + betweenFilterBuilder_.mergeFrom(value); + } else { + betweenFilterBuilder_.setMessage(value); + } + } + oneFilterCase_ = 7; + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public Builder clearBetweenFilter() { + if (betweenFilterBuilder_ == null) { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + onChanged(); + } + } else { + if (oneFilterCase_ == 7) { + oneFilterCase_ = 0; + oneFilter_ = null; + } + betweenFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + public com.google.analytics.data.v1alpha.BetweenFilter.Builder getBetweenFilterBuilder() { + return getBetweenFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder() { + if ((oneFilterCase_ == 7) && (betweenFilterBuilder_ != null)) { + return betweenFilterBuilder_.getMessageOrBuilder(); + } else { + if (oneFilterCase_ == 7) { + return (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_; + } + return com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A filter for between two values.
+     * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder> + getBetweenFilterFieldBuilder() { + if (betweenFilterBuilder_ == null) { + if (!(oneFilterCase_ == 7)) { + oneFilter_ = com.google.analytics.data.v1alpha.BetweenFilter.getDefaultInstance(); + } + betweenFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.BetweenFilter, + com.google.analytics.data.v1alpha.BetweenFilter.Builder, + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder>( + (com.google.analytics.data.v1alpha.BetweenFilter) oneFilter_, + getParentForChildren(), + isClean()); + oneFilter_ = null; + } + oneFilterCase_ = 7; + onChanged(); + ; + return betweenFilterBuilder_; + } + + private com.google.analytics.data.v1alpha.SegmentParameterFilterScoping filterScoping_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping, + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder> + filterScopingBuilder_; + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * + * @return Whether the filterScoping field is set. + */ + public boolean hasFilterScoping() { + return filterScopingBuilder_ != null || filterScoping_ != null; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * + * @return The filterScoping. + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterScoping getFilterScoping() { + if (filterScopingBuilder_ == null) { + return filterScoping_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.getDefaultInstance() + : filterScoping_; + } else { + return filterScopingBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + public Builder setFilterScoping( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping value) { + if (filterScopingBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + filterScoping_ = value; + onChanged(); + } else { + filterScopingBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + public Builder setFilterScoping( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder builderForValue) { + if (filterScopingBuilder_ == null) { + filterScoping_ = builderForValue.build(); + onChanged(); + } else { + filterScopingBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + public Builder mergeFilterScoping( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping value) { + if (filterScopingBuilder_ == null) { + if (filterScoping_ != null) { + filterScoping_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.newBuilder( + filterScoping_) + .mergeFrom(value) + .buildPartial(); + } else { + filterScoping_ = value; + } + onChanged(); + } else { + filterScopingBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + public Builder clearFilterScoping() { + if (filterScopingBuilder_ == null) { + filterScoping_ = null; + onChanged(); + } else { + filterScoping_ = null; + filterScopingBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder + getFilterScopingBuilder() { + + onChanged(); + return getFilterScopingFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder + getFilterScopingOrBuilder() { + if (filterScopingBuilder_ != null) { + return filterScopingBuilder_.getMessageOrBuilder(); + } else { + return filterScoping_ == null + ? com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.getDefaultInstance() + : filterScoping_; + } + } + /** + * + * + *
+     * Specifies the scope for the filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping, + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder> + getFilterScopingFieldBuilder() { + if (filterScopingBuilder_ == null) { + filterScopingBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping, + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder>( + getFilterScoping(), getParentForChildren(), isClean()); + filterScoping_ = null; + } + return filterScopingBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentParameterFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentParameterFilter) + private static final com.google.analytics.data.v1alpha.SegmentParameterFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentParameterFilter(); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentParameterFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentParameterFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentParameterFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpression.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpression.java new file mode 100644 index 00000000..a1160cd0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpression.java @@ -0,0 +1,1912 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Expresses combinations of segment filter on parameters.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilterExpression} + */ +public final class SegmentParameterFilterExpression extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentParameterFilterExpression) + SegmentParameterFilterExpressionOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentParameterFilterExpression.newBuilder() to construct. + private SegmentParameterFilterExpression( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentParameterFilterExpression() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentParameterFilterExpression(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentParameterFilterExpression( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder + subBuilder = null; + if (exprCase_ == 1) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 1; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder + subBuilder = null; + if (exprCase_ == 2) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 2; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + subBuilder = null; + if (exprCase_ == 3) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_) + .toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 3; + break; + } + case 34: + { + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder subBuilder = null; + if (exprCase_ == 4) { + subBuilder = + ((com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_).toBuilder(); + } + expr_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilter.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_); + expr_ = subBuilder.buildPartial(); + } + exprCase_ = 4; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.class, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder.class); + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public enum ExprCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AND_GROUP(1), + OR_GROUP(2), + NOT_EXPRESSION(3), + SEGMENT_PARAMETER_FILTER(4), + EXPR_NOT_SET(0); + private final int value; + + private ExprCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ExprCase valueOf(int value) { + return forNumber(value); + } + + public static ExprCase forNumber(int value) { + switch (value) { + case 1: + return AND_GROUP; + case 2: + return OR_GROUP; + case 3: + return NOT_EXPRESSION; + case 4: + return SEGMENT_PARAMETER_FILTER; + case 0: + return EXPR_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public static final int AND_GROUP_FIELD_NUMBER = 1; + /** + * + * + *
+   * The SegmentParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+   * The SegmentParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList getAndGroup() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + /** + * + * + *
+   * The SegmentParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + + public static final int OR_GROUP_FIELD_NUMBER = 2; + /** + * + * + *
+   * The SegmentParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+   * The SegmentParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList getOrGroup() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + /** + * + * + *
+   * The SegmentParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + + public static final int NOT_EXPRESSION_FIELD_NUMBER = 3; + /** + * + * + *
+   * The SegmentParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+   * The SegmentParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression getNotExpression() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.getDefaultInstance(); + } + /** + * + * + *
+   * The SegmentParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.getDefaultInstance(); + } + + public static final int SEGMENT_PARAMETER_FILTER_FIELD_NUMBER = 4; + /** + * + * + *
+   * A primitive segment parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + * + * @return Whether the segmentParameterFilter field is set. + */ + @java.lang.Override + public boolean hasSegmentParameterFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+   * A primitive segment parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + * + * @return The segmentParameterFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilter getSegmentParameterFilter() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } + /** + * + * + *
+   * A primitive segment parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder + getSegmentParameterFilterOrBuilder() { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } + + 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 (exprCase_ == 1) { + output.writeMessage( + 1, (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + output.writeMessage( + 2, (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + output.writeMessage( + 3, (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_); + } + if (exprCase_ == 4) { + output.writeMessage(4, (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (exprCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_); + } + if (exprCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_); + } + if (exprCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_); + } + if (exprCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentParameterFilterExpression)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression other = + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) obj; + + if (!getExprCase().equals(other.getExprCase())) return false; + switch (exprCase_) { + case 1: + if (!getAndGroup().equals(other.getAndGroup())) return false; + break; + case 2: + if (!getOrGroup().equals(other.getOrGroup())) return false; + break; + case 3: + if (!getNotExpression().equals(other.getNotExpression())) return false; + break; + case 4: + if (!getSegmentParameterFilter().equals(other.getSegmentParameterFilter())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (exprCase_) { + case 1: + hash = (37 * hash) + AND_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getAndGroup().hashCode(); + break; + case 2: + hash = (37 * hash) + OR_GROUP_FIELD_NUMBER; + hash = (53 * hash) + getOrGroup().hashCode(); + break; + case 3: + hash = (37 * hash) + NOT_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getNotExpression().hashCode(); + break; + case 4: + hash = (37 * hash) + SEGMENT_PARAMETER_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getSegmentParameterFilter().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression 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.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentParameterFilterExpression 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Expresses combinations of segment filter on parameters.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilterExpression} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentParameterFilterExpression) + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.class, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder.class); + } + + // Construct using + // com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + exprCase_ = 0; + expr_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpression_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression build() { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression buildPartial() { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression result = + new com.google.analytics.data.v1alpha.SegmentParameterFilterExpression(this); + if (exprCase_ == 1) { + if (andGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = andGroupBuilder_.build(); + } + } + if (exprCase_ == 2) { + if (orGroupBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = orGroupBuilder_.build(); + } + } + if (exprCase_ == 3) { + if (notExpressionBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = notExpressionBuilder_.build(); + } + } + if (exprCase_ == 4) { + if (segmentParameterFilterBuilder_ == null) { + result.expr_ = expr_; + } else { + result.expr_ = segmentParameterFilterBuilder_.build(); + } + } + result.exprCase_ = exprCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) { + return mergeFrom( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression other) { + if (other + == com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance()) return this; + switch (other.getExprCase()) { + case AND_GROUP: + { + mergeAndGroup(other.getAndGroup()); + break; + } + case OR_GROUP: + { + mergeOrGroup(other.getOrGroup()); + break; + } + case NOT_EXPRESSION: + { + mergeNotExpression(other.getNotExpression()); + break; + } + case SEGMENT_PARAMETER_FILTER: + { + mergeSegmentParameterFilter(other.getSegmentParameterFilter()); + break; + } + case EXPR_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int exprCase_ = 0; + private java.lang.Object expr_; + + public ExprCase getExprCase() { + return ExprCase.forNumber(exprCase_); + } + + public Builder clearExpr() { + exprCase_ = 0; + expr_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder> + andGroupBuilder_; + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + * + * @return Whether the andGroup field is set. + */ + @java.lang.Override + public boolean hasAndGroup() { + return exprCase_ == 1; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + * + * @return The andGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList getAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } else { + if (exprCase_ == 1) { + return andGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + andGroupBuilder_.setMessage(value); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + public Builder setAndGroup( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder + builderForValue) { + if (andGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + andGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + public Builder mergeAndGroup( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList value) { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1 + && expr_ + != com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 1) { + andGroupBuilder_.mergeFrom(value); + } else { + andGroupBuilder_.setMessage(value); + } + } + exprCase_ = 1; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + public Builder clearAndGroup() { + if (andGroupBuilder_ == null) { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 1) { + exprCase_ = 0; + expr_ = null; + } + andGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder + getAndGroupBuilder() { + return getAndGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder + getAndGroupOrBuilder() { + if ((exprCase_ == 1) && (andGroupBuilder_ != null)) { + return andGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 1) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `andGroup` have an AND
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder> + getAndGroupFieldBuilder() { + if (andGroupBuilder_ == null) { + if (!(exprCase_ == 1)) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + andGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 1; + onChanged(); + ; + return andGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder> + orGroupBuilder_; + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + * + * @return Whether the orGroup field is set. + */ + @java.lang.Override + public boolean hasOrGroup() { + return exprCase_ == 2; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + * + * @return The orGroup. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList getOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } else { + if (exprCase_ == 2) { + return orGroupBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + orGroupBuilder_.setMessage(value); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + public Builder setOrGroup( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder + builderForValue) { + if (orGroupBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + orGroupBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + public Builder mergeOrGroup( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList value) { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2 + && expr_ + != com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.newBuilder( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 2) { + orGroupBuilder_.mergeFrom(value); + } else { + orGroupBuilder_.setMessage(value); + } + } + exprCase_ = 2; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + public Builder clearOrGroup() { + if (orGroupBuilder_ == null) { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 2) { + exprCase_ = 0; + expr_ = null; + } + orGroupBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder + getOrGroupBuilder() { + return getOrGroupFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder + getOrGroupOrBuilder() { + if ((exprCase_ == 2) && (orGroupBuilder_ != null)) { + return orGroupBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 2) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentParameterFilterExpression in `orGroup` have an OR
+     * relationship.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder> + getOrGroupFieldBuilder() { + if (orGroupBuilder_ == null) { + if (!(exprCase_ == 2)) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + orGroupBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 2; + onChanged(); + ; + return orGroupBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + notExpressionBuilder_; + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + * + * @return Whether the notExpression field is set. + */ + @java.lang.Override + public boolean hasNotExpression() { + return exprCase_ == 3; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + * + * @return The notExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression getNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance(); + } else { + if (exprCase_ == 3) { + return notExpressionBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + notExpressionBuilder_.setMessage(value); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + public Builder setNotExpression( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + builderForValue) { + if (notExpressionBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + notExpressionBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + public Builder mergeNotExpression( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3 + && expr_ + != com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.newBuilder( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 3) { + notExpressionBuilder_.mergeFrom(value); + } else { + notExpressionBuilder_.setMessage(value); + } + } + exprCase_ = 3; + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + public Builder clearNotExpression() { + if (notExpressionBuilder_ == null) { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 3) { + exprCase_ = 0; + expr_ = null; + } + notExpressionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + getNotExpressionBuilder() { + return getNotExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getNotExpressionOrBuilder() { + if ((exprCase_ == 3) && (notExpressionBuilder_ != null)) { + return notExpressionBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 3) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance(); + } + } + /** + * + * + *
+     * The SegmentParameterFilterExpression is NOT of `notExpression`.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + getNotExpressionFieldBuilder() { + if (notExpressionBuilder_ == null) { + if (!(exprCase_ == 3)) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance(); + } + notExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpression) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 3; + onChanged(); + ; + return notExpressionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilter, + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder> + segmentParameterFilterBuilder_; + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + * + * @return Whether the segmentParameterFilter field is set. + */ + @java.lang.Override + public boolean hasSegmentParameterFilter() { + return exprCase_ == 4; + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + * + * @return The segmentParameterFilter. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilter getSegmentParameterFilter() { + if (segmentParameterFilterBuilder_ == null) { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } else { + if (exprCase_ == 4) { + return segmentParameterFilterBuilder_.getMessage(); + } + return com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + public Builder setSegmentParameterFilter( + com.google.analytics.data.v1alpha.SegmentParameterFilter value) { + if (segmentParameterFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expr_ = value; + onChanged(); + } else { + segmentParameterFilterBuilder_.setMessage(value); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + public Builder setSegmentParameterFilter( + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder builderForValue) { + if (segmentParameterFilterBuilder_ == null) { + expr_ = builderForValue.build(); + onChanged(); + } else { + segmentParameterFilterBuilder_.setMessage(builderForValue.build()); + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + public Builder mergeSegmentParameterFilter( + com.google.analytics.data.v1alpha.SegmentParameterFilter value) { + if (segmentParameterFilterBuilder_ == null) { + if (exprCase_ == 4 + && expr_ + != com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance()) { + expr_ = + com.google.analytics.data.v1alpha.SegmentParameterFilter.newBuilder( + (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_) + .mergeFrom(value) + .buildPartial(); + } else { + expr_ = value; + } + onChanged(); + } else { + if (exprCase_ == 4) { + segmentParameterFilterBuilder_.mergeFrom(value); + } else { + segmentParameterFilterBuilder_.setMessage(value); + } + } + exprCase_ = 4; + return this; + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + public Builder clearSegmentParameterFilter() { + if (segmentParameterFilterBuilder_ == null) { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + onChanged(); + } + } else { + if (exprCase_ == 4) { + exprCase_ = 0; + expr_ = null; + } + segmentParameterFilterBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder + getSegmentParameterFilterBuilder() { + return getSegmentParameterFilterFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder + getSegmentParameterFilterOrBuilder() { + if ((exprCase_ == 4) && (segmentParameterFilterBuilder_ != null)) { + return segmentParameterFilterBuilder_.getMessageOrBuilder(); + } else { + if (exprCase_ == 4) { + return (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_; + } + return com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } + } + /** + * + * + *
+     * A primitive segment parameter filter.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilter, + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder> + getSegmentParameterFilterFieldBuilder() { + if (segmentParameterFilterBuilder_ == null) { + if (!(exprCase_ == 4)) { + expr_ = com.google.analytics.data.v1alpha.SegmentParameterFilter.getDefaultInstance(); + } + segmentParameterFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilter, + com.google.analytics.data.v1alpha.SegmentParameterFilter.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder>( + (com.google.analytics.data.v1alpha.SegmentParameterFilter) expr_, + getParentForChildren(), + isClean()); + expr_ = null; + } + exprCase_ = 4; + onChanged(); + ; + return segmentParameterFilterBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentParameterFilterExpression) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentParameterFilterExpression) + private static final com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentParameterFilterExpression(); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentParameterFilterExpression parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentParameterFilterExpression(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentParameterFilterExpression + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionList.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionList.java new file mode 100644 index 00000000..73967881 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionList.java @@ -0,0 +1,1041 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A list of segment parameter filter expressions.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilterExpressionList} + */ +public final class SegmentParameterFilterExpressionList + extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + SegmentParameterFilterExpressionListOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentParameterFilterExpressionList.newBuilder() to construct. + private SegmentParameterFilterExpressionList( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentParameterFilterExpressionList() { + expressions_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentParameterFilterExpressionList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentParameterFilterExpressionList( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression>(); + mutable_bitField0_ |= 0x00000001; + } + expressions_.add( + input.readMessage( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.class, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder.class); + } + + public static final int EXPRESSIONS_FIELD_NUMBER = 1; + private java.util.List + expressions_; + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public java.util.List + getExpressionsList() { + return expressions_; + } + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + return expressions_; + } + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public int getExpressionsCount() { + return expressions_.size(); + } + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression getExpressions( + int index) { + return expressions_.get(index); + } + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getExpressionsOrBuilder(int index) { + return expressions_.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 < expressions_.size(); i++) { + output.writeMessage(1, expressions_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < expressions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, expressions_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentParameterFilterExpressionList)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList other = + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) obj; + + if (!getExpressionsList().equals(other.getExpressionsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExpressionsCount() > 0) { + hash = (37 * hash) + EXPRESSIONS_FIELD_NUMBER; + hash = (53 * hash) + getExpressionsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList 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.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentParameterFilterExpressionList 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A list of segment parameter filter expressions.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilterExpressionList} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.class, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.Builder.class); + } + + // Construct using + // com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExpressionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + expressionsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterExpressionList_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList build() { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList buildPartial() { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList result = + new com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList(this); + int from_bitField0_ = bitField0_; + if (expressionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + expressions_ = java.util.Collections.unmodifiableList(expressions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.expressions_ = expressions_; + } else { + result.expressions_ = expressionsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) { + return mergeFrom( + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList other) { + if (other + == com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + .getDefaultInstance()) return this; + if (expressionsBuilder_ == null) { + if (!other.expressions_.isEmpty()) { + if (expressions_.isEmpty()) { + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExpressionsIsMutable(); + expressions_.addAll(other.expressions_); + } + onChanged(); + } + } else { + if (!other.expressions_.isEmpty()) { + if (expressionsBuilder_.isEmpty()) { + expressionsBuilder_.dispose(); + expressionsBuilder_ = null; + expressions_ = other.expressions_; + bitField0_ = (bitField0_ & ~0x00000001); + expressionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExpressionsFieldBuilder() + : null; + } else { + expressionsBuilder_.addAllMessages(other.expressions_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + expressions_ = java.util.Collections.emptyList(); + + private void ensureExpressionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + expressions_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression>(expressions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + expressionsBuilder_; + + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public java.util.List + getExpressionsList() { + if (expressionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(expressions_); + } else { + return expressionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public int getExpressionsCount() { + if (expressionsBuilder_ == null) { + return expressions_.size(); + } else { + return expressionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression getExpressions( + int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder setExpressions( + int index, com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.set(index, value); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder setExpressions( + int index, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.set(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(value); + onChanged(); + } else { + expressionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + int index, com.google.analytics.data.v1alpha.SegmentParameterFilterExpression value) { + if (expressionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExpressionsIsMutable(); + expressions_.add(index, value); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder addExpressions( + int index, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + builderForValue) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.add(index, builderForValue.build()); + onChanged(); + } else { + expressionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder addAllExpressions( + java.lang.Iterable< + ? extends com.google.analytics.data.v1alpha.SegmentParameterFilterExpression> + values) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, expressions_); + onChanged(); + } else { + expressionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder clearExpressions() { + if (expressionsBuilder_ == null) { + expressions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + expressionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public Builder removeExpressions(int index) { + if (expressionsBuilder_ == null) { + ensureExpressionsIsMutable(); + expressions_.remove(index); + onChanged(); + } else { + expressionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + getExpressionsBuilder(int index) { + return getExpressionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getExpressionsOrBuilder(int index) { + if (expressionsBuilder_ == null) { + return expressions_.get(index); + } else { + return expressionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + getExpressionsOrBuilderList() { + if (expressionsBuilder_ != null) { + return expressionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(expressions_); + } + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + addExpressionsBuilder() { + return getExpressionsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance()); + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder + addExpressionsBuilder(int index) { + return getExpressionsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression + .getDefaultInstance()); + } + /** + * + * + *
+     * The list of segment parameter filter expressions.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + public java.util.List< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder> + getExpressionsBuilderList() { + return getExpressionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + getExpressionsFieldBuilder() { + if (expressionsBuilder_ == null) { + expressionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder>( + expressions_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + expressions_ = null; + } + return expressionsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + private static final com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList(); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentParameterFilterExpressionList parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentParameterFilterExpressionList(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentParameterFilterExpressionList + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionListOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionListOrBuilder.java new file mode 100644 index 00000000..2313d641 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionListOrBuilder.java @@ -0,0 +1,85 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentParameterFilterExpressionListOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentParameterFilterExpressionList) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + java.util.List + getExpressionsList(); + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression getExpressions(int index); + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + int getExpressionsCount(); + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + java.util.List< + ? extends com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder> + getExpressionsOrBuilderList(); + /** + * + * + *
+   * The list of segment parameter filter expressions.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getExpressionsOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionOrBuilder.java new file mode 100644 index 00000000..9e180515 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterExpressionOrBuilder.java @@ -0,0 +1,183 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentParameterFilterExpressionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentParameterFilterExpression) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The SegmentParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + * @return Whether the andGroup field is set. + */ + boolean hasAndGroup(); + /** + * + * + *
+   * The SegmentParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * + * @return The andGroup. + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList getAndGroup(); + /** + * + * + *
+   * The SegmentParameterFilterExpression in `andGroup` have an AND
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder + getAndGroupOrBuilder(); + + /** + * + * + *
+   * The SegmentParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + * @return Whether the orGroup field is set. + */ + boolean hasOrGroup(); + /** + * + * + *
+   * The SegmentParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * + * @return The orGroup. + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionList getOrGroup(); + /** + * + * + *
+   * The SegmentParameterFilterExpression in `orGroup` have an OR
+   * relationship.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionListOrBuilder + getOrGroupOrBuilder(); + + /** + * + * + *
+   * The SegmentParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + * + * @return Whether the notExpression field is set. + */ + boolean hasNotExpression(); + /** + * + * + *
+   * The SegmentParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + * + * @return The notExpression. + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpression getNotExpression(); + /** + * + * + *
+   * The SegmentParameterFilterExpression is NOT of `notExpression`.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterExpressionOrBuilder + getNotExpressionOrBuilder(); + + /** + * + * + *
+   * A primitive segment parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + * + * @return Whether the segmentParameterFilter field is set. + */ + boolean hasSegmentParameterFilter(); + /** + * + * + *
+   * A primitive segment parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + * + * @return The segmentParameterFilter. + */ + com.google.analytics.data.v1alpha.SegmentParameterFilter getSegmentParameterFilter(); + /** + * + * + *
+   * A primitive segment parameter filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterOrBuilder + getSegmentParameterFilterOrBuilder(); + + public com.google.analytics.data.v1alpha.SegmentParameterFilterExpression.ExprCase getExprCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterOrBuilder.java new file mode 100644 index 00000000..fb56b041 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterOrBuilder.java @@ -0,0 +1,322 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentParameterFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentParameterFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return Whether the eventParameterName field is set. + */ + boolean hasEventParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The eventParameterName. + */ + java.lang.String getEventParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified event parameter. Event
+   * parameters are logged as parameters of the event. Event parameters
+   * include fields like "firebase_screen" & "currency".
+   * Event parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * 
+ * + * string event_parameter_name = 1; + * + * @return The bytes for eventParameterName. + */ + com.google.protobuf.ByteString getEventParameterNameBytes(); + + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return Whether the itemParameterName field is set. + */ + boolean hasItemParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The itemParameterName. + */ + java.lang.String getItemParameterName(); + /** + * + * + *
+   * This filter will be evaluated on the specified item parameter. Item
+   * parameters are logged as parameters in the item array. Item parameters
+   * include fields like "item_name" & "item_category".
+   * Item parameters can only be used in segments & funnels and can only be
+   * used in a descendent filter from an EventFilter. In a descendent filter
+   * from an EventFilter either event or item parameters should be used.
+   * Item parameters are only available in ecommerce events. To learn more
+   * about ecommerce events, see the [Measure ecommerce]
+   * (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce)
+   * guide.
+   * 
+ * + * string item_parameter_name = 2; + * + * @return The bytes for itemParameterName. + */ + com.google.protobuf.ByteString getItemParameterNameBytes(); + + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return Whether the stringFilter field is set. + */ + boolean hasStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * + * @return The stringFilter. + */ + com.google.analytics.data.v1alpha.StringFilter getStringFilter(); + /** + * + * + *
+   * Strings related filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter string_filter = 4; + */ + com.google.analytics.data.v1alpha.StringFilterOrBuilder getStringFilterOrBuilder(); + + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return Whether the inListFilter field is set. + */ + boolean hasInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * + * @return The inListFilter. + */ + com.google.analytics.data.v1alpha.InListFilter getInListFilter(); + /** + * + * + *
+   * A filter for in list values.
+   * 
+ * + * .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + */ + com.google.analytics.data.v1alpha.InListFilterOrBuilder getInListFilterOrBuilder(); + + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return Whether the numericFilter field is set. + */ + boolean hasNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * + * @return The numericFilter. + */ + com.google.analytics.data.v1alpha.NumericFilter getNumericFilter(); + /** + * + * + *
+   * A filter for numeric or date values.
+   * 
+ * + * .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + */ + com.google.analytics.data.v1alpha.NumericFilterOrBuilder getNumericFilterOrBuilder(); + + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return Whether the betweenFilter field is set. + */ + boolean hasBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * + * @return The betweenFilter. + */ + com.google.analytics.data.v1alpha.BetweenFilter getBetweenFilter(); + /** + * + * + *
+   * A filter for between two values.
+   * 
+ * + * .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + */ + com.google.analytics.data.v1alpha.BetweenFilterOrBuilder getBetweenFilterOrBuilder(); + + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * + * @return Whether the filterScoping field is set. + */ + boolean hasFilterScoping(); + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * + * @return The filterScoping. + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping getFilterScoping(); + /** + * + * + *
+   * Specifies the scope for the filter.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder + getFilterScopingOrBuilder(); + + public com.google.analytics.data.v1alpha.SegmentParameterFilter.OneParameterCase + getOneParameterCase(); + + public com.google.analytics.data.v1alpha.SegmentParameterFilter.OneFilterCase getOneFilterCase(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScoping.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScoping.java new file mode 100644 index 00000000..8c3d9a2a --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScoping.java @@ -0,0 +1,724 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Scopings specify how multiple events should be considered when evaluating a
+ * segment parameter filter.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilterScoping} + */ +public final class SegmentParameterFilterScoping extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SegmentParameterFilterScoping) + SegmentParameterFilterScopingOrBuilder { + private static final long serialVersionUID = 0L; + // Use SegmentParameterFilterScoping.newBuilder() to construct. + private SegmentParameterFilterScoping(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SegmentParameterFilterScoping() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SegmentParameterFilterScoping(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SegmentParameterFilterScoping( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + bitField0_ |= 0x00000001; + inAnyNDayPeriod_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.class, + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder.class); + } + + private int bitField0_; + public static final int IN_ANY_N_DAY_PERIOD_FIELD_NUMBER = 1; + private long inAnyNDayPeriod_; + /** + * + * + *
+   * Accumulates the parameter over the specified period of days before
+   * applying the filter. Only supported if criteria scoping is
+   * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+   * parameter is `event_count`.
+   * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+   * the event parameter is "event_count", and the Filter's criteria is
+   * greater than 5, this filter will accumulate the event count of purchase
+   * events over every 3 consecutive day period in the report's date range; a
+   * user will pass this Filter's criteria to be included in this segment if
+   * their count of purchase events exceeds 5 in any 3 consecutive day period.
+   * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+   * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+   * The date range is not extended for the purpose of having a full N day
+   * window near the start of the date range. For example if a report is for
+   * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+   * period will be effectively shortened because no event data outside the
+   * report's date range will be read. For example, the first four periods
+   * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+   * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+   * `inAnyNDayPeriod` is optional. If not specified, the
+   * `segmentParameterFilter` is applied to each event individually.
+   * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return Whether the inAnyNDayPeriod field is set. + */ + @java.lang.Override + public boolean hasInAnyNDayPeriod() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * Accumulates the parameter over the specified period of days before
+   * applying the filter. Only supported if criteria scoping is
+   * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+   * parameter is `event_count`.
+   * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+   * the event parameter is "event_count", and the Filter's criteria is
+   * greater than 5, this filter will accumulate the event count of purchase
+   * events over every 3 consecutive day period in the report's date range; a
+   * user will pass this Filter's criteria to be included in this segment if
+   * their count of purchase events exceeds 5 in any 3 consecutive day period.
+   * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+   * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+   * The date range is not extended for the purpose of having a full N day
+   * window near the start of the date range. For example if a report is for
+   * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+   * period will be effectively shortened because no event data outside the
+   * report's date range will be read. For example, the first four periods
+   * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+   * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+   * `inAnyNDayPeriod` is optional. If not specified, the
+   * `segmentParameterFilter` is applied to each event individually.
+   * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return The inAnyNDayPeriod. + */ + @java.lang.Override + public long getInAnyNDayPeriod() { + return inAnyNDayPeriod_; + } + + 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.writeInt64(1, inAnyNDayPeriod_); + } + unknownFields.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.computeInt64Size(1, inAnyNDayPeriod_); + } + size += unknownFields.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.analytics.data.v1alpha.SegmentParameterFilterScoping)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping other = + (com.google.analytics.data.v1alpha.SegmentParameterFilterScoping) obj; + + if (hasInAnyNDayPeriod() != other.hasInAnyNDayPeriod()) return false; + if (hasInAnyNDayPeriod()) { + if (getInAnyNDayPeriod() != other.getInAnyNDayPeriod()) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasInAnyNDayPeriod()) { + hash = (37 * hash) + IN_ANY_N_DAY_PERIOD_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getInAnyNDayPeriod()); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping 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.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SegmentParameterFilterScoping 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Scopings specify how multiple events should be considered when evaluating a
+   * segment parameter filter.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SegmentParameterFilterScoping} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SegmentParameterFilterScoping) + com.google.analytics.data.v1alpha.SegmentParameterFilterScopingOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.class, + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + inAnyNDayPeriod_ = 0L; + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SegmentParameterFilterScoping_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterScoping + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterScoping build() { + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentParameterFilterScoping buildPartial() { + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping result = + new com.google.analytics.data.v1alpha.SegmentParameterFilterScoping(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.inAnyNDayPeriod_ = inAnyNDayPeriod_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SegmentParameterFilterScoping) { + return mergeFrom((com.google.analytics.data.v1alpha.SegmentParameterFilterScoping) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping other) { + if (other + == com.google.analytics.data.v1alpha.SegmentParameterFilterScoping.getDefaultInstance()) + return this; + if (other.hasInAnyNDayPeriod()) { + setInAnyNDayPeriod(other.getInAnyNDayPeriod()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SegmentParameterFilterScoping parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SegmentParameterFilterScoping) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private long inAnyNDayPeriod_; + /** + * + * + *
+     * Accumulates the parameter over the specified period of days before
+     * applying the filter. Only supported if criteria scoping is
+     * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+     * parameter is `event_count`.
+     * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+     * the event parameter is "event_count", and the Filter's criteria is
+     * greater than 5, this filter will accumulate the event count of purchase
+     * events over every 3 consecutive day period in the report's date range; a
+     * user will pass this Filter's criteria to be included in this segment if
+     * their count of purchase events exceeds 5 in any 3 consecutive day period.
+     * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+     * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+     * The date range is not extended for the purpose of having a full N day
+     * window near the start of the date range. For example if a report is for
+     * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+     * period will be effectively shortened because no event data outside the
+     * report's date range will be read. For example, the first four periods
+     * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+     * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+     * `inAnyNDayPeriod` is optional. If not specified, the
+     * `segmentParameterFilter` is applied to each event individually.
+     * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return Whether the inAnyNDayPeriod field is set. + */ + @java.lang.Override + public boolean hasInAnyNDayPeriod() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+     * Accumulates the parameter over the specified period of days before
+     * applying the filter. Only supported if criteria scoping is
+     * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+     * parameter is `event_count`.
+     * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+     * the event parameter is "event_count", and the Filter's criteria is
+     * greater than 5, this filter will accumulate the event count of purchase
+     * events over every 3 consecutive day period in the report's date range; a
+     * user will pass this Filter's criteria to be included in this segment if
+     * their count of purchase events exceeds 5 in any 3 consecutive day period.
+     * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+     * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+     * The date range is not extended for the purpose of having a full N day
+     * window near the start of the date range. For example if a report is for
+     * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+     * period will be effectively shortened because no event data outside the
+     * report's date range will be read. For example, the first four periods
+     * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+     * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+     * `inAnyNDayPeriod` is optional. If not specified, the
+     * `segmentParameterFilter` is applied to each event individually.
+     * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return The inAnyNDayPeriod. + */ + @java.lang.Override + public long getInAnyNDayPeriod() { + return inAnyNDayPeriod_; + } + /** + * + * + *
+     * Accumulates the parameter over the specified period of days before
+     * applying the filter. Only supported if criteria scoping is
+     * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+     * parameter is `event_count`.
+     * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+     * the event parameter is "event_count", and the Filter's criteria is
+     * greater than 5, this filter will accumulate the event count of purchase
+     * events over every 3 consecutive day period in the report's date range; a
+     * user will pass this Filter's criteria to be included in this segment if
+     * their count of purchase events exceeds 5 in any 3 consecutive day period.
+     * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+     * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+     * The date range is not extended for the purpose of having a full N day
+     * window near the start of the date range. For example if a report is for
+     * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+     * period will be effectively shortened because no event data outside the
+     * report's date range will be read. For example, the first four periods
+     * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+     * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+     * `inAnyNDayPeriod` is optional. If not specified, the
+     * `segmentParameterFilter` is applied to each event individually.
+     * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @param value The inAnyNDayPeriod to set. + * @return This builder for chaining. + */ + public Builder setInAnyNDayPeriod(long value) { + bitField0_ |= 0x00000001; + inAnyNDayPeriod_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Accumulates the parameter over the specified period of days before
+     * applying the filter. Only supported if criteria scoping is
+     * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+     * parameter is `event_count`.
+     * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+     * the event parameter is "event_count", and the Filter's criteria is
+     * greater than 5, this filter will accumulate the event count of purchase
+     * events over every 3 consecutive day period in the report's date range; a
+     * user will pass this Filter's criteria to be included in this segment if
+     * their count of purchase events exceeds 5 in any 3 consecutive day period.
+     * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+     * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+     * The date range is not extended for the purpose of having a full N day
+     * window near the start of the date range. For example if a report is for
+     * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+     * period will be effectively shortened because no event data outside the
+     * report's date range will be read. For example, the first four periods
+     * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+     * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+     * `inAnyNDayPeriod` is optional. If not specified, the
+     * `segmentParameterFilter` is applied to each event individually.
+     * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return This builder for chaining. + */ + public Builder clearInAnyNDayPeriod() { + bitField0_ = (bitField0_ & ~0x00000001); + inAnyNDayPeriod_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SegmentParameterFilterScoping) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SegmentParameterFilterScoping) + private static final com.google.analytics.data.v1alpha.SegmentParameterFilterScoping + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SegmentParameterFilterScoping(); + } + + public static com.google.analytics.data.v1alpha.SegmentParameterFilterScoping + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SegmentParameterFilterScoping parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SegmentParameterFilterScoping(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SegmentParameterFilterScoping + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScopingOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScopingOrBuilder.java new file mode 100644 index 00000000..17241195 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SegmentParameterFilterScopingOrBuilder.java @@ -0,0 +1,90 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SegmentParameterFilterScopingOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SegmentParameterFilterScoping) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Accumulates the parameter over the specified period of days before
+   * applying the filter. Only supported if criteria scoping is
+   * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+   * parameter is `event_count`.
+   * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+   * the event parameter is "event_count", and the Filter's criteria is
+   * greater than 5, this filter will accumulate the event count of purchase
+   * events over every 3 consecutive day period in the report's date range; a
+   * user will pass this Filter's criteria to be included in this segment if
+   * their count of purchase events exceeds 5 in any 3 consecutive day period.
+   * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+   * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+   * The date range is not extended for the purpose of having a full N day
+   * window near the start of the date range. For example if a report is for
+   * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+   * period will be effectively shortened because no event data outside the
+   * report's date range will be read. For example, the first four periods
+   * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+   * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+   * `inAnyNDayPeriod` is optional. If not specified, the
+   * `segmentParameterFilter` is applied to each event individually.
+   * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return Whether the inAnyNDayPeriod field is set. + */ + boolean hasInAnyNDayPeriod(); + /** + * + * + *
+   * Accumulates the parameter over the specified period of days before
+   * applying the filter. Only supported if criteria scoping is
+   * `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the
+   * parameter is `event_count`.
+   * For example if `inAnyNDayPeriod` is 3, the event_name is "purchase",
+   * the event parameter is "event_count", and the Filter's criteria is
+   * greater than 5, this filter will accumulate the event count of purchase
+   * events over every 3 consecutive day period in the report's date range; a
+   * user will pass this Filter's criteria to be included in this segment if
+   * their count of purchase events exceeds 5 in any 3 consecutive day period.
+   * For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to
+   * 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered.
+   * The date range is not extended for the purpose of having a full N day
+   * window near the start of the date range. For example if a report is for
+   * 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day
+   * period will be effectively shortened because no event data outside the
+   * report's date range will be read. For example, the first four periods
+   * will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02,
+   * 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04.
+   * `inAnyNDayPeriod` is optional. If not specified, the
+   * `segmentParameterFilter` is applied to each event individually.
+   * 
+ * + * optional int64 in_any_n_day_period = 1; + * + * @return The inAnyNDayPeriod. + */ + long getInAnyNDayPeriod(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionCriteriaScoping.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionCriteriaScoping.java new file mode 100644 index 00000000..248c60ef --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionCriteriaScoping.java @@ -0,0 +1,186 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Scoping specifies which events are considered when evaluating if a
+ * session meets a criteria.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.SessionCriteriaScoping} + */ +public enum SessionCriteriaScoping implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified criteria scoping. Do not specify.
+   * 
+ * + * SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + SESSION_CRITERIA_SCOPING_UNSPECIFIED(0), + /** + * + * + *
+   * If the criteria is satisfied within one event, the session matches the
+   * criteria.
+   * 
+ * + * SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + SESSION_CRITERIA_WITHIN_SAME_EVENT(1), + /** + * + * + *
+   * If the criteria is satisfied within one session, the session matches
+   * the criteria.
+   * 
+ * + * SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; + */ + SESSION_CRITERIA_WITHIN_SAME_SESSION(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified criteria scoping. Do not specify.
+   * 
+ * + * SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + public static final int SESSION_CRITERIA_SCOPING_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * If the criteria is satisfied within one event, the session matches the
+   * criteria.
+   * 
+ * + * SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + public static final int SESSION_CRITERIA_WITHIN_SAME_EVENT_VALUE = 1; + /** + * + * + *
+   * If the criteria is satisfied within one session, the session matches
+   * the criteria.
+   * 
+ * + * SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; + */ + public static final int SESSION_CRITERIA_WITHIN_SAME_SESSION_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 SessionCriteriaScoping 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 SessionCriteriaScoping forNumber(int value) { + switch (value) { + case 0: + return SESSION_CRITERIA_SCOPING_UNSPECIFIED; + case 1: + return SESSION_CRITERIA_WITHIN_SAME_EVENT; + case 2: + return SESSION_CRITERIA_WITHIN_SAME_SESSION; + 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 SessionCriteriaScoping findValueByNumber(int number) { + return SessionCriteriaScoping.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(2); + } + + private static final SessionCriteriaScoping[] VALUES = values(); + + public static SessionCriteriaScoping 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 SessionCriteriaScoping(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.SessionCriteriaScoping) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionExclusionDuration.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionExclusionDuration.java new file mode 100644 index 00000000..7e0ba958 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionExclusionDuration.java @@ -0,0 +1,186 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Enumerates options for how long an exclusion will last if a session
+ * matches the `sessionExclusionCriteria`.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.SessionExclusionDuration} + */ +public enum SessionExclusionDuration implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified exclusion duration. Do not specify.
+   * 
+ * + * SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + SESSION_EXCLUSION_DURATION_UNSPECIFIED(0), + /** + * + * + *
+   * Temporarily exclude sessions from the segment during periods when the
+   * session meets the `sessionExclusionCriteria` condition.
+   * 
+ * + * SESSION_EXCLUSION_TEMPORARY = 1; + */ + SESSION_EXCLUSION_TEMPORARY(1), + /** + * + * + *
+   * Permanently exclude sessions from the segment if the session ever meets
+   * the `sessionExclusionCriteria` condition.
+   * 
+ * + * SESSION_EXCLUSION_PERMANENT = 2; + */ + SESSION_EXCLUSION_PERMANENT(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified exclusion duration. Do not specify.
+   * 
+ * + * SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + public static final int SESSION_EXCLUSION_DURATION_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * Temporarily exclude sessions from the segment during periods when the
+   * session meets the `sessionExclusionCriteria` condition.
+   * 
+ * + * SESSION_EXCLUSION_TEMPORARY = 1; + */ + public static final int SESSION_EXCLUSION_TEMPORARY_VALUE = 1; + /** + * + * + *
+   * Permanently exclude sessions from the segment if the session ever meets
+   * the `sessionExclusionCriteria` condition.
+   * 
+ * + * SESSION_EXCLUSION_PERMANENT = 2; + */ + public static final int SESSION_EXCLUSION_PERMANENT_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 SessionExclusionDuration 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 SessionExclusionDuration forNumber(int value) { + switch (value) { + case 0: + return SESSION_EXCLUSION_DURATION_UNSPECIFIED; + case 1: + return SESSION_EXCLUSION_TEMPORARY; + case 2: + return SESSION_EXCLUSION_PERMANENT; + 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 SessionExclusionDuration findValueByNumber(int number) { + return SessionExclusionDuration.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(3); + } + + private static final SessionExclusionDuration[] VALUES = values(); + + public static SessionExclusionDuration 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 SessionExclusionDuration(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.SessionExclusionDuration) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegment.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegment.java new file mode 100644 index 00000000..028aef36 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegment.java @@ -0,0 +1,1041 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Session segments are subsets of the sessions that occurred on your site or
+ * app: for example, all the sessions that originated from a particular
+ * advertising campaign.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegment} + */ +public final class SessionSegment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SessionSegment) + SessionSegmentOrBuilder { + private static final long serialVersionUID = 0L; + // Use SessionSegment.newBuilder() to construct. + private SessionSegment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SessionSegment() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SessionSegment(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SessionSegment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder subBuilder = null; + if (sessionInclusionCriteria_ != null) { + subBuilder = sessionInclusionCriteria_.toBuilder(); + } + sessionInclusionCriteria_ = + input.readMessage( + com.google.analytics.data.v1alpha.SessionSegmentCriteria.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(sessionInclusionCriteria_); + sessionInclusionCriteria_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder subBuilder = null; + if (exclusion_ != null) { + subBuilder = exclusion_.toBuilder(); + } + exclusion_ = + input.readMessage( + com.google.analytics.data.v1alpha.SessionSegmentExclusion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(exclusion_); + exclusion_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegment.class, + com.google.analytics.data.v1alpha.SessionSegment.Builder.class); + } + + public static final int SESSION_INCLUSION_CRITERIA_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.SessionSegmentCriteria sessionInclusionCriteria_; + /** + * + * + *
+   * Defines which sessions are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + * + * @return Whether the sessionInclusionCriteria field is set. + */ + @java.lang.Override + public boolean hasSessionInclusionCriteria() { + return sessionInclusionCriteria_ != null; + } + /** + * + * + *
+   * Defines which sessions are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + * + * @return The sessionInclusionCriteria. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteria getSessionInclusionCriteria() { + return sessionInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance() + : sessionInclusionCriteria_; + } + /** + * + * + *
+   * Defines which sessions are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder + getSessionInclusionCriteriaOrBuilder() { + return getSessionInclusionCriteria(); + } + + public static final int EXCLUSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.SessionSegmentExclusion exclusion_; + /** + * + * + *
+   * Defines which sessions are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + @java.lang.Override + public boolean hasExclusion() { + return exclusion_ != null; + } + /** + * + * + *
+   * Defines which sessions are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentExclusion getExclusion() { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentExclusion.getDefaultInstance() + : exclusion_; + } + /** + * + * + *
+   * Defines which sessions are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder + getExclusionOrBuilder() { + return getExclusion(); + } + + 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 (sessionInclusionCriteria_ != null) { + output.writeMessage(1, getSessionInclusionCriteria()); + } + if (exclusion_ != null) { + output.writeMessage(2, getExclusion()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (sessionInclusionCriteria_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, getSessionInclusionCriteria()); + } + if (exclusion_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getExclusion()); + } + size += unknownFields.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.analytics.data.v1alpha.SessionSegment)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SessionSegment other = + (com.google.analytics.data.v1alpha.SessionSegment) obj; + + if (hasSessionInclusionCriteria() != other.hasSessionInclusionCriteria()) return false; + if (hasSessionInclusionCriteria()) { + if (!getSessionInclusionCriteria().equals(other.getSessionInclusionCriteria())) return false; + } + if (hasExclusion() != other.hasExclusion()) return false; + if (hasExclusion()) { + if (!getExclusion().equals(other.getExclusion())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSessionInclusionCriteria()) { + hash = (37 * hash) + SESSION_INCLUSION_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getSessionInclusionCriteria().hashCode(); + } + if (hasExclusion()) { + hash = (37 * hash) + EXCLUSION_FIELD_NUMBER; + hash = (53 * hash) + getExclusion().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegment 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.analytics.data.v1alpha.SessionSegment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegment parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SessionSegment 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Session segments are subsets of the sessions that occurred on your site or
+   * app: for example, all the sessions that originated from a particular
+   * advertising campaign.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SessionSegment) + com.google.analytics.data.v1alpha.SessionSegmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegment.class, + com.google.analytics.data.v1alpha.SessionSegment.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SessionSegment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (sessionInclusionCriteriaBuilder_ == null) { + sessionInclusionCriteria_ = null; + } else { + sessionInclusionCriteria_ = null; + sessionInclusionCriteriaBuilder_ = null; + } + if (exclusionBuilder_ == null) { + exclusion_ = null; + } else { + exclusion_ = null; + exclusionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegment_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegment getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegment build() { + com.google.analytics.data.v1alpha.SessionSegment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegment buildPartial() { + com.google.analytics.data.v1alpha.SessionSegment result = + new com.google.analytics.data.v1alpha.SessionSegment(this); + if (sessionInclusionCriteriaBuilder_ == null) { + result.sessionInclusionCriteria_ = sessionInclusionCriteria_; + } else { + result.sessionInclusionCriteria_ = sessionInclusionCriteriaBuilder_.build(); + } + if (exclusionBuilder_ == null) { + result.exclusion_ = exclusion_; + } else { + result.exclusion_ = exclusionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SessionSegment) { + return mergeFrom((com.google.analytics.data.v1alpha.SessionSegment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SessionSegment other) { + if (other == com.google.analytics.data.v1alpha.SessionSegment.getDefaultInstance()) + return this; + if (other.hasSessionInclusionCriteria()) { + mergeSessionInclusionCriteria(other.getSessionInclusionCriteria()); + } + if (other.hasExclusion()) { + mergeExclusion(other.getExclusion()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SessionSegment parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.SessionSegment) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.analytics.data.v1alpha.SessionSegmentCriteria sessionInclusionCriteria_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentCriteria, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder> + sessionInclusionCriteriaBuilder_; + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + * + * @return Whether the sessionInclusionCriteria field is set. + */ + public boolean hasSessionInclusionCriteria() { + return sessionInclusionCriteriaBuilder_ != null || sessionInclusionCriteria_ != null; + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + * + * @return The sessionInclusionCriteria. + */ + public com.google.analytics.data.v1alpha.SessionSegmentCriteria getSessionInclusionCriteria() { + if (sessionInclusionCriteriaBuilder_ == null) { + return sessionInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance() + : sessionInclusionCriteria_; + } else { + return sessionInclusionCriteriaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + public Builder setSessionInclusionCriteria( + com.google.analytics.data.v1alpha.SessionSegmentCriteria value) { + if (sessionInclusionCriteriaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + sessionInclusionCriteria_ = value; + onChanged(); + } else { + sessionInclusionCriteriaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + public Builder setSessionInclusionCriteria( + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder builderForValue) { + if (sessionInclusionCriteriaBuilder_ == null) { + sessionInclusionCriteria_ = builderForValue.build(); + onChanged(); + } else { + sessionInclusionCriteriaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + public Builder mergeSessionInclusionCriteria( + com.google.analytics.data.v1alpha.SessionSegmentCriteria value) { + if (sessionInclusionCriteriaBuilder_ == null) { + if (sessionInclusionCriteria_ != null) { + sessionInclusionCriteria_ = + com.google.analytics.data.v1alpha.SessionSegmentCriteria.newBuilder( + sessionInclusionCriteria_) + .mergeFrom(value) + .buildPartial(); + } else { + sessionInclusionCriteria_ = value; + } + onChanged(); + } else { + sessionInclusionCriteriaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + public Builder clearSessionInclusionCriteria() { + if (sessionInclusionCriteriaBuilder_ == null) { + sessionInclusionCriteria_ = null; + onChanged(); + } else { + sessionInclusionCriteria_ = null; + sessionInclusionCriteriaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder + getSessionInclusionCriteriaBuilder() { + + onChanged(); + return getSessionInclusionCriteriaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder + getSessionInclusionCriteriaOrBuilder() { + if (sessionInclusionCriteriaBuilder_ != null) { + return sessionInclusionCriteriaBuilder_.getMessageOrBuilder(); + } else { + return sessionInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance() + : sessionInclusionCriteria_; + } + } + /** + * + * + *
+     * Defines which sessions are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentCriteria, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder> + getSessionInclusionCriteriaFieldBuilder() { + if (sessionInclusionCriteriaBuilder_ == null) { + sessionInclusionCriteriaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentCriteria, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder>( + getSessionInclusionCriteria(), getParentForChildren(), isClean()); + sessionInclusionCriteria_ = null; + } + return sessionInclusionCriteriaBuilder_; + } + + private com.google.analytics.data.v1alpha.SessionSegmentExclusion exclusion_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentExclusion, + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder> + exclusionBuilder_; + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + public boolean hasExclusion() { + return exclusionBuilder_ != null || exclusion_ != null; + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + public com.google.analytics.data.v1alpha.SessionSegmentExclusion getExclusion() { + if (exclusionBuilder_ == null) { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentExclusion.getDefaultInstance() + : exclusion_; + } else { + return exclusionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + public Builder setExclusion(com.google.analytics.data.v1alpha.SessionSegmentExclusion value) { + if (exclusionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + exclusion_ = value; + onChanged(); + } else { + exclusionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + public Builder setExclusion( + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder builderForValue) { + if (exclusionBuilder_ == null) { + exclusion_ = builderForValue.build(); + onChanged(); + } else { + exclusionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + public Builder mergeExclusion(com.google.analytics.data.v1alpha.SessionSegmentExclusion value) { + if (exclusionBuilder_ == null) { + if (exclusion_ != null) { + exclusion_ = + com.google.analytics.data.v1alpha.SessionSegmentExclusion.newBuilder(exclusion_) + .mergeFrom(value) + .buildPartial(); + } else { + exclusion_ = value; + } + onChanged(); + } else { + exclusionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + public Builder clearExclusion() { + if (exclusionBuilder_ == null) { + exclusion_ = null; + onChanged(); + } else { + exclusion_ = null; + exclusionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + public com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder getExclusionBuilder() { + + onChanged(); + return getExclusionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + public com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder + getExclusionOrBuilder() { + if (exclusionBuilder_ != null) { + return exclusionBuilder_.getMessageOrBuilder(); + } else { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentExclusion.getDefaultInstance() + : exclusion_; + } + } + /** + * + * + *
+     * Defines which sessions are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentExclusion, + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder> + getExclusionFieldBuilder() { + if (exclusionBuilder_ == null) { + exclusionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentExclusion, + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder>( + getExclusion(), getParentForChildren(), isClean()); + exclusion_ = null; + } + return exclusionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SessionSegment) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SessionSegment) + private static final com.google.analytics.data.v1alpha.SessionSegment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SessionSegment(); + } + + public static com.google.analytics.data.v1alpha.SessionSegment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SessionSegment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SessionSegment(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SessionSegment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroup.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroup.java new file mode 100644 index 00000000..6c6029b2 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroup.java @@ -0,0 +1,1028 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Conditions tell Analytics what data to include in or exclude from the
+ * segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegmentConditionGroup} + */ +public final class SessionSegmentConditionGroup extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SessionSegmentConditionGroup) + SessionSegmentConditionGroupOrBuilder { + private static final long serialVersionUID = 0L; + // Use SessionSegmentConditionGroup.newBuilder() to construct. + private SessionSegmentConditionGroup(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SessionSegmentConditionGroup() { + conditionScoping_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SessionSegmentConditionGroup(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SessionSegmentConditionGroup( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + conditionScoping_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder subBuilder = null; + if (segmentFilterExpression_ != null) { + subBuilder = segmentFilterExpression_.toBuilder(); + } + segmentFilterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(segmentFilterExpression_); + segmentFilterExpression_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.class, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder.class); + } + + public static final int CONDITION_SCOPING_FIELD_NUMBER = 1; + private int conditionScoping_; + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this session. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+   * single event, and then, the condition group is determined to be matched or
+   * not for this session.
+   * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+   * is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + @java.lang.Override + public int getConditionScopingValue() { + return conditionScoping_; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this session. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+   * single event, and then, the condition group is determined to be matched or
+   * not for this session.
+   * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+   * is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionCriteriaScoping getConditionScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.SessionCriteriaScoping result = + com.google.analytics.data.v1alpha.SessionCriteriaScoping.valueOf(conditionScoping_); + return result == null + ? com.google.analytics.data.v1alpha.SessionCriteriaScoping.UNRECOGNIZED + : result; + } + + public static final int SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + @java.lang.Override + public boolean hasSegmentFilterExpression() { + return segmentFilterExpression_ != null; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + return getSegmentFilterExpression(); + } + + 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 (conditionScoping_ + != com.google.analytics.data.v1alpha.SessionCriteriaScoping + .SESSION_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, conditionScoping_); + } + if (segmentFilterExpression_ != null) { + output.writeMessage(2, getSegmentFilterExpression()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (conditionScoping_ + != com.google.analytics.data.v1alpha.SessionCriteriaScoping + .SESSION_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, conditionScoping_); + } + if (segmentFilterExpression_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSegmentFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.SessionSegmentConditionGroup)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup other = + (com.google.analytics.data.v1alpha.SessionSegmentConditionGroup) obj; + + if (conditionScoping_ != other.conditionScoping_) return false; + if (hasSegmentFilterExpression() != other.hasSegmentFilterExpression()) return false; + if (hasSegmentFilterExpression()) { + if (!getSegmentFilterExpression().equals(other.getSegmentFilterExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + CONDITION_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + conditionScoping_; + if (hasSegmentFilterExpression()) { + hash = (37 * hash) + SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getSegmentFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup 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.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SessionSegmentConditionGroup 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Conditions tell Analytics what data to include in or exclude from the
+   * segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegmentConditionGroup} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SessionSegmentConditionGroup) + com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.class, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + conditionScoping_ = 0; + + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentConditionGroup_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup + getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup build() { + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup buildPartial() { + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup result = + new com.google.analytics.data.v1alpha.SessionSegmentConditionGroup(this); + result.conditionScoping_ = conditionScoping_; + if (segmentFilterExpressionBuilder_ == null) { + result.segmentFilterExpression_ = segmentFilterExpression_; + } else { + result.segmentFilterExpression_ = segmentFilterExpressionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SessionSegmentConditionGroup) { + return mergeFrom((com.google.analytics.data.v1alpha.SessionSegmentConditionGroup) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SessionSegmentConditionGroup other) { + if (other + == com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.getDefaultInstance()) + return this; + if (other.conditionScoping_ != 0) { + setConditionScopingValue(other.getConditionScopingValue()); + } + if (other.hasSegmentFilterExpression()) { + mergeSegmentFilterExpression(other.getSegmentFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SessionSegmentConditionGroup) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int conditionScoping_ = 0; + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this session. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+     * single event, and then, the condition group is determined to be matched or
+     * not for this session.
+     * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+     * is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + @java.lang.Override + public int getConditionScopingValue() { + return conditionScoping_; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this session. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+     * single event, and then, the condition group is determined to be matched or
+     * not for this session.
+     * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+     * is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @param value The enum numeric value on the wire for conditionScoping to set. + * @return This builder for chaining. + */ + public Builder setConditionScopingValue(int value) { + + conditionScoping_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this session. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+     * single event, and then, the condition group is determined to be matched or
+     * not for this session.
+     * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+     * is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionCriteriaScoping getConditionScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.SessionCriteriaScoping result = + com.google.analytics.data.v1alpha.SessionCriteriaScoping.valueOf(conditionScoping_); + return result == null + ? com.google.analytics.data.v1alpha.SessionCriteriaScoping.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this session. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+     * single event, and then, the condition group is determined to be matched or
+     * not for this session.
+     * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+     * is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @param value The conditionScoping to set. + * @return This builder for chaining. + */ + public Builder setConditionScoping( + com.google.analytics.data.v1alpha.SessionCriteriaScoping value) { + if (value == null) { + throw new NullPointerException(); + } + + conditionScoping_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this session. For example if `conditionScoping =
+     * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+     * single event, and then, the condition group is determined to be matched or
+     * not for this session.
+     * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+     * is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return This builder for chaining. + */ + public Builder clearConditionScoping() { + + conditionScoping_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + segmentFilterExpressionBuilder_; + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + public boolean hasSegmentFilterExpression() { + return segmentFilterExpressionBuilder_ != null || segmentFilterExpression_ != null; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } else { + return segmentFilterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + segmentFilterExpression_ = value; + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = builderForValue.build(); + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder mergeSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (segmentFilterExpression_ != null) { + segmentFilterExpression_ = + com.google.analytics.data.v1alpha.SegmentFilterExpression.newBuilder( + segmentFilterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + segmentFilterExpression_ = value; + } + onChanged(); + } else { + segmentFilterExpressionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder clearSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + onChanged(); + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder + getSegmentFilterExpressionBuilder() { + + onChanged(); + return getSegmentFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + if (segmentFilterExpressionBuilder_ != null) { + return segmentFilterExpressionBuilder_.getMessageOrBuilder(); + } else { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getSegmentFilterExpressionFieldBuilder() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder>( + getSegmentFilterExpression(), getParentForChildren(), isClean()); + segmentFilterExpression_ = null; + } + return segmentFilterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SessionSegmentConditionGroup) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SessionSegmentConditionGroup) + private static final com.google.analytics.data.v1alpha.SessionSegmentConditionGroup + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SessionSegmentConditionGroup(); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentConditionGroup + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SessionSegmentConditionGroup parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SessionSegmentConditionGroup(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SessionSegmentConditionGroup + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroupOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroupOrBuilder.java new file mode 100644 index 00000000..75323664 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentConditionGroupOrBuilder.java @@ -0,0 +1,117 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SessionSegmentConditionGroupOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SessionSegmentConditionGroup) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this session. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+   * single event, and then, the condition group is determined to be matched or
+   * not for this session.
+   * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+   * is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + int getConditionScopingValue(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this session. For example if `conditionScoping =
+   * SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a
+   * single event, and then, the condition group is determined to be matched or
+   * not for this session.
+   * Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION`
+   * is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + com.google.analytics.data.v1alpha.SessionCriteriaScoping getConditionScoping(); + + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + boolean hasSegmentFilterExpression(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteria.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteria.java new file mode 100644 index 00000000..a9feec05 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteria.java @@ -0,0 +1,1054 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A session matches a criteria if the session's events meet the conditions in
+ * the criteria.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegmentCriteria} + */ +public final class SessionSegmentCriteria extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SessionSegmentCriteria) + SessionSegmentCriteriaOrBuilder { + private static final long serialVersionUID = 0L; + // Use SessionSegmentCriteria.newBuilder() to construct. + private SessionSegmentCriteria(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SessionSegmentCriteria() { + andConditionGroups_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SessionSegmentCriteria(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SessionSegmentCriteria( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup>(); + mutable_bitField0_ |= 0x00000001; + } + andConditionGroups_.add( + input.readMessage( + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = java.util.Collections.unmodifiableList(andConditionGroups_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegmentCriteria.class, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder.class); + } + + public static final int AND_CONDITION_GROUPS_FIELD_NUMBER = 1; + private java.util.List + andConditionGroups_; + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public java.util.List + getAndConditionGroupsList() { + return andConditionGroups_; + } + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder> + getAndConditionGroupsOrBuilderList() { + return andConditionGroups_; + } + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public int getAndConditionGroupsCount() { + return andConditionGroups_.size(); + } + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup getAndConditionGroups( + int index) { + return andConditionGroups_.get(index); + } + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index) { + return andConditionGroups_.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 < andConditionGroups_.size(); i++) { + output.writeMessage(1, andConditionGroups_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < andConditionGroups_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, andConditionGroups_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.SessionSegmentCriteria)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SessionSegmentCriteria other = + (com.google.analytics.data.v1alpha.SessionSegmentCriteria) obj; + + if (!getAndConditionGroupsList().equals(other.getAndConditionGroupsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAndConditionGroupsCount() > 0) { + hash = (37 * hash) + AND_CONDITION_GROUPS_FIELD_NUMBER; + hash = (53 * hash) + getAndConditionGroupsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria 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.analytics.data.v1alpha.SessionSegmentCriteria parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SessionSegmentCriteria 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A session matches a criteria if the session's events meet the conditions in
+   * the criteria.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegmentCriteria} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SessionSegmentCriteria) + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegmentCriteria.class, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SessionSegmentCriteria.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getAndConditionGroupsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (andConditionGroupsBuilder_ == null) { + andConditionGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + andConditionGroupsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentCriteria_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteria getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteria build() { + com.google.analytics.data.v1alpha.SessionSegmentCriteria result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteria buildPartial() { + com.google.analytics.data.v1alpha.SessionSegmentCriteria result = + new com.google.analytics.data.v1alpha.SessionSegmentCriteria(this); + int from_bitField0_ = bitField0_; + if (andConditionGroupsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = java.util.Collections.unmodifiableList(andConditionGroups_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.andConditionGroups_ = andConditionGroups_; + } else { + result.andConditionGroups_ = andConditionGroupsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SessionSegmentCriteria) { + return mergeFrom((com.google.analytics.data.v1alpha.SessionSegmentCriteria) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SessionSegmentCriteria other) { + if (other == com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance()) + return this; + if (andConditionGroupsBuilder_ == null) { + if (!other.andConditionGroups_.isEmpty()) { + if (andConditionGroups_.isEmpty()) { + andConditionGroups_ = other.andConditionGroups_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.addAll(other.andConditionGroups_); + } + onChanged(); + } + } else { + if (!other.andConditionGroups_.isEmpty()) { + if (andConditionGroupsBuilder_.isEmpty()) { + andConditionGroupsBuilder_.dispose(); + andConditionGroupsBuilder_ = null; + andConditionGroups_ = other.andConditionGroups_; + bitField0_ = (bitField0_ & ~0x00000001); + andConditionGroupsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getAndConditionGroupsFieldBuilder() + : null; + } else { + andConditionGroupsBuilder_.addAllMessages(other.andConditionGroups_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SessionSegmentCriteria parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SessionSegmentCriteria) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + andConditionGroups_ = java.util.Collections.emptyList(); + + private void ensureAndConditionGroupsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = + new java.util.ArrayList( + andConditionGroups_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder> + andConditionGroupsBuilder_; + + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List + getAndConditionGroupsList() { + if (andConditionGroupsBuilder_ == null) { + return java.util.Collections.unmodifiableList(andConditionGroups_); + } else { + return andConditionGroupsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public int getAndConditionGroupsCount() { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.size(); + } else { + return andConditionGroupsBuilder_.getCount(); + } + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup getAndConditionGroups( + int index) { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.get(index); + } else { + return andConditionGroupsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder setAndConditionGroups( + int index, com.google.analytics.data.v1alpha.SessionSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.set(index, value); + onChanged(); + } else { + andConditionGroupsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder setAndConditionGroups( + int index, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.set(index, builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(value); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + int index, com.google.analytics.data.v1alpha.SessionSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(index, value); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + int index, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(index, builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAllAndConditionGroups( + java.lang.Iterable + values) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, andConditionGroups_); + onChanged(); + } else { + andConditionGroupsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder clearAndConditionGroups() { + if (andConditionGroupsBuilder_ == null) { + andConditionGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + andConditionGroupsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder removeAndConditionGroups(int index) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.remove(index); + onChanged(); + } else { + andConditionGroupsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder + getAndConditionGroupsBuilder(int index) { + return getAndConditionGroupsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index) { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.get(index); + } else { + return andConditionGroupsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder> + getAndConditionGroupsOrBuilderList() { + if (andConditionGroupsBuilder_ != null) { + return andConditionGroupsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(andConditionGroups_); + } + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder + addAndConditionGroupsBuilder() { + return getAndConditionGroupsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.getDefaultInstance()); + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder + addAndConditionGroupsBuilder(int index) { + return getAndConditionGroupsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.getDefaultInstance()); + } + /** + * + * + *
+     * A session matches this criteria if the session matches each of these
+     * `andConditionGroups`.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List + getAndConditionGroupsBuilderList() { + return getAndConditionGroupsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder> + getAndConditionGroupsFieldBuilder() { + if (andConditionGroupsBuilder_ == null) { + andConditionGroupsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder>( + andConditionGroups_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + andConditionGroups_ = null; + } + return andConditionGroupsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SessionSegmentCriteria) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SessionSegmentCriteria) + private static final com.google.analytics.data.v1alpha.SessionSegmentCriteria DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SessionSegmentCriteria(); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentCriteria getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SessionSegmentCriteria parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SessionSegmentCriteria(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SessionSegmentCriteria getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteriaOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteriaOrBuilder.java new file mode 100644 index 00000000..c92545fb --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentCriteriaOrBuilder.java @@ -0,0 +1,94 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SessionSegmentCriteriaOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SessionSegmentCriteria) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + java.util.List + getAndConditionGroupsList(); + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + com.google.analytics.data.v1alpha.SessionSegmentConditionGroup getAndConditionGroups(int index); + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + int getAndConditionGroupsCount(); + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + java.util.List + getAndConditionGroupsOrBuilderList(); + /** + * + * + *
+   * A session matches this criteria if the session matches each of these
+   * `andConditionGroups`.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * + */ + com.google.analytics.data.v1alpha.SessionSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusion.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusion.java new file mode 100644 index 00000000..83a236a2 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusion.java @@ -0,0 +1,963 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Specifies which sessions are excluded in this segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegmentExclusion} + */ +public final class SessionSegmentExclusion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.SessionSegmentExclusion) + SessionSegmentExclusionOrBuilder { + private static final long serialVersionUID = 0L; + // Use SessionSegmentExclusion.newBuilder() to construct. + private SessionSegmentExclusion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SessionSegmentExclusion() { + sessionExclusionDuration_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SessionSegmentExclusion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SessionSegmentExclusion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + sessionExclusionDuration_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder subBuilder = null; + if (sessionExclusionCriteria_ != null) { + subBuilder = sessionExclusionCriteria_.toBuilder(); + } + sessionExclusionCriteria_ = + input.readMessage( + com.google.analytics.data.v1alpha.SessionSegmentCriteria.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(sessionExclusionCriteria_); + sessionExclusionCriteria_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegmentExclusion.class, + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder.class); + } + + public static final int SESSION_EXCLUSION_DURATION_FIELD_NUMBER = 1; + private int sessionExclusionDuration_; + /** + * + * + *
+   * Specifies how long an exclusion will last if a session matches the
+   * `sessionExclusionCriteria`.
+   * Optional. If unspecified, a `sessionExclusionDuration` of
+   * `SESSION_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for sessionExclusionDuration. + */ + @java.lang.Override + public int getSessionExclusionDurationValue() { + return sessionExclusionDuration_; + } + /** + * + * + *
+   * Specifies how long an exclusion will last if a session matches the
+   * `sessionExclusionCriteria`.
+   * Optional. If unspecified, a `sessionExclusionDuration` of
+   * `SESSION_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return The sessionExclusionDuration. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionExclusionDuration getSessionExclusionDuration() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.SessionExclusionDuration result = + com.google.analytics.data.v1alpha.SessionExclusionDuration.valueOf( + sessionExclusionDuration_); + return result == null + ? com.google.analytics.data.v1alpha.SessionExclusionDuration.UNRECOGNIZED + : result; + } + + public static final int SESSION_EXCLUSION_CRITERIA_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.SessionSegmentCriteria sessionExclusionCriteria_; + /** + * + * + *
+   * If a session meets this condition, the session is excluded from
+   * membership in the segment for the `sessionExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + * + * @return Whether the sessionExclusionCriteria field is set. + */ + @java.lang.Override + public boolean hasSessionExclusionCriteria() { + return sessionExclusionCriteria_ != null; + } + /** + * + * + *
+   * If a session meets this condition, the session is excluded from
+   * membership in the segment for the `sessionExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + * + * @return The sessionExclusionCriteria. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteria getSessionExclusionCriteria() { + return sessionExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance() + : sessionExclusionCriteria_; + } + /** + * + * + *
+   * If a session meets this condition, the session is excluded from
+   * membership in the segment for the `sessionExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder + getSessionExclusionCriteriaOrBuilder() { + return getSessionExclusionCriteria(); + } + + 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 (sessionExclusionDuration_ + != com.google.analytics.data.v1alpha.SessionExclusionDuration + .SESSION_EXCLUSION_DURATION_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, sessionExclusionDuration_); + } + if (sessionExclusionCriteria_ != null) { + output.writeMessage(2, getSessionExclusionCriteria()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (sessionExclusionDuration_ + != com.google.analytics.data.v1alpha.SessionExclusionDuration + .SESSION_EXCLUSION_DURATION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, sessionExclusionDuration_); + } + if (sessionExclusionCriteria_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, getSessionExclusionCriteria()); + } + size += unknownFields.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.analytics.data.v1alpha.SessionSegmentExclusion)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.SessionSegmentExclusion other = + (com.google.analytics.data.v1alpha.SessionSegmentExclusion) obj; + + if (sessionExclusionDuration_ != other.sessionExclusionDuration_) return false; + if (hasSessionExclusionCriteria() != other.hasSessionExclusionCriteria()) return false; + if (hasSessionExclusionCriteria()) { + if (!getSessionExclusionCriteria().equals(other.getSessionExclusionCriteria())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + SESSION_EXCLUSION_DURATION_FIELD_NUMBER; + hash = (53 * hash) + sessionExclusionDuration_; + if (hasSessionExclusionCriteria()) { + hash = (37 * hash) + SESSION_EXCLUSION_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getSessionExclusionCriteria().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion 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.analytics.data.v1alpha.SessionSegmentExclusion parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.SessionSegmentExclusion 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Specifies which sessions are excluded in this segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.SessionSegmentExclusion} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.SessionSegmentExclusion) + com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.SessionSegmentExclusion.class, + com.google.analytics.data.v1alpha.SessionSegmentExclusion.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.SessionSegmentExclusion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + sessionExclusionDuration_ = 0; + + if (sessionExclusionCriteriaBuilder_ == null) { + sessionExclusionCriteria_ = null; + } else { + sessionExclusionCriteria_ = null; + sessionExclusionCriteriaBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_SessionSegmentExclusion_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentExclusion getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.SessionSegmentExclusion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentExclusion build() { + com.google.analytics.data.v1alpha.SessionSegmentExclusion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionSegmentExclusion buildPartial() { + com.google.analytics.data.v1alpha.SessionSegmentExclusion result = + new com.google.analytics.data.v1alpha.SessionSegmentExclusion(this); + result.sessionExclusionDuration_ = sessionExclusionDuration_; + if (sessionExclusionCriteriaBuilder_ == null) { + result.sessionExclusionCriteria_ = sessionExclusionCriteria_; + } else { + result.sessionExclusionCriteria_ = sessionExclusionCriteriaBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.SessionSegmentExclusion) { + return mergeFrom((com.google.analytics.data.v1alpha.SessionSegmentExclusion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.SessionSegmentExclusion other) { + if (other == com.google.analytics.data.v1alpha.SessionSegmentExclusion.getDefaultInstance()) + return this; + if (other.sessionExclusionDuration_ != 0) { + setSessionExclusionDurationValue(other.getSessionExclusionDurationValue()); + } + if (other.hasSessionExclusionCriteria()) { + mergeSessionExclusionCriteria(other.getSessionExclusionCriteria()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.SessionSegmentExclusion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.SessionSegmentExclusion) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int sessionExclusionDuration_ = 0; + /** + * + * + *
+     * Specifies how long an exclusion will last if a session matches the
+     * `sessionExclusionCriteria`.
+     * Optional. If unspecified, a `sessionExclusionDuration` of
+     * `SESSION_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for sessionExclusionDuration. + */ + @java.lang.Override + public int getSessionExclusionDurationValue() { + return sessionExclusionDuration_; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a session matches the
+     * `sessionExclusionCriteria`.
+     * Optional. If unspecified, a `sessionExclusionDuration` of
+     * `SESSION_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @param value The enum numeric value on the wire for sessionExclusionDuration to set. + * @return This builder for chaining. + */ + public Builder setSessionExclusionDurationValue(int value) { + + sessionExclusionDuration_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a session matches the
+     * `sessionExclusionCriteria`.
+     * Optional. If unspecified, a `sessionExclusionDuration` of
+     * `SESSION_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return The sessionExclusionDuration. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SessionExclusionDuration + getSessionExclusionDuration() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.SessionExclusionDuration result = + com.google.analytics.data.v1alpha.SessionExclusionDuration.valueOf( + sessionExclusionDuration_); + return result == null + ? com.google.analytics.data.v1alpha.SessionExclusionDuration.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a session matches the
+     * `sessionExclusionCriteria`.
+     * Optional. If unspecified, a `sessionExclusionDuration` of
+     * `SESSION_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @param value The sessionExclusionDuration to set. + * @return This builder for chaining. + */ + public Builder setSessionExclusionDuration( + com.google.analytics.data.v1alpha.SessionExclusionDuration value) { + if (value == null) { + throw new NullPointerException(); + } + + sessionExclusionDuration_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a session matches the
+     * `sessionExclusionCriteria`.
+     * Optional. If unspecified, a `sessionExclusionDuration` of
+     * `SESSION_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return This builder for chaining. + */ + public Builder clearSessionExclusionDuration() { + + sessionExclusionDuration_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.SessionSegmentCriteria sessionExclusionCriteria_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentCriteria, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder> + sessionExclusionCriteriaBuilder_; + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + * + * @return Whether the sessionExclusionCriteria field is set. + */ + public boolean hasSessionExclusionCriteria() { + return sessionExclusionCriteriaBuilder_ != null || sessionExclusionCriteria_ != null; + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + * + * @return The sessionExclusionCriteria. + */ + public com.google.analytics.data.v1alpha.SessionSegmentCriteria getSessionExclusionCriteria() { + if (sessionExclusionCriteriaBuilder_ == null) { + return sessionExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance() + : sessionExclusionCriteria_; + } else { + return sessionExclusionCriteriaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + public Builder setSessionExclusionCriteria( + com.google.analytics.data.v1alpha.SessionSegmentCriteria value) { + if (sessionExclusionCriteriaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + sessionExclusionCriteria_ = value; + onChanged(); + } else { + sessionExclusionCriteriaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + public Builder setSessionExclusionCriteria( + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder builderForValue) { + if (sessionExclusionCriteriaBuilder_ == null) { + sessionExclusionCriteria_ = builderForValue.build(); + onChanged(); + } else { + sessionExclusionCriteriaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + public Builder mergeSessionExclusionCriteria( + com.google.analytics.data.v1alpha.SessionSegmentCriteria value) { + if (sessionExclusionCriteriaBuilder_ == null) { + if (sessionExclusionCriteria_ != null) { + sessionExclusionCriteria_ = + com.google.analytics.data.v1alpha.SessionSegmentCriteria.newBuilder( + sessionExclusionCriteria_) + .mergeFrom(value) + .buildPartial(); + } else { + sessionExclusionCriteria_ = value; + } + onChanged(); + } else { + sessionExclusionCriteriaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + public Builder clearSessionExclusionCriteria() { + if (sessionExclusionCriteriaBuilder_ == null) { + sessionExclusionCriteria_ = null; + onChanged(); + } else { + sessionExclusionCriteria_ = null; + sessionExclusionCriteriaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder + getSessionExclusionCriteriaBuilder() { + + onChanged(); + return getSessionExclusionCriteriaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + public com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder + getSessionExclusionCriteriaOrBuilder() { + if (sessionExclusionCriteriaBuilder_ != null) { + return sessionExclusionCriteriaBuilder_.getMessageOrBuilder(); + } else { + return sessionExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.SessionSegmentCriteria.getDefaultInstance() + : sessionExclusionCriteria_; + } + } + /** + * + * + *
+     * If a session meets this condition, the session is excluded from
+     * membership in the segment for the `sessionExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentCriteria, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder> + getSessionExclusionCriteriaFieldBuilder() { + if (sessionExclusionCriteriaBuilder_ == null) { + sessionExclusionCriteriaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SessionSegmentCriteria, + com.google.analytics.data.v1alpha.SessionSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder>( + getSessionExclusionCriteria(), getParentForChildren(), isClean()); + sessionExclusionCriteria_ = null; + } + return sessionExclusionCriteriaBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.SessionSegmentExclusion) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.SessionSegmentExclusion) + private static final com.google.analytics.data.v1alpha.SessionSegmentExclusion DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.SessionSegmentExclusion(); + } + + public static com.google.analytics.data.v1alpha.SessionSegmentExclusion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SessionSegmentExclusion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SessionSegmentExclusion(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.SessionSegmentExclusion getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusionOrBuilder.java new file mode 100644 index 00000000..53c8f593 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentExclusionOrBuilder.java @@ -0,0 +1,100 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SessionSegmentExclusionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SessionSegmentExclusion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Specifies how long an exclusion will last if a session matches the
+   * `sessionExclusionCriteria`.
+   * Optional. If unspecified, a `sessionExclusionDuration` of
+   * `SESSION_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for sessionExclusionDuration. + */ + int getSessionExclusionDurationValue(); + /** + * + * + *
+   * Specifies how long an exclusion will last if a session matches the
+   * `sessionExclusionCriteria`.
+   * Optional. If unspecified, a `sessionExclusionDuration` of
+   * `SESSION_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * + * + * @return The sessionExclusionDuration. + */ + com.google.analytics.data.v1alpha.SessionExclusionDuration getSessionExclusionDuration(); + + /** + * + * + *
+   * If a session meets this condition, the session is excluded from
+   * membership in the segment for the `sessionExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + * + * @return Whether the sessionExclusionCriteria field is set. + */ + boolean hasSessionExclusionCriteria(); + /** + * + * + *
+   * If a session meets this condition, the session is excluded from
+   * membership in the segment for the `sessionExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + * + * @return The sessionExclusionCriteria. + */ + com.google.analytics.data.v1alpha.SessionSegmentCriteria getSessionExclusionCriteria(); + /** + * + * + *
+   * If a session meets this condition, the session is excluded from
+   * membership in the segment for the `sessionExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * + */ + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder + getSessionExclusionCriteriaOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentOrBuilder.java new file mode 100644 index 00000000..fa600e30 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/SessionSegmentOrBuilder.java @@ -0,0 +1,99 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface SessionSegmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.SessionSegment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Defines which sessions are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + * + * @return Whether the sessionInclusionCriteria field is set. + */ + boolean hasSessionInclusionCriteria(); + /** + * + * + *
+   * Defines which sessions are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + * + * @return The sessionInclusionCriteria. + */ + com.google.analytics.data.v1alpha.SessionSegmentCriteria getSessionInclusionCriteria(); + /** + * + * + *
+   * Defines which sessions are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * + */ + com.google.analytics.data.v1alpha.SessionSegmentCriteriaOrBuilder + getSessionInclusionCriteriaOrBuilder(); + + /** + * + * + *
+   * Defines which sessions are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + boolean hasExclusion(); + /** + * + * + *
+   * Defines which sessions are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + com.google.analytics.data.v1alpha.SessionSegmentExclusion getExclusion(); + /** + * + * + *
+   * Defines which sessions are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + com.google.analytics.data.v1alpha.SessionSegmentExclusionOrBuilder getExclusionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilter.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilter.java new file mode 100644 index 00000000..18da13e9 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilter.java @@ -0,0 +1,1129 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * The filter for string
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.StringFilter} + */ +public final class StringFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.StringFilter) + StringFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use StringFilter.newBuilder() to construct. + private StringFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private StringFilter() { + matchType_ = 0; + value_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StringFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private StringFilter( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + matchType_ = rawValue; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + value_ = s; + break; + } + case 24: + { + caseSensitive_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_StringFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_StringFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.StringFilter.class, + com.google.analytics.data.v1alpha.StringFilter.Builder.class); + } + + /** + * + * + *
+   * The match type of a string filter
+   * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.StringFilter.MatchType} + */ + public enum MatchType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified
+     * 
+ * + * MATCH_TYPE_UNSPECIFIED = 0; + */ + MATCH_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * Exact match of the string value.
+     * 
+ * + * EXACT = 1; + */ + EXACT(1), + /** + * + * + *
+     * Begins with the string value.
+     * 
+ * + * BEGINS_WITH = 2; + */ + BEGINS_WITH(2), + /** + * + * + *
+     * Ends with the string value.
+     * 
+ * + * ENDS_WITH = 3; + */ + ENDS_WITH(3), + /** + * + * + *
+     * Contains the string value.
+     * 
+ * + * CONTAINS = 4; + */ + CONTAINS(4), + /** + * + * + *
+     * Full match for the regular expression with the string value.
+     * 
+ * + * FULL_REGEXP = 5; + */ + FULL_REGEXP(5), + /** + * + * + *
+     * Partial match for the regular expression with the string value.
+     * 
+ * + * PARTIAL_REGEXP = 6; + */ + PARTIAL_REGEXP(6), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unspecified
+     * 
+ * + * MATCH_TYPE_UNSPECIFIED = 0; + */ + public static final int MATCH_TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * Exact match of the string value.
+     * 
+ * + * EXACT = 1; + */ + public static final int EXACT_VALUE = 1; + /** + * + * + *
+     * Begins with the string value.
+     * 
+ * + * BEGINS_WITH = 2; + */ + public static final int BEGINS_WITH_VALUE = 2; + /** + * + * + *
+     * Ends with the string value.
+     * 
+ * + * ENDS_WITH = 3; + */ + public static final int ENDS_WITH_VALUE = 3; + /** + * + * + *
+     * Contains the string value.
+     * 
+ * + * CONTAINS = 4; + */ + public static final int CONTAINS_VALUE = 4; + /** + * + * + *
+     * Full match for the regular expression with the string value.
+     * 
+ * + * FULL_REGEXP = 5; + */ + public static final int FULL_REGEXP_VALUE = 5; + /** + * + * + *
+     * Partial match for the regular expression with the string value.
+     * 
+ * + * PARTIAL_REGEXP = 6; + */ + public static final int PARTIAL_REGEXP_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 MatchType 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 MatchType forNumber(int value) { + switch (value) { + case 0: + return MATCH_TYPE_UNSPECIFIED; + case 1: + return EXACT; + case 2: + return BEGINS_WITH; + case 3: + return ENDS_WITH; + case 4: + return CONTAINS; + case 5: + return FULL_REGEXP; + case 6: + return PARTIAL_REGEXP; + 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 MatchType findValueByNumber(int number) { + return MatchType.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.StringFilter.getDescriptor().getEnumTypes().get(0); + } + + private static final MatchType[] VALUES = values(); + + public static MatchType 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 MatchType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.StringFilter.MatchType) + } + + public static final int MATCH_TYPE_FIELD_NUMBER = 1; + private int matchType_; + /** + * + * + *
+   * The match type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return The enum numeric value on the wire for matchType. + */ + @java.lang.Override + public int getMatchTypeValue() { + return matchType_; + } + /** + * + * + *
+   * The match type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return The matchType. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter.MatchType getMatchType() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.StringFilter.MatchType result = + com.google.analytics.data.v1alpha.StringFilter.MatchType.valueOf(matchType_); + return result == null + ? com.google.analytics.data.v1alpha.StringFilter.MatchType.UNRECOGNIZED + : result; + } + + public static final int VALUE_FIELD_NUMBER = 2; + private volatile java.lang.Object value_; + /** + * + * + *
+   * The string value used for the matching.
+   * 
+ * + * 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 string value used for the matching.
+   * 
+ * + * 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 CASE_SENSITIVE_FIELD_NUMBER = 3; + private boolean caseSensitive_; + /** + * + * + *
+   * If true, the string value is case sensitive.
+   * 
+ * + * bool case_sensitive = 3; + * + * @return The caseSensitive. + */ + @java.lang.Override + public boolean getCaseSensitive() { + return caseSensitive_; + } + + 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 (matchType_ + != com.google.analytics.data.v1alpha.StringFilter.MatchType.MATCH_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, matchType_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(value_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, value_); + } + if (caseSensitive_ != false) { + output.writeBool(3, caseSensitive_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (matchType_ + != com.google.analytics.data.v1alpha.StringFilter.MatchType.MATCH_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, matchType_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(value_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, value_); + } + if (caseSensitive_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, caseSensitive_); + } + size += unknownFields.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.analytics.data.v1alpha.StringFilter)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.StringFilter other = + (com.google.analytics.data.v1alpha.StringFilter) obj; + + if (matchType_ != other.matchType_) return false; + if (!getValue().equals(other.getValue())) return false; + if (getCaseSensitive() != other.getCaseSensitive()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + MATCH_TYPE_FIELD_NUMBER; + hash = (53 * hash) + matchType_; + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + hash = (37 * hash) + CASE_SENSITIVE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getCaseSensitive()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.StringFilter 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.analytics.data.v1alpha.StringFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.StringFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.StringFilter 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The filter for string
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.StringFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.StringFilter) + com.google.analytics.data.v1alpha.StringFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_StringFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_StringFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.StringFilter.class, + com.google.analytics.data.v1alpha.StringFilter.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.StringFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + matchType_ = 0; + + value_ = ""; + + caseSensitive_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_StringFilter_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter build() { + com.google.analytics.data.v1alpha.StringFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter buildPartial() { + com.google.analytics.data.v1alpha.StringFilter result = + new com.google.analytics.data.v1alpha.StringFilter(this); + result.matchType_ = matchType_; + result.value_ = value_; + result.caseSensitive_ = caseSensitive_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.StringFilter) { + return mergeFrom((com.google.analytics.data.v1alpha.StringFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.StringFilter other) { + if (other == com.google.analytics.data.v1alpha.StringFilter.getDefaultInstance()) return this; + if (other.matchType_ != 0) { + setMatchTypeValue(other.getMatchTypeValue()); + } + if (!other.getValue().isEmpty()) { + value_ = other.value_; + onChanged(); + } + if (other.getCaseSensitive() != false) { + setCaseSensitive(other.getCaseSensitive()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.StringFilter parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.StringFilter) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int matchType_ = 0; + /** + * + * + *
+     * The match type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return The enum numeric value on the wire for matchType. + */ + @java.lang.Override + public int getMatchTypeValue() { + return matchType_; + } + /** + * + * + *
+     * The match type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @param value The enum numeric value on the wire for matchType to set. + * @return This builder for chaining. + */ + public Builder setMatchTypeValue(int value) { + + matchType_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The match type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return The matchType. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.StringFilter.MatchType getMatchType() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.StringFilter.MatchType result = + com.google.analytics.data.v1alpha.StringFilter.MatchType.valueOf(matchType_); + return result == null + ? com.google.analytics.data.v1alpha.StringFilter.MatchType.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * The match type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @param value The matchType to set. + * @return This builder for chaining. + */ + public Builder setMatchType(com.google.analytics.data.v1alpha.StringFilter.MatchType value) { + if (value == null) { + throw new NullPointerException(); + } + + matchType_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The match type for this filter.
+     * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return This builder for chaining. + */ + public Builder clearMatchType() { + + matchType_ = 0; + onChanged(); + return this; + } + + private java.lang.Object value_ = ""; + /** + * + * + *
+     * The string value used for the matching.
+     * 
+ * + * 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 string value used for the matching.
+     * 
+ * + * 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 string value used for the matching.
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The string value used for the matching.
+     * 
+ * + * string value = 2; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + + value_ = getDefaultInstance().getValue(); + onChanged(); + return this; + } + /** + * + * + *
+     * The string value used for the matching.
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private boolean caseSensitive_; + /** + * + * + *
+     * If true, the string value is case sensitive.
+     * 
+ * + * bool case_sensitive = 3; + * + * @return The caseSensitive. + */ + @java.lang.Override + public boolean getCaseSensitive() { + return caseSensitive_; + } + /** + * + * + *
+     * If true, the string value is case sensitive.
+     * 
+ * + * bool case_sensitive = 3; + * + * @param value The caseSensitive to set. + * @return This builder for chaining. + */ + public Builder setCaseSensitive(boolean value) { + + caseSensitive_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If true, the string value is case sensitive.
+     * 
+ * + * bool case_sensitive = 3; + * + * @return This builder for chaining. + */ + public Builder clearCaseSensitive() { + + caseSensitive_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.StringFilter) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.StringFilter) + private static final com.google.analytics.data.v1alpha.StringFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.StringFilter(); + } + + public static com.google.analytics.data.v1alpha.StringFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StringFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new StringFilter(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.StringFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilterOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilterOrBuilder.java new file mode 100644 index 00000000..ad6ee584 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/StringFilterOrBuilder.java @@ -0,0 +1,88 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface StringFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.StringFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The match type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return The enum numeric value on the wire for matchType. + */ + int getMatchTypeValue(); + /** + * + * + *
+   * The match type for this filter.
+   * 
+ * + * .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * + * @return The matchType. + */ + com.google.analytics.data.v1alpha.StringFilter.MatchType getMatchType(); + + /** + * + * + *
+   * The string value used for the matching.
+   * 
+ * + * string value = 2; + * + * @return The value. + */ + java.lang.String getValue(); + /** + * + * + *
+   * The string value used for the matching.
+   * 
+ * + * string value = 2; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); + + /** + * + * + *
+   * If true, the string value is case sensitive.
+   * 
+ * + * bool case_sensitive = 3; + * + * @return The caseSensitive. + */ + boolean getCaseSensitive(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserCriteriaScoping.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserCriteriaScoping.java new file mode 100644 index 00000000..78ed5df3 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserCriteriaScoping.java @@ -0,0 +1,210 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Scoping specifies which events are considered when evaluating if a user
+ * meets a criteria.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.UserCriteriaScoping} + */ +public enum UserCriteriaScoping implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified criteria scoping. Do not specify.
+   * 
+ * + * USER_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + USER_CRITERIA_SCOPING_UNSPECIFIED(0), + /** + * + * + *
+   * If the criteria is satisfied within one event, the user matches the
+   * criteria.
+   * 
+ * + * USER_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + USER_CRITERIA_WITHIN_SAME_EVENT(1), + /** + * + * + *
+   * If the criteria is satisfied within one session, the user matches the
+   * criteria.
+   * 
+ * + * USER_CRITERIA_WITHIN_SAME_SESSION = 2; + */ + USER_CRITERIA_WITHIN_SAME_SESSION(2), + /** + * + * + *
+   * If the criteria is satisfied by any events for the user, the user
+   * matches the criteria.
+   * 
+ * + * USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; + */ + USER_CRITERIA_ACROSS_ALL_SESSIONS(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified criteria scoping. Do not specify.
+   * 
+ * + * USER_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + public static final int USER_CRITERIA_SCOPING_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * If the criteria is satisfied within one event, the user matches the
+   * criteria.
+   * 
+ * + * USER_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + public static final int USER_CRITERIA_WITHIN_SAME_EVENT_VALUE = 1; + /** + * + * + *
+   * If the criteria is satisfied within one session, the user matches the
+   * criteria.
+   * 
+ * + * USER_CRITERIA_WITHIN_SAME_SESSION = 2; + */ + public static final int USER_CRITERIA_WITHIN_SAME_SESSION_VALUE = 2; + /** + * + * + *
+   * If the criteria is satisfied by any events for the user, the user
+   * matches the criteria.
+   * 
+ * + * USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; + */ + public static final int USER_CRITERIA_ACROSS_ALL_SESSIONS_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 UserCriteriaScoping 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 UserCriteriaScoping forNumber(int value) { + switch (value) { + case 0: + return USER_CRITERIA_SCOPING_UNSPECIFIED; + case 1: + return USER_CRITERIA_WITHIN_SAME_EVENT; + case 2: + return USER_CRITERIA_WITHIN_SAME_SESSION; + case 3: + return USER_CRITERIA_ACROSS_ALL_SESSIONS; + 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 UserCriteriaScoping findValueByNumber(int number) { + return UserCriteriaScoping.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final UserCriteriaScoping[] VALUES = values(); + + public static UserCriteriaScoping 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 UserCriteriaScoping(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.UserCriteriaScoping) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserExclusionDuration.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserExclusionDuration.java new file mode 100644 index 00000000..50c10f56 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserExclusionDuration.java @@ -0,0 +1,186 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Enumerates options for how long an exclusion will last if a user matches
+ * the `userExclusionCriteria`.
+ * 
+ * + * Protobuf enum {@code google.analytics.data.v1alpha.UserExclusionDuration} + */ +public enum UserExclusionDuration implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified exclusion duration. Do not specify.
+   * 
+ * + * USER_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + USER_EXCLUSION_DURATION_UNSPECIFIED(0), + /** + * + * + *
+   * Temporarily exclude users from the segment during periods when the
+   * user meets the `userExclusionCriteria` condition.
+   * 
+ * + * USER_EXCLUSION_TEMPORARY = 1; + */ + USER_EXCLUSION_TEMPORARY(1), + /** + * + * + *
+   * Permanently exclude users from the segment if the user ever meets the
+   * `userExclusionCriteria` condition.
+   * 
+ * + * USER_EXCLUSION_PERMANENT = 2; + */ + USER_EXCLUSION_PERMANENT(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Unspecified exclusion duration. Do not specify.
+   * 
+ * + * USER_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + public static final int USER_EXCLUSION_DURATION_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * Temporarily exclude users from the segment during periods when the
+   * user meets the `userExclusionCriteria` condition.
+   * 
+ * + * USER_EXCLUSION_TEMPORARY = 1; + */ + public static final int USER_EXCLUSION_TEMPORARY_VALUE = 1; + /** + * + * + *
+   * Permanently exclude users from the segment if the user ever meets the
+   * `userExclusionCriteria` condition.
+   * 
+ * + * USER_EXCLUSION_PERMANENT = 2; + */ + public static final int USER_EXCLUSION_PERMANENT_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 UserExclusionDuration 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 UserExclusionDuration forNumber(int value) { + switch (value) { + case 0: + return USER_EXCLUSION_DURATION_UNSPECIFIED; + case 1: + return USER_EXCLUSION_TEMPORARY; + case 2: + return USER_EXCLUSION_PERMANENT; + 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 UserExclusionDuration findValueByNumber(int number) { + return UserExclusionDuration.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final UserExclusionDuration[] VALUES = values(); + + public static UserExclusionDuration 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 UserExclusionDuration(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.analytics.data.v1alpha.UserExclusionDuration) +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegment.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegment.java new file mode 100644 index 00000000..36ca8735 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegment.java @@ -0,0 +1,1025 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * User segments are subsets of users who engaged with your site or app. For
+ * example, users who have previously purchased; users who added items to their
+ * shopping carts, but didn’t complete a purchase.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegment} + */ +public final class UserSegment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.UserSegment) + UserSegmentOrBuilder { + private static final long serialVersionUID = 0L; + // Use UserSegment.newBuilder() to construct. + private UserSegment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UserSegment() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UserSegment(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UserSegment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder subBuilder = null; + if (userInclusionCriteria_ != null) { + subBuilder = userInclusionCriteria_.toBuilder(); + } + userInclusionCriteria_ = + input.readMessage( + com.google.analytics.data.v1alpha.UserSegmentCriteria.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(userInclusionCriteria_); + userInclusionCriteria_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder subBuilder = null; + if (exclusion_ != null) { + subBuilder = exclusion_.toBuilder(); + } + exclusion_ = + input.readMessage( + com.google.analytics.data.v1alpha.UserSegmentExclusion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(exclusion_); + exclusion_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegment.class, + com.google.analytics.data.v1alpha.UserSegment.Builder.class); + } + + public static final int USER_INCLUSION_CRITERIA_FIELD_NUMBER = 1; + private com.google.analytics.data.v1alpha.UserSegmentCriteria userInclusionCriteria_; + /** + * + * + *
+   * Defines which users are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * + * @return Whether the userInclusionCriteria field is set. + */ + @java.lang.Override + public boolean hasUserInclusionCriteria() { + return userInclusionCriteria_ != null; + } + /** + * + * + *
+   * Defines which users are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * + * @return The userInclusionCriteria. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteria getUserInclusionCriteria() { + return userInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance() + : userInclusionCriteria_; + } + /** + * + * + *
+   * Defines which users are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder + getUserInclusionCriteriaOrBuilder() { + return getUserInclusionCriteria(); + } + + public static final int EXCLUSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.UserSegmentExclusion exclusion_; + /** + * + * + *
+   * Defines which users are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + @java.lang.Override + public boolean hasExclusion() { + return exclusion_ != null; + } + /** + * + * + *
+   * Defines which users are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentExclusion getExclusion() { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.UserSegmentExclusion.getDefaultInstance() + : exclusion_; + } + /** + * + * + *
+   * Defines which users are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder getExclusionOrBuilder() { + return getExclusion(); + } + + 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 (userInclusionCriteria_ != null) { + output.writeMessage(1, getUserInclusionCriteria()); + } + if (exclusion_ != null) { + output.writeMessage(2, getExclusion()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (userInclusionCriteria_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, getUserInclusionCriteria()); + } + if (exclusion_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getExclusion()); + } + size += unknownFields.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.analytics.data.v1alpha.UserSegment)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.UserSegment other = + (com.google.analytics.data.v1alpha.UserSegment) obj; + + if (hasUserInclusionCriteria() != other.hasUserInclusionCriteria()) return false; + if (hasUserInclusionCriteria()) { + if (!getUserInclusionCriteria().equals(other.getUserInclusionCriteria())) return false; + } + if (hasExclusion() != other.hasExclusion()) return false; + if (hasExclusion()) { + if (!getExclusion().equals(other.getExclusion())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasUserInclusionCriteria()) { + hash = (37 * hash) + USER_INCLUSION_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getUserInclusionCriteria().hashCode(); + } + if (hasExclusion()) { + hash = (37 * hash) + EXCLUSION_FIELD_NUMBER; + hash = (53 * hash) + getExclusion().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegment 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.analytics.data.v1alpha.UserSegment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegment parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.UserSegment 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * User segments are subsets of users who engaged with your site or app. For
+   * example, users who have previously purchased; users who added items to their
+   * shopping carts, but didn’t complete a purchase.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.UserSegment) + com.google.analytics.data.v1alpha.UserSegmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegment.class, + com.google.analytics.data.v1alpha.UserSegment.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.UserSegment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (userInclusionCriteriaBuilder_ == null) { + userInclusionCriteria_ = null; + } else { + userInclusionCriteria_ = null; + userInclusionCriteriaBuilder_ = null; + } + if (exclusionBuilder_ == null) { + exclusion_ = null; + } else { + exclusion_ = null; + exclusionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegment_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegment getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegment build() { + com.google.analytics.data.v1alpha.UserSegment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegment buildPartial() { + com.google.analytics.data.v1alpha.UserSegment result = + new com.google.analytics.data.v1alpha.UserSegment(this); + if (userInclusionCriteriaBuilder_ == null) { + result.userInclusionCriteria_ = userInclusionCriteria_; + } else { + result.userInclusionCriteria_ = userInclusionCriteriaBuilder_.build(); + } + if (exclusionBuilder_ == null) { + result.exclusion_ = exclusion_; + } else { + result.exclusion_ = exclusionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.UserSegment) { + return mergeFrom((com.google.analytics.data.v1alpha.UserSegment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.UserSegment other) { + if (other == com.google.analytics.data.v1alpha.UserSegment.getDefaultInstance()) return this; + if (other.hasUserInclusionCriteria()) { + mergeUserInclusionCriteria(other.getUserInclusionCriteria()); + } + if (other.hasExclusion()) { + mergeExclusion(other.getExclusion()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.UserSegment parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.analytics.data.v1alpha.UserSegment) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.analytics.data.v1alpha.UserSegmentCriteria userInclusionCriteria_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentCriteria, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder> + userInclusionCriteriaBuilder_; + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * + * @return Whether the userInclusionCriteria field is set. + */ + public boolean hasUserInclusionCriteria() { + return userInclusionCriteriaBuilder_ != null || userInclusionCriteria_ != null; + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * + * @return The userInclusionCriteria. + */ + public com.google.analytics.data.v1alpha.UserSegmentCriteria getUserInclusionCriteria() { + if (userInclusionCriteriaBuilder_ == null) { + return userInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance() + : userInclusionCriteria_; + } else { + return userInclusionCriteriaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + public Builder setUserInclusionCriteria( + com.google.analytics.data.v1alpha.UserSegmentCriteria value) { + if (userInclusionCriteriaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + userInclusionCriteria_ = value; + onChanged(); + } else { + userInclusionCriteriaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + public Builder setUserInclusionCriteria( + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder builderForValue) { + if (userInclusionCriteriaBuilder_ == null) { + userInclusionCriteria_ = builderForValue.build(); + onChanged(); + } else { + userInclusionCriteriaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + public Builder mergeUserInclusionCriteria( + com.google.analytics.data.v1alpha.UserSegmentCriteria value) { + if (userInclusionCriteriaBuilder_ == null) { + if (userInclusionCriteria_ != null) { + userInclusionCriteria_ = + com.google.analytics.data.v1alpha.UserSegmentCriteria.newBuilder( + userInclusionCriteria_) + .mergeFrom(value) + .buildPartial(); + } else { + userInclusionCriteria_ = value; + } + onChanged(); + } else { + userInclusionCriteriaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + public Builder clearUserInclusionCriteria() { + if (userInclusionCriteriaBuilder_ == null) { + userInclusionCriteria_ = null; + onChanged(); + } else { + userInclusionCriteria_ = null; + userInclusionCriteriaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + public com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder + getUserInclusionCriteriaBuilder() { + + onChanged(); + return getUserInclusionCriteriaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + public com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder + getUserInclusionCriteriaOrBuilder() { + if (userInclusionCriteriaBuilder_ != null) { + return userInclusionCriteriaBuilder_.getMessageOrBuilder(); + } else { + return userInclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance() + : userInclusionCriteria_; + } + } + /** + * + * + *
+     * Defines which users are included in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentCriteria, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder> + getUserInclusionCriteriaFieldBuilder() { + if (userInclusionCriteriaBuilder_ == null) { + userInclusionCriteriaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentCriteria, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder>( + getUserInclusionCriteria(), getParentForChildren(), isClean()); + userInclusionCriteria_ = null; + } + return userInclusionCriteriaBuilder_; + } + + private com.google.analytics.data.v1alpha.UserSegmentExclusion exclusion_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentExclusion, + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder> + exclusionBuilder_; + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + public boolean hasExclusion() { + return exclusionBuilder_ != null || exclusion_ != null; + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + public com.google.analytics.data.v1alpha.UserSegmentExclusion getExclusion() { + if (exclusionBuilder_ == null) { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.UserSegmentExclusion.getDefaultInstance() + : exclusion_; + } else { + return exclusionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + public Builder setExclusion(com.google.analytics.data.v1alpha.UserSegmentExclusion value) { + if (exclusionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + exclusion_ = value; + onChanged(); + } else { + exclusionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + public Builder setExclusion( + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder builderForValue) { + if (exclusionBuilder_ == null) { + exclusion_ = builderForValue.build(); + onChanged(); + } else { + exclusionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + public Builder mergeExclusion(com.google.analytics.data.v1alpha.UserSegmentExclusion value) { + if (exclusionBuilder_ == null) { + if (exclusion_ != null) { + exclusion_ = + com.google.analytics.data.v1alpha.UserSegmentExclusion.newBuilder(exclusion_) + .mergeFrom(value) + .buildPartial(); + } else { + exclusion_ = value; + } + onChanged(); + } else { + exclusionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + public Builder clearExclusion() { + if (exclusionBuilder_ == null) { + exclusion_ = null; + onChanged(); + } else { + exclusion_ = null; + exclusionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + public com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder getExclusionBuilder() { + + onChanged(); + return getExclusionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + public com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder getExclusionOrBuilder() { + if (exclusionBuilder_ != null) { + return exclusionBuilder_.getMessageOrBuilder(); + } else { + return exclusion_ == null + ? com.google.analytics.data.v1alpha.UserSegmentExclusion.getDefaultInstance() + : exclusion_; + } + } + /** + * + * + *
+     * Defines which users are excluded in this segment. Optional.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentExclusion, + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder> + getExclusionFieldBuilder() { + if (exclusionBuilder_ == null) { + exclusionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentExclusion, + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder, + com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder>( + getExclusion(), getParentForChildren(), isClean()); + exclusion_ = null; + } + return exclusionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.UserSegment) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.UserSegment) + private static final com.google.analytics.data.v1alpha.UserSegment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.UserSegment(); + } + + public static com.google.analytics.data.v1alpha.UserSegment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UserSegment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UserSegment(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.UserSegment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroup.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroup.java new file mode 100644 index 00000000..9be45faa --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroup.java @@ -0,0 +1,1020 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Conditions tell Analytics what data to include in or exclude from the
+ * segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentConditionGroup} + */ +public final class UserSegmentConditionGroup extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.UserSegmentConditionGroup) + UserSegmentConditionGroupOrBuilder { + private static final long serialVersionUID = 0L; + // Use UserSegmentConditionGroup.newBuilder() to construct. + private UserSegmentConditionGroup(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UserSegmentConditionGroup() { + conditionScoping_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UserSegmentConditionGroup(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UserSegmentConditionGroup( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + conditionScoping_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder subBuilder = null; + if (segmentFilterExpression_ != null) { + subBuilder = segmentFilterExpression_.toBuilder(); + } + segmentFilterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(segmentFilterExpression_); + segmentFilterExpression_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.class, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder.class); + } + + public static final int CONDITION_SCOPING_FIELD_NUMBER = 1; + private int conditionScoping_; + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this user. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+   * event, and then, the condition group is determined to be matched or not for
+   * this user.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + @java.lang.Override + public int getConditionScopingValue() { + return conditionScoping_; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this user. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+   * event, and then, the condition group is determined to be matched or not for
+   * this user.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserCriteriaScoping getConditionScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserCriteriaScoping result = + com.google.analytics.data.v1alpha.UserCriteriaScoping.valueOf(conditionScoping_); + return result == null + ? com.google.analytics.data.v1alpha.UserCriteriaScoping.UNRECOGNIZED + : result; + } + + public static final int SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + @java.lang.Override + public boolean hasSegmentFilterExpression() { + return segmentFilterExpression_ != null; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + return getSegmentFilterExpression(); + } + + 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 (conditionScoping_ + != com.google.analytics.data.v1alpha.UserCriteriaScoping.USER_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, conditionScoping_); + } + if (segmentFilterExpression_ != null) { + output.writeMessage(2, getSegmentFilterExpression()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (conditionScoping_ + != com.google.analytics.data.v1alpha.UserCriteriaScoping.USER_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, conditionScoping_); + } + if (segmentFilterExpression_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSegmentFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.UserSegmentConditionGroup)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.UserSegmentConditionGroup other = + (com.google.analytics.data.v1alpha.UserSegmentConditionGroup) obj; + + if (conditionScoping_ != other.conditionScoping_) return false; + if (hasSegmentFilterExpression() != other.hasSegmentFilterExpression()) return false; + if (hasSegmentFilterExpression()) { + if (!getSegmentFilterExpression().equals(other.getSegmentFilterExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + CONDITION_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + conditionScoping_; + if (hasSegmentFilterExpression()) { + hash = (37 * hash) + SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getSegmentFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup 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.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.UserSegmentConditionGroup 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Conditions tell Analytics what data to include in or exclude from the
+   * segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentConditionGroup} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.UserSegmentConditionGroup) + com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.class, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.UserSegmentConditionGroup.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + conditionScoping_ = 0; + + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentConditionGroup_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.UserSegmentConditionGroup.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup build() { + com.google.analytics.data.v1alpha.UserSegmentConditionGroup result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup buildPartial() { + com.google.analytics.data.v1alpha.UserSegmentConditionGroup result = + new com.google.analytics.data.v1alpha.UserSegmentConditionGroup(this); + result.conditionScoping_ = conditionScoping_; + if (segmentFilterExpressionBuilder_ == null) { + result.segmentFilterExpression_ = segmentFilterExpression_; + } else { + result.segmentFilterExpression_ = segmentFilterExpressionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.UserSegmentConditionGroup) { + return mergeFrom((com.google.analytics.data.v1alpha.UserSegmentConditionGroup) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.UserSegmentConditionGroup other) { + if (other == com.google.analytics.data.v1alpha.UserSegmentConditionGroup.getDefaultInstance()) + return this; + if (other.conditionScoping_ != 0) { + setConditionScopingValue(other.getConditionScopingValue()); + } + if (other.hasSegmentFilterExpression()) { + mergeSegmentFilterExpression(other.getSegmentFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.UserSegmentConditionGroup parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.UserSegmentConditionGroup) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int conditionScoping_ = 0; + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this user. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+     * event, and then, the condition group is determined to be matched or not for
+     * this user.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + @java.lang.Override + public int getConditionScopingValue() { + return conditionScoping_; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this user. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+     * event, and then, the condition group is determined to be matched or not for
+     * this user.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @param value The enum numeric value on the wire for conditionScoping to set. + * @return This builder for chaining. + */ + public Builder setConditionScopingValue(int value) { + + conditionScoping_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this user. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+     * event, and then, the condition group is determined to be matched or not for
+     * this user.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserCriteriaScoping getConditionScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserCriteriaScoping result = + com.google.analytics.data.v1alpha.UserCriteriaScoping.valueOf(conditionScoping_); + return result == null + ? com.google.analytics.data.v1alpha.UserCriteriaScoping.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this user. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+     * event, and then, the condition group is determined to be matched or not for
+     * this user.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @param value The conditionScoping to set. + * @return This builder for chaining. + */ + public Builder setConditionScoping( + com.google.analytics.data.v1alpha.UserCriteriaScoping value) { + if (value == null) { + throw new NullPointerException(); + } + + conditionScoping_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * the condition group. This scoping defines how many events the
+     * `segmentFilterExpression` is evaluated on before the condition group
+     * is determined to be matched or not. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+     * events in a session, and then, the condition group is determined to be
+     * matched or not for this user. For example if `conditionScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+     * event, and then, the condition group is determined to be matched or not for
+     * this user.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return This builder for chaining. + */ + public Builder clearConditionScoping() { + + conditionScoping_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + segmentFilterExpressionBuilder_; + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + public boolean hasSegmentFilterExpression() { + return segmentFilterExpressionBuilder_ != null || segmentFilterExpression_ != null; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } else { + return segmentFilterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + segmentFilterExpression_ = value; + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = builderForValue.build(); + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder mergeSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (segmentFilterExpression_ != null) { + segmentFilterExpression_ = + com.google.analytics.data.v1alpha.SegmentFilterExpression.newBuilder( + segmentFilterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + segmentFilterExpression_ = value; + } + onChanged(); + } else { + segmentFilterExpressionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public Builder clearSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + onChanged(); + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder + getSegmentFilterExpressionBuilder() { + + onChanged(); + return getSegmentFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + if (segmentFilterExpressionBuilder_ != null) { + return segmentFilterExpressionBuilder_.getMessageOrBuilder(); + } else { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + } + /** + * + * + *
+     * Data is included or excluded from the segment based on if it matches
+     * this expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getSegmentFilterExpressionFieldBuilder() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder>( + getSegmentFilterExpression(), getParentForChildren(), isClean()); + segmentFilterExpression_ = null; + } + return segmentFilterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.UserSegmentConditionGroup) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.UserSegmentConditionGroup) + private static final com.google.analytics.data.v1alpha.UserSegmentConditionGroup DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.UserSegmentConditionGroup(); + } + + public static com.google.analytics.data.v1alpha.UserSegmentConditionGroup getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UserSegmentConditionGroup parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UserSegmentConditionGroup(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.UserSegmentConditionGroup getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroupOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroupOrBuilder.java new file mode 100644 index 00000000..69c56dae --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentConditionGroupOrBuilder.java @@ -0,0 +1,117 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface UserSegmentConditionGroupOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.UserSegmentConditionGroup) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this user. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+   * event, and then, the condition group is determined to be matched or not for
+   * this user.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return The enum numeric value on the wire for conditionScoping. + */ + int getConditionScopingValue(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * the condition group. This scoping defines how many events the
+   * `segmentFilterExpression` is evaluated on before the condition group
+   * is determined to be matched or not. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all
+   * events in a session, and then, the condition group is determined to be
+   * matched or not for this user. For example if `conditionScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single
+   * event, and then, the condition group is determined to be matched or not for
+   * this user.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * + * @return The conditionScoping. + */ + com.google.analytics.data.v1alpha.UserCriteriaScoping getConditionScoping(); + + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + boolean hasSegmentFilterExpression(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + * + * @return The segmentFilterExpression. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression(); + /** + * + * + *
+   * Data is included or excluded from the segment based on if it matches
+   * this expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteria.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteria.java new file mode 100644 index 00000000..8fe0780d --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteria.java @@ -0,0 +1,1682 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A user matches a criteria if the user's events meet the conditions in the
+ * criteria.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentCriteria} + */ +public final class UserSegmentCriteria extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.UserSegmentCriteria) + UserSegmentCriteriaOrBuilder { + private static final long serialVersionUID = 0L; + // Use UserSegmentCriteria.newBuilder() to construct. + private UserSegmentCriteria(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UserSegmentCriteria() { + andConditionGroups_ = java.util.Collections.emptyList(); + andSequenceGroups_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UserSegmentCriteria(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UserSegmentCriteria( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.UserSegmentConditionGroup>(); + mutable_bitField0_ |= 0x00000001; + } + andConditionGroups_.add( + input.readMessage( + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.parser(), + extensionRegistry)); + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + andSequenceGroups_ = + new java.util.ArrayList< + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup>(); + mutable_bitField0_ |= 0x00000002; + } + andSequenceGroups_.add( + input.readMessage( + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = java.util.Collections.unmodifiableList(andConditionGroups_); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + andSequenceGroups_ = java.util.Collections.unmodifiableList(andSequenceGroups_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentCriteria.class, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder.class); + } + + public static final int AND_CONDITION_GROUPS_FIELD_NUMBER = 1; + private java.util.List + andConditionGroups_; + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public java.util.List + getAndConditionGroupsList() { + return andConditionGroups_; + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder> + getAndConditionGroupsOrBuilderList() { + return andConditionGroups_; + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public int getAndConditionGroupsCount() { + return andConditionGroups_.size(); + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup getAndConditionGroups( + int index) { + return andConditionGroups_.get(index); + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index) { + return andConditionGroups_.get(index); + } + + public static final int AND_SEQUENCE_GROUPS_FIELD_NUMBER = 2; + private java.util.List + andSequenceGroups_; + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + @java.lang.Override + public java.util.List + getAndSequenceGroupsList() { + return andSequenceGroups_; + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder> + getAndSequenceGroupsOrBuilderList() { + return andSequenceGroups_; + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + @java.lang.Override + public int getAndSequenceGroupsCount() { + return andSequenceGroups_.size(); + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup getAndSequenceGroups( + int index) { + return andSequenceGroups_.get(index); + } + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder + getAndSequenceGroupsOrBuilder(int index) { + return andSequenceGroups_.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 < andConditionGroups_.size(); i++) { + output.writeMessage(1, andConditionGroups_.get(i)); + } + for (int i = 0; i < andSequenceGroups_.size(); i++) { + output.writeMessage(2, andSequenceGroups_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < andConditionGroups_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, andConditionGroups_.get(i)); + } + for (int i = 0; i < andSequenceGroups_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, andSequenceGroups_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.UserSegmentCriteria)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.UserSegmentCriteria other = + (com.google.analytics.data.v1alpha.UserSegmentCriteria) obj; + + if (!getAndConditionGroupsList().equals(other.getAndConditionGroupsList())) return false; + if (!getAndSequenceGroupsList().equals(other.getAndSequenceGroupsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAndConditionGroupsCount() > 0) { + hash = (37 * hash) + AND_CONDITION_GROUPS_FIELD_NUMBER; + hash = (53 * hash) + getAndConditionGroupsList().hashCode(); + } + if (getAndSequenceGroupsCount() > 0) { + hash = (37 * hash) + AND_SEQUENCE_GROUPS_FIELD_NUMBER; + hash = (53 * hash) + getAndSequenceGroupsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria 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.analytics.data.v1alpha.UserSegmentCriteria parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.UserSegmentCriteria 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A user matches a criteria if the user's events meet the conditions in the
+   * criteria.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentCriteria} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.UserSegmentCriteria) + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentCriteria.class, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.UserSegmentCriteria.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getAndConditionGroupsFieldBuilder(); + getAndSequenceGroupsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (andConditionGroupsBuilder_ == null) { + andConditionGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + andConditionGroupsBuilder_.clear(); + } + if (andSequenceGroupsBuilder_ == null) { + andSequenceGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + andSequenceGroupsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentCriteria_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteria getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteria build() { + com.google.analytics.data.v1alpha.UserSegmentCriteria result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteria buildPartial() { + com.google.analytics.data.v1alpha.UserSegmentCriteria result = + new com.google.analytics.data.v1alpha.UserSegmentCriteria(this); + int from_bitField0_ = bitField0_; + if (andConditionGroupsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = java.util.Collections.unmodifiableList(andConditionGroups_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.andConditionGroups_ = andConditionGroups_; + } else { + result.andConditionGroups_ = andConditionGroupsBuilder_.build(); + } + if (andSequenceGroupsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + andSequenceGroups_ = java.util.Collections.unmodifiableList(andSequenceGroups_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.andSequenceGroups_ = andSequenceGroups_; + } else { + result.andSequenceGroups_ = andSequenceGroupsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.UserSegmentCriteria) { + return mergeFrom((com.google.analytics.data.v1alpha.UserSegmentCriteria) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.UserSegmentCriteria other) { + if (other == com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance()) + return this; + if (andConditionGroupsBuilder_ == null) { + if (!other.andConditionGroups_.isEmpty()) { + if (andConditionGroups_.isEmpty()) { + andConditionGroups_ = other.andConditionGroups_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.addAll(other.andConditionGroups_); + } + onChanged(); + } + } else { + if (!other.andConditionGroups_.isEmpty()) { + if (andConditionGroupsBuilder_.isEmpty()) { + andConditionGroupsBuilder_.dispose(); + andConditionGroupsBuilder_ = null; + andConditionGroups_ = other.andConditionGroups_; + bitField0_ = (bitField0_ & ~0x00000001); + andConditionGroupsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getAndConditionGroupsFieldBuilder() + : null; + } else { + andConditionGroupsBuilder_.addAllMessages(other.andConditionGroups_); + } + } + } + if (andSequenceGroupsBuilder_ == null) { + if (!other.andSequenceGroups_.isEmpty()) { + if (andSequenceGroups_.isEmpty()) { + andSequenceGroups_ = other.andSequenceGroups_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.addAll(other.andSequenceGroups_); + } + onChanged(); + } + } else { + if (!other.andSequenceGroups_.isEmpty()) { + if (andSequenceGroupsBuilder_.isEmpty()) { + andSequenceGroupsBuilder_.dispose(); + andSequenceGroupsBuilder_ = null; + andSequenceGroups_ = other.andSequenceGroups_; + bitField0_ = (bitField0_ & ~0x00000002); + andSequenceGroupsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getAndSequenceGroupsFieldBuilder() + : null; + } else { + andSequenceGroupsBuilder_.addAllMessages(other.andSequenceGroups_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.UserSegmentCriteria parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.UserSegmentCriteria) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + andConditionGroups_ = java.util.Collections.emptyList(); + + private void ensureAndConditionGroupsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + andConditionGroups_ = + new java.util.ArrayList( + andConditionGroups_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentConditionGroup, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder> + andConditionGroupsBuilder_; + + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List + getAndConditionGroupsList() { + if (andConditionGroupsBuilder_ == null) { + return java.util.Collections.unmodifiableList(andConditionGroups_); + } else { + return andConditionGroupsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public int getAndConditionGroupsCount() { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.size(); + } else { + return andConditionGroupsBuilder_.getCount(); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup getAndConditionGroups( + int index) { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.get(index); + } else { + return andConditionGroupsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder setAndConditionGroups( + int index, com.google.analytics.data.v1alpha.UserSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.set(index, value); + onChanged(); + } else { + andConditionGroupsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder setAndConditionGroups( + int index, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.set(index, builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + com.google.analytics.data.v1alpha.UserSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(value); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + int index, com.google.analytics.data.v1alpha.UserSegmentConditionGroup value) { + if (andConditionGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(index, value); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAndConditionGroups( + int index, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder builderForValue) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.add(index, builderForValue.build()); + onChanged(); + } else { + andConditionGroupsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder addAllAndConditionGroups( + java.lang.Iterable + values) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, andConditionGroups_); + onChanged(); + } else { + andConditionGroupsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder clearAndConditionGroups() { + if (andConditionGroupsBuilder_ == null) { + andConditionGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + andConditionGroupsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public Builder removeAndConditionGroups(int index) { + if (andConditionGroupsBuilder_ == null) { + ensureAndConditionGroupsIsMutable(); + andConditionGroups_.remove(index); + onChanged(); + } else { + andConditionGroupsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder + getAndConditionGroupsBuilder(int index) { + return getAndConditionGroupsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index) { + if (andConditionGroupsBuilder_ == null) { + return andConditionGroups_.get(index); + } else { + return andConditionGroupsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder> + getAndConditionGroupsOrBuilderList() { + if (andConditionGroupsBuilder_ != null) { + return andConditionGroupsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(andConditionGroups_); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder + addAndConditionGroupsBuilder() { + return getAndConditionGroupsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.getDefaultInstance()); + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder + addAndConditionGroupsBuilder(int index) { + return getAndConditionGroupsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.getDefaultInstance()); + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andConditionGroups` and each of the `andSequenceGroups`.
+     * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + public java.util.List + getAndConditionGroupsBuilderList() { + return getAndConditionGroupsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentConditionGroup, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder> + getAndConditionGroupsFieldBuilder() { + if (andConditionGroupsBuilder_ == null) { + andConditionGroupsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentConditionGroup, + com.google.analytics.data.v1alpha.UserSegmentConditionGroup.Builder, + com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder>( + andConditionGroups_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + andConditionGroups_ = null; + } + return andConditionGroupsBuilder_; + } + + private java.util.List + andSequenceGroups_ = java.util.Collections.emptyList(); + + private void ensureAndSequenceGroupsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + andSequenceGroups_ = + new java.util.ArrayList( + andSequenceGroups_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder> + andSequenceGroupsBuilder_; + + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public java.util.List + getAndSequenceGroupsList() { + if (andSequenceGroupsBuilder_ == null) { + return java.util.Collections.unmodifiableList(andSequenceGroups_); + } else { + return andSequenceGroupsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public int getAndSequenceGroupsCount() { + if (andSequenceGroupsBuilder_ == null) { + return andSequenceGroups_.size(); + } else { + return andSequenceGroupsBuilder_.getCount(); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup getAndSequenceGroups( + int index) { + if (andSequenceGroupsBuilder_ == null) { + return andSequenceGroups_.get(index); + } else { + return andSequenceGroupsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder setAndSequenceGroups( + int index, com.google.analytics.data.v1alpha.UserSegmentSequenceGroup value) { + if (andSequenceGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.set(index, value); + onChanged(); + } else { + andSequenceGroupsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder setAndSequenceGroups( + int index, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder builderForValue) { + if (andSequenceGroupsBuilder_ == null) { + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.set(index, builderForValue.build()); + onChanged(); + } else { + andSequenceGroupsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder addAndSequenceGroups( + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup value) { + if (andSequenceGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.add(value); + onChanged(); + } else { + andSequenceGroupsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder addAndSequenceGroups( + int index, com.google.analytics.data.v1alpha.UserSegmentSequenceGroup value) { + if (andSequenceGroupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.add(index, value); + onChanged(); + } else { + andSequenceGroupsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder addAndSequenceGroups( + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder builderForValue) { + if (andSequenceGroupsBuilder_ == null) { + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.add(builderForValue.build()); + onChanged(); + } else { + andSequenceGroupsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder addAndSequenceGroups( + int index, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder builderForValue) { + if (andSequenceGroupsBuilder_ == null) { + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.add(index, builderForValue.build()); + onChanged(); + } else { + andSequenceGroupsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder addAllAndSequenceGroups( + java.lang.Iterable + values) { + if (andSequenceGroupsBuilder_ == null) { + ensureAndSequenceGroupsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, andSequenceGroups_); + onChanged(); + } else { + andSequenceGroupsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder clearAndSequenceGroups() { + if (andSequenceGroupsBuilder_ == null) { + andSequenceGroups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + andSequenceGroupsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public Builder removeAndSequenceGroups(int index) { + if (andSequenceGroupsBuilder_ == null) { + ensureAndSequenceGroupsIsMutable(); + andSequenceGroups_.remove(index); + onChanged(); + } else { + andSequenceGroupsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder + getAndSequenceGroupsBuilder(int index) { + return getAndSequenceGroupsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder + getAndSequenceGroupsOrBuilder(int index) { + if (andSequenceGroupsBuilder_ == null) { + return andSequenceGroups_.get(index); + } else { + return andSequenceGroupsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public java.util.List< + ? extends com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder> + getAndSequenceGroupsOrBuilderList() { + if (andSequenceGroupsBuilder_ != null) { + return andSequenceGroupsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(andSequenceGroups_); + } + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder + addAndSequenceGroupsBuilder() { + return getAndSequenceGroupsFieldBuilder() + .addBuilder( + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.getDefaultInstance()); + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder + addAndSequenceGroupsBuilder(int index) { + return getAndSequenceGroupsFieldBuilder() + .addBuilder( + index, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.getDefaultInstance()); + } + /** + * + * + *
+     * A user matches this criteria if the user matches each of these
+     * `andSequenceGroups` and each of the `andConditionGroups`.
+     * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+     * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + public java.util.List + getAndSequenceGroupsBuilderList() { + return getAndSequenceGroupsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder> + getAndSequenceGroupsFieldBuilder() { + if (andSequenceGroupsBuilder_ == null) { + andSequenceGroupsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder>( + andSequenceGroups_, + ((bitField0_ & 0x00000002) != 0), + getParentForChildren(), + isClean()); + andSequenceGroups_ = null; + } + return andSequenceGroupsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.UserSegmentCriteria) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.UserSegmentCriteria) + private static final com.google.analytics.data.v1alpha.UserSegmentCriteria DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.UserSegmentCriteria(); + } + + public static com.google.analytics.data.v1alpha.UserSegmentCriteria getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UserSegmentCriteria parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UserSegmentCriteria(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.UserSegmentCriteria getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteriaOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteriaOrBuilder.java new file mode 100644 index 00000000..607a98ec --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentCriteriaOrBuilder.java @@ -0,0 +1,168 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface UserSegmentCriteriaOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.UserSegmentCriteria) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + java.util.List + getAndConditionGroupsList(); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + com.google.analytics.data.v1alpha.UserSegmentConditionGroup getAndConditionGroups(int index); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + int getAndConditionGroupsCount(); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + java.util.List + getAndConditionGroupsOrBuilderList(); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andConditionGroups` and each of the `andSequenceGroups`.
+   * `andConditionGroups` may be empty if `andSequenceGroups` are specified.
+   * 
+ * + * + * repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * + */ + com.google.analytics.data.v1alpha.UserSegmentConditionGroupOrBuilder + getAndConditionGroupsOrBuilder(int index); + + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + java.util.List + getAndSequenceGroupsList(); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup getAndSequenceGroups(int index); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + int getAndSequenceGroupsCount(); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + java.util.List + getAndSequenceGroupsOrBuilderList(); + /** + * + * + *
+   * A user matches this criteria if the user matches each of these
+   * `andSequenceGroups` and each of the `andConditionGroups`.
+   * `andSequenceGroups` may be empty if `andConditionGroups` are specified.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * + */ + com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder getAndSequenceGroupsOrBuilder( + int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusion.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusion.java new file mode 100644 index 00000000..51f70dcb --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusion.java @@ -0,0 +1,945 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Specifies which users are excluded in this segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentExclusion} + */ +public final class UserSegmentExclusion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.UserSegmentExclusion) + UserSegmentExclusionOrBuilder { + private static final long serialVersionUID = 0L; + // Use UserSegmentExclusion.newBuilder() to construct. + private UserSegmentExclusion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UserSegmentExclusion() { + userExclusionDuration_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UserSegmentExclusion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UserSegmentExclusion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + userExclusionDuration_ = rawValue; + break; + } + case 18: + { + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder subBuilder = null; + if (userExclusionCriteria_ != null) { + subBuilder = userExclusionCriteria_.toBuilder(); + } + userExclusionCriteria_ = + input.readMessage( + com.google.analytics.data.v1alpha.UserSegmentCriteria.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(userExclusionCriteria_); + userExclusionCriteria_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentExclusion.class, + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder.class); + } + + public static final int USER_EXCLUSION_DURATION_FIELD_NUMBER = 1; + private int userExclusionDuration_; + /** + * + * + *
+   * Specifies how long an exclusion will last if a user matches the
+   * `userExclusionCriteria`.
+   * Optional. If unspecified, `userExclusionDuration` of
+   * `USER_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * @return The enum numeric value on the wire for userExclusionDuration. + */ + @java.lang.Override + public int getUserExclusionDurationValue() { + return userExclusionDuration_; + } + /** + * + * + *
+   * Specifies how long an exclusion will last if a user matches the
+   * `userExclusionCriteria`.
+   * Optional. If unspecified, `userExclusionDuration` of
+   * `USER_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * @return The userExclusionDuration. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserExclusionDuration getUserExclusionDuration() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserExclusionDuration result = + com.google.analytics.data.v1alpha.UserExclusionDuration.valueOf(userExclusionDuration_); + return result == null + ? com.google.analytics.data.v1alpha.UserExclusionDuration.UNRECOGNIZED + : result; + } + + public static final int USER_EXCLUSION_CRITERIA_FIELD_NUMBER = 2; + private com.google.analytics.data.v1alpha.UserSegmentCriteria userExclusionCriteria_; + /** + * + * + *
+   * If a user meets this condition, the user is excluded from membership in
+   * the segment for the `userExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * + * @return Whether the userExclusionCriteria field is set. + */ + @java.lang.Override + public boolean hasUserExclusionCriteria() { + return userExclusionCriteria_ != null; + } + /** + * + * + *
+   * If a user meets this condition, the user is excluded from membership in
+   * the segment for the `userExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * + * @return The userExclusionCriteria. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteria getUserExclusionCriteria() { + return userExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance() + : userExclusionCriteria_; + } + /** + * + * + *
+   * If a user meets this condition, the user is excluded from membership in
+   * the segment for the `userExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder + getUserExclusionCriteriaOrBuilder() { + return getUserExclusionCriteria(); + } + + 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 (userExclusionDuration_ + != com.google.analytics.data.v1alpha.UserExclusionDuration + .USER_EXCLUSION_DURATION_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, userExclusionDuration_); + } + if (userExclusionCriteria_ != null) { + output.writeMessage(2, getUserExclusionCriteria()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (userExclusionDuration_ + != com.google.analytics.data.v1alpha.UserExclusionDuration + .USER_EXCLUSION_DURATION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, userExclusionDuration_); + } + if (userExclusionCriteria_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUserExclusionCriteria()); + } + size += unknownFields.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.analytics.data.v1alpha.UserSegmentExclusion)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.UserSegmentExclusion other = + (com.google.analytics.data.v1alpha.UserSegmentExclusion) obj; + + if (userExclusionDuration_ != other.userExclusionDuration_) return false; + if (hasUserExclusionCriteria() != other.hasUserExclusionCriteria()) return false; + if (hasUserExclusionCriteria()) { + if (!getUserExclusionCriteria().equals(other.getUserExclusionCriteria())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + USER_EXCLUSION_DURATION_FIELD_NUMBER; + hash = (53 * hash) + userExclusionDuration_; + if (hasUserExclusionCriteria()) { + hash = (37 * hash) + USER_EXCLUSION_CRITERIA_FIELD_NUMBER; + hash = (53 * hash) + getUserExclusionCriteria().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion 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.analytics.data.v1alpha.UserSegmentExclusion parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.UserSegmentExclusion 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Specifies which users are excluded in this segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentExclusion} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.UserSegmentExclusion) + com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentExclusion.class, + com.google.analytics.data.v1alpha.UserSegmentExclusion.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.UserSegmentExclusion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + userExclusionDuration_ = 0; + + if (userExclusionCriteriaBuilder_ == null) { + userExclusionCriteria_ = null; + } else { + userExclusionCriteria_ = null; + userExclusionCriteriaBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentExclusion_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentExclusion getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.UserSegmentExclusion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentExclusion build() { + com.google.analytics.data.v1alpha.UserSegmentExclusion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentExclusion buildPartial() { + com.google.analytics.data.v1alpha.UserSegmentExclusion result = + new com.google.analytics.data.v1alpha.UserSegmentExclusion(this); + result.userExclusionDuration_ = userExclusionDuration_; + if (userExclusionCriteriaBuilder_ == null) { + result.userExclusionCriteria_ = userExclusionCriteria_; + } else { + result.userExclusionCriteria_ = userExclusionCriteriaBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.UserSegmentExclusion) { + return mergeFrom((com.google.analytics.data.v1alpha.UserSegmentExclusion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.UserSegmentExclusion other) { + if (other == com.google.analytics.data.v1alpha.UserSegmentExclusion.getDefaultInstance()) + return this; + if (other.userExclusionDuration_ != 0) { + setUserExclusionDurationValue(other.getUserExclusionDurationValue()); + } + if (other.hasUserExclusionCriteria()) { + mergeUserExclusionCriteria(other.getUserExclusionCriteria()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.UserSegmentExclusion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.UserSegmentExclusion) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int userExclusionDuration_ = 0; + /** + * + * + *
+     * Specifies how long an exclusion will last if a user matches the
+     * `userExclusionCriteria`.
+     * Optional. If unspecified, `userExclusionDuration` of
+     * `USER_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * + * @return The enum numeric value on the wire for userExclusionDuration. + */ + @java.lang.Override + public int getUserExclusionDurationValue() { + return userExclusionDuration_; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a user matches the
+     * `userExclusionCriteria`.
+     * Optional. If unspecified, `userExclusionDuration` of
+     * `USER_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * + * @param value The enum numeric value on the wire for userExclusionDuration to set. + * @return This builder for chaining. + */ + public Builder setUserExclusionDurationValue(int value) { + + userExclusionDuration_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a user matches the
+     * `userExclusionCriteria`.
+     * Optional. If unspecified, `userExclusionDuration` of
+     * `USER_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * + * @return The userExclusionDuration. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserExclusionDuration getUserExclusionDuration() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserExclusionDuration result = + com.google.analytics.data.v1alpha.UserExclusionDuration.valueOf(userExclusionDuration_); + return result == null + ? com.google.analytics.data.v1alpha.UserExclusionDuration.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a user matches the
+     * `userExclusionCriteria`.
+     * Optional. If unspecified, `userExclusionDuration` of
+     * `USER_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * + * @param value The userExclusionDuration to set. + * @return This builder for chaining. + */ + public Builder setUserExclusionDuration( + com.google.analytics.data.v1alpha.UserExclusionDuration value) { + if (value == null) { + throw new NullPointerException(); + } + + userExclusionDuration_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Specifies how long an exclusion will last if a user matches the
+     * `userExclusionCriteria`.
+     * Optional. If unspecified, `userExclusionDuration` of
+     * `USER_EXCLUSION_TEMPORARY` is used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * + * @return This builder for chaining. + */ + public Builder clearUserExclusionDuration() { + + userExclusionDuration_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.UserSegmentCriteria userExclusionCriteria_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentCriteria, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder> + userExclusionCriteriaBuilder_; + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * + * @return Whether the userExclusionCriteria field is set. + */ + public boolean hasUserExclusionCriteria() { + return userExclusionCriteriaBuilder_ != null || userExclusionCriteria_ != null; + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * + * @return The userExclusionCriteria. + */ + public com.google.analytics.data.v1alpha.UserSegmentCriteria getUserExclusionCriteria() { + if (userExclusionCriteriaBuilder_ == null) { + return userExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance() + : userExclusionCriteria_; + } else { + return userExclusionCriteriaBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + public Builder setUserExclusionCriteria( + com.google.analytics.data.v1alpha.UserSegmentCriteria value) { + if (userExclusionCriteriaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + userExclusionCriteria_ = value; + onChanged(); + } else { + userExclusionCriteriaBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + public Builder setUserExclusionCriteria( + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder builderForValue) { + if (userExclusionCriteriaBuilder_ == null) { + userExclusionCriteria_ = builderForValue.build(); + onChanged(); + } else { + userExclusionCriteriaBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + public Builder mergeUserExclusionCriteria( + com.google.analytics.data.v1alpha.UserSegmentCriteria value) { + if (userExclusionCriteriaBuilder_ == null) { + if (userExclusionCriteria_ != null) { + userExclusionCriteria_ = + com.google.analytics.data.v1alpha.UserSegmentCriteria.newBuilder( + userExclusionCriteria_) + .mergeFrom(value) + .buildPartial(); + } else { + userExclusionCriteria_ = value; + } + onChanged(); + } else { + userExclusionCriteriaBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + public Builder clearUserExclusionCriteria() { + if (userExclusionCriteriaBuilder_ == null) { + userExclusionCriteria_ = null; + onChanged(); + } else { + userExclusionCriteria_ = null; + userExclusionCriteriaBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + public com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder + getUserExclusionCriteriaBuilder() { + + onChanged(); + return getUserExclusionCriteriaFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + public com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder + getUserExclusionCriteriaOrBuilder() { + if (userExclusionCriteriaBuilder_ != null) { + return userExclusionCriteriaBuilder_.getMessageOrBuilder(); + } else { + return userExclusionCriteria_ == null + ? com.google.analytics.data.v1alpha.UserSegmentCriteria.getDefaultInstance() + : userExclusionCriteria_; + } + } + /** + * + * + *
+     * If a user meets this condition, the user is excluded from membership in
+     * the segment for the `userExclusionDuration`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentCriteria, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder> + getUserExclusionCriteriaFieldBuilder() { + if (userExclusionCriteriaBuilder_ == null) { + userExclusionCriteriaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSegmentCriteria, + com.google.analytics.data.v1alpha.UserSegmentCriteria.Builder, + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder>( + getUserExclusionCriteria(), getParentForChildren(), isClean()); + userExclusionCriteria_ = null; + } + return userExclusionCriteriaBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.UserSegmentExclusion) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.UserSegmentExclusion) + private static final com.google.analytics.data.v1alpha.UserSegmentExclusion DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.UserSegmentExclusion(); + } + + public static com.google.analytics.data.v1alpha.UserSegmentExclusion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UserSegmentExclusion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UserSegmentExclusion(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.UserSegmentExclusion getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusionOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusionOrBuilder.java new file mode 100644 index 00000000..03637976 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentExclusionOrBuilder.java @@ -0,0 +1,95 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface UserSegmentExclusionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.UserSegmentExclusion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Specifies how long an exclusion will last if a user matches the
+   * `userExclusionCriteria`.
+   * Optional. If unspecified, `userExclusionDuration` of
+   * `USER_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * @return The enum numeric value on the wire for userExclusionDuration. + */ + int getUserExclusionDurationValue(); + /** + * + * + *
+   * Specifies how long an exclusion will last if a user matches the
+   * `userExclusionCriteria`.
+   * Optional. If unspecified, `userExclusionDuration` of
+   * `USER_EXCLUSION_TEMPORARY` is used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * + * @return The userExclusionDuration. + */ + com.google.analytics.data.v1alpha.UserExclusionDuration getUserExclusionDuration(); + + /** + * + * + *
+   * If a user meets this condition, the user is excluded from membership in
+   * the segment for the `userExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * + * @return Whether the userExclusionCriteria field is set. + */ + boolean hasUserExclusionCriteria(); + /** + * + * + *
+   * If a user meets this condition, the user is excluded from membership in
+   * the segment for the `userExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * + * @return The userExclusionCriteria. + */ + com.google.analytics.data.v1alpha.UserSegmentCriteria getUserExclusionCriteria(); + /** + * + * + *
+   * If a user meets this condition, the user is excluded from membership in
+   * the segment for the `userExclusionDuration`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder + getUserExclusionCriteriaOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentOrBuilder.java new file mode 100644 index 00000000..fe91559e --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentOrBuilder.java @@ -0,0 +1,96 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface UserSegmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.UserSegment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Defines which users are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * + * @return Whether the userInclusionCriteria field is set. + */ + boolean hasUserInclusionCriteria(); + /** + * + * + *
+   * Defines which users are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * + * @return The userInclusionCriteria. + */ + com.google.analytics.data.v1alpha.UserSegmentCriteria getUserInclusionCriteria(); + /** + * + * + *
+   * Defines which users are included in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + com.google.analytics.data.v1alpha.UserSegmentCriteriaOrBuilder + getUserInclusionCriteriaOrBuilder(); + + /** + * + * + *
+   * Defines which users are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * + * @return Whether the exclusion field is set. + */ + boolean hasExclusion(); + /** + * + * + *
+   * Defines which users are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * + * @return The exclusion. + */ + com.google.analytics.data.v1alpha.UserSegmentExclusion getExclusion(); + /** + * + * + *
+   * Defines which users are excluded in this segment. Optional.
+   * 
+ * + * .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + com.google.analytics.data.v1alpha.UserSegmentExclusionOrBuilder getExclusionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroup.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroup.java new file mode 100644 index 00000000..08fb0db0 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroup.java @@ -0,0 +1,1587 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * Define conditions that must occur in a specific order for the user to be
+ * a member of the segment.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentSequenceGroup} + */ +public final class UserSegmentSequenceGroup extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.UserSegmentSequenceGroup) + UserSegmentSequenceGroupOrBuilder { + private static final long serialVersionUID = 0L; + // Use UserSegmentSequenceGroup.newBuilder() to construct. + private UserSegmentSequenceGroup(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UserSegmentSequenceGroup() { + sequenceScoping_ = 0; + userSequenceSteps_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UserSegmentSequenceGroup(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UserSegmentSequenceGroup( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + sequenceScoping_ = rawValue; + break; + } + case 18: + { + com.google.protobuf.Duration.Builder subBuilder = null; + if (sequenceMaximumDuration_ != null) { + subBuilder = sequenceMaximumDuration_.toBuilder(); + } + sequenceMaximumDuration_ = + input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(sequenceMaximumDuration_); + sequenceMaximumDuration_ = subBuilder.buildPartial(); + } + + break; + } + case 26: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + userSequenceSteps_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + userSequenceSteps_.add( + input.readMessage( + com.google.analytics.data.v1alpha.UserSequenceStep.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + userSequenceSteps_ = java.util.Collections.unmodifiableList(userSequenceSteps_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.class, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder.class); + } + + public static final int SEQUENCE_SCOPING_FIELD_NUMBER = 1; + private int sequenceScoping_; + /** + * + * + *
+   * All sequence steps must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+   * one session for the user to match the sequence. `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return The enum numeric value on the wire for sequenceScoping. + */ + @java.lang.Override + public int getSequenceScopingValue() { + return sequenceScoping_; + } + /** + * + * + *
+   * All sequence steps must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+   * one session for the user to match the sequence. `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return The sequenceScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserCriteriaScoping getSequenceScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserCriteriaScoping result = + com.google.analytics.data.v1alpha.UserCriteriaScoping.valueOf(sequenceScoping_); + return result == null + ? com.google.analytics.data.v1alpha.UserCriteriaScoping.UNRECOGNIZED + : result; + } + + public static final int SEQUENCE_MAXIMUM_DURATION_FIELD_NUMBER = 2; + private com.google.protobuf.Duration sequenceMaximumDuration_; + /** + * + * + *
+   * Defines the time period in which the whole sequence must occur; for
+   * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+   * of the endpoint at the microsecond granularity. For example a sequence
+   * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+   * seconds, but not 5 seconds and 1 microsecond.
+   * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+   * be completed in any time duration.
+   * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + * + * @return Whether the sequenceMaximumDuration field is set. + */ + @java.lang.Override + public boolean hasSequenceMaximumDuration() { + return sequenceMaximumDuration_ != null; + } + /** + * + * + *
+   * Defines the time period in which the whole sequence must occur; for
+   * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+   * of the endpoint at the microsecond granularity. For example a sequence
+   * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+   * seconds, but not 5 seconds and 1 microsecond.
+   * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+   * be completed in any time duration.
+   * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + * + * @return The sequenceMaximumDuration. + */ + @java.lang.Override + public com.google.protobuf.Duration getSequenceMaximumDuration() { + return sequenceMaximumDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : sequenceMaximumDuration_; + } + /** + * + * + *
+   * Defines the time period in which the whole sequence must occur; for
+   * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+   * of the endpoint at the microsecond granularity. For example a sequence
+   * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+   * seconds, but not 5 seconds and 1 microsecond.
+   * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+   * be completed in any time duration.
+   * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getSequenceMaximumDurationOrBuilder() { + return getSequenceMaximumDuration(); + } + + public static final int USER_SEQUENCE_STEPS_FIELD_NUMBER = 3; + private java.util.List userSequenceSteps_; + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + @java.lang.Override + public java.util.List + getUserSequenceStepsList() { + return userSequenceSteps_; + } + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + @java.lang.Override + public java.util.List + getUserSequenceStepsOrBuilderList() { + return userSequenceSteps_; + } + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + @java.lang.Override + public int getUserSequenceStepsCount() { + return userSequenceSteps_.size(); + } + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSequenceStep getUserSequenceSteps(int index) { + return userSequenceSteps_.get(index); + } + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder getUserSequenceStepsOrBuilder( + int index) { + return userSequenceSteps_.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 (sequenceScoping_ + != com.google.analytics.data.v1alpha.UserCriteriaScoping.USER_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, sequenceScoping_); + } + if (sequenceMaximumDuration_ != null) { + output.writeMessage(2, getSequenceMaximumDuration()); + } + for (int i = 0; i < userSequenceSteps_.size(); i++) { + output.writeMessage(3, userSequenceSteps_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (sequenceScoping_ + != com.google.analytics.data.v1alpha.UserCriteriaScoping.USER_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, sequenceScoping_); + } + if (sequenceMaximumDuration_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSequenceMaximumDuration()); + } + for (int i = 0; i < userSequenceSteps_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, userSequenceSteps_.get(i)); + } + size += unknownFields.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.analytics.data.v1alpha.UserSegmentSequenceGroup)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup other = + (com.google.analytics.data.v1alpha.UserSegmentSequenceGroup) obj; + + if (sequenceScoping_ != other.sequenceScoping_) return false; + if (hasSequenceMaximumDuration() != other.hasSequenceMaximumDuration()) return false; + if (hasSequenceMaximumDuration()) { + if (!getSequenceMaximumDuration().equals(other.getSequenceMaximumDuration())) return false; + } + if (!getUserSequenceStepsList().equals(other.getUserSequenceStepsList())) return false; + if (!unknownFields.equals(other.unknownFields)) 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_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + sequenceScoping_; + if (hasSequenceMaximumDuration()) { + hash = (37 * hash) + SEQUENCE_MAXIMUM_DURATION_FIELD_NUMBER; + hash = (53 * hash) + getSequenceMaximumDuration().hashCode(); + } + if (getUserSequenceStepsCount() > 0) { + hash = (37 * hash) + USER_SEQUENCE_STEPS_FIELD_NUMBER; + hash = (53 * hash) + getUserSequenceStepsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup 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.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.UserSegmentSequenceGroup 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Define conditions that must occur in a specific order for the user to be
+   * a member of the segment.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSegmentSequenceGroup} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.UserSegmentSequenceGroup) + com.google.analytics.data.v1alpha.UserSegmentSequenceGroupOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.class, + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getUserSequenceStepsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + sequenceScoping_ = 0; + + if (sequenceMaximumDurationBuilder_ == null) { + sequenceMaximumDuration_ = null; + } else { + sequenceMaximumDuration_ = null; + sequenceMaximumDurationBuilder_ = null; + } + if (userSequenceStepsBuilder_ == null) { + userSequenceSteps_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + userSequenceStepsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSegmentSequenceGroup_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup build() { + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSegmentSequenceGroup buildPartial() { + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup result = + new com.google.analytics.data.v1alpha.UserSegmentSequenceGroup(this); + int from_bitField0_ = bitField0_; + result.sequenceScoping_ = sequenceScoping_; + if (sequenceMaximumDurationBuilder_ == null) { + result.sequenceMaximumDuration_ = sequenceMaximumDuration_; + } else { + result.sequenceMaximumDuration_ = sequenceMaximumDurationBuilder_.build(); + } + if (userSequenceStepsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + userSequenceSteps_ = java.util.Collections.unmodifiableList(userSequenceSteps_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.userSequenceSteps_ = userSequenceSteps_; + } else { + result.userSequenceSteps_ = userSequenceStepsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.UserSegmentSequenceGroup) { + return mergeFrom((com.google.analytics.data.v1alpha.UserSegmentSequenceGroup) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.UserSegmentSequenceGroup other) { + if (other == com.google.analytics.data.v1alpha.UserSegmentSequenceGroup.getDefaultInstance()) + return this; + if (other.sequenceScoping_ != 0) { + setSequenceScopingValue(other.getSequenceScopingValue()); + } + if (other.hasSequenceMaximumDuration()) { + mergeSequenceMaximumDuration(other.getSequenceMaximumDuration()); + } + if (userSequenceStepsBuilder_ == null) { + if (!other.userSequenceSteps_.isEmpty()) { + if (userSequenceSteps_.isEmpty()) { + userSequenceSteps_ = other.userSequenceSteps_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.addAll(other.userSequenceSteps_); + } + onChanged(); + } + } else { + if (!other.userSequenceSteps_.isEmpty()) { + if (userSequenceStepsBuilder_.isEmpty()) { + userSequenceStepsBuilder_.dispose(); + userSequenceStepsBuilder_ = null; + userSequenceSteps_ = other.userSequenceSteps_; + bitField0_ = (bitField0_ & ~0x00000001); + userSequenceStepsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getUserSequenceStepsFieldBuilder() + : null; + } else { + userSequenceStepsBuilder_.addAllMessages(other.userSequenceSteps_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.UserSegmentSequenceGroup parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.UserSegmentSequenceGroup) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private int sequenceScoping_ = 0; + /** + * + * + *
+     * All sequence steps must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+     * one session for the user to match the sequence. `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return The enum numeric value on the wire for sequenceScoping. + */ + @java.lang.Override + public int getSequenceScopingValue() { + return sequenceScoping_; + } + /** + * + * + *
+     * All sequence steps must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+     * one session for the user to match the sequence. `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @param value The enum numeric value on the wire for sequenceScoping to set. + * @return This builder for chaining. + */ + public Builder setSequenceScopingValue(int value) { + + sequenceScoping_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * All sequence steps must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+     * one session for the user to match the sequence. `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return The sequenceScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserCriteriaScoping getSequenceScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserCriteriaScoping result = + com.google.analytics.data.v1alpha.UserCriteriaScoping.valueOf(sequenceScoping_); + return result == null + ? com.google.analytics.data.v1alpha.UserCriteriaScoping.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * All sequence steps must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+     * one session for the user to match the sequence. `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @param value The sequenceScoping to set. + * @return This builder for chaining. + */ + public Builder setSequenceScoping(com.google.analytics.data.v1alpha.UserCriteriaScoping value) { + if (value == null) { + throw new NullPointerException(); + } + + sequenceScoping_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * All sequence steps must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+     * one session for the user to match the sequence. `sequenceScoping =
+     * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+     * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+     * used.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return This builder for chaining. + */ + public Builder clearSequenceScoping() { + + sequenceScoping_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Duration sequenceMaximumDuration_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + sequenceMaximumDurationBuilder_; + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + * + * @return Whether the sequenceMaximumDuration field is set. + */ + public boolean hasSequenceMaximumDuration() { + return sequenceMaximumDurationBuilder_ != null || sequenceMaximumDuration_ != null; + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + * + * @return The sequenceMaximumDuration. + */ + public com.google.protobuf.Duration getSequenceMaximumDuration() { + if (sequenceMaximumDurationBuilder_ == null) { + return sequenceMaximumDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : sequenceMaximumDuration_; + } else { + return sequenceMaximumDurationBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + public Builder setSequenceMaximumDuration(com.google.protobuf.Duration value) { + if (sequenceMaximumDurationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + sequenceMaximumDuration_ = value; + onChanged(); + } else { + sequenceMaximumDurationBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + public Builder setSequenceMaximumDuration( + com.google.protobuf.Duration.Builder builderForValue) { + if (sequenceMaximumDurationBuilder_ == null) { + sequenceMaximumDuration_ = builderForValue.build(); + onChanged(); + } else { + sequenceMaximumDurationBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + public Builder mergeSequenceMaximumDuration(com.google.protobuf.Duration value) { + if (sequenceMaximumDurationBuilder_ == null) { + if (sequenceMaximumDuration_ != null) { + sequenceMaximumDuration_ = + com.google.protobuf.Duration.newBuilder(sequenceMaximumDuration_) + .mergeFrom(value) + .buildPartial(); + } else { + sequenceMaximumDuration_ = value; + } + onChanged(); + } else { + sequenceMaximumDurationBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + public Builder clearSequenceMaximumDuration() { + if (sequenceMaximumDurationBuilder_ == null) { + sequenceMaximumDuration_ = null; + onChanged(); + } else { + sequenceMaximumDuration_ = null; + sequenceMaximumDurationBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + public com.google.protobuf.Duration.Builder getSequenceMaximumDurationBuilder() { + + onChanged(); + return getSequenceMaximumDurationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + public com.google.protobuf.DurationOrBuilder getSequenceMaximumDurationOrBuilder() { + if (sequenceMaximumDurationBuilder_ != null) { + return sequenceMaximumDurationBuilder_.getMessageOrBuilder(); + } else { + return sequenceMaximumDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : sequenceMaximumDuration_; + } + } + /** + * + * + *
+     * Defines the time period in which the whole sequence must occur; for
+     * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+     * of the endpoint at the microsecond granularity. For example a sequence
+     * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+     * seconds, but not 5 seconds and 1 microsecond.
+     * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+     * be completed in any time duration.
+     * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + getSequenceMaximumDurationFieldBuilder() { + if (sequenceMaximumDurationBuilder_ == null) { + sequenceMaximumDurationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getSequenceMaximumDuration(), getParentForChildren(), isClean()); + sequenceMaximumDuration_ = null; + } + return sequenceMaximumDurationBuilder_; + } + + private java.util.List userSequenceSteps_ = + java.util.Collections.emptyList(); + + private void ensureUserSequenceStepsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + userSequenceSteps_ = + new java.util.ArrayList( + userSequenceSteps_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSequenceStep, + com.google.analytics.data.v1alpha.UserSequenceStep.Builder, + com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder> + userSequenceStepsBuilder_; + + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public java.util.List + getUserSequenceStepsList() { + if (userSequenceStepsBuilder_ == null) { + return java.util.Collections.unmodifiableList(userSequenceSteps_); + } else { + return userSequenceStepsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public int getUserSequenceStepsCount() { + if (userSequenceStepsBuilder_ == null) { + return userSequenceSteps_.size(); + } else { + return userSequenceStepsBuilder_.getCount(); + } + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public com.google.analytics.data.v1alpha.UserSequenceStep getUserSequenceSteps(int index) { + if (userSequenceStepsBuilder_ == null) { + return userSequenceSteps_.get(index); + } else { + return userSequenceStepsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder setUserSequenceSteps( + int index, com.google.analytics.data.v1alpha.UserSequenceStep value) { + if (userSequenceStepsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.set(index, value); + onChanged(); + } else { + userSequenceStepsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder setUserSequenceSteps( + int index, com.google.analytics.data.v1alpha.UserSequenceStep.Builder builderForValue) { + if (userSequenceStepsBuilder_ == null) { + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.set(index, builderForValue.build()); + onChanged(); + } else { + userSequenceStepsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder addUserSequenceSteps(com.google.analytics.data.v1alpha.UserSequenceStep value) { + if (userSequenceStepsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.add(value); + onChanged(); + } else { + userSequenceStepsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder addUserSequenceSteps( + int index, com.google.analytics.data.v1alpha.UserSequenceStep value) { + if (userSequenceStepsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.add(index, value); + onChanged(); + } else { + userSequenceStepsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder addUserSequenceSteps( + com.google.analytics.data.v1alpha.UserSequenceStep.Builder builderForValue) { + if (userSequenceStepsBuilder_ == null) { + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.add(builderForValue.build()); + onChanged(); + } else { + userSequenceStepsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder addUserSequenceSteps( + int index, com.google.analytics.data.v1alpha.UserSequenceStep.Builder builderForValue) { + if (userSequenceStepsBuilder_ == null) { + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.add(index, builderForValue.build()); + onChanged(); + } else { + userSequenceStepsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder addAllUserSequenceSteps( + java.lang.Iterable values) { + if (userSequenceStepsBuilder_ == null) { + ensureUserSequenceStepsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, userSequenceSteps_); + onChanged(); + } else { + userSequenceStepsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder clearUserSequenceSteps() { + if (userSequenceStepsBuilder_ == null) { + userSequenceSteps_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + userSequenceStepsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public Builder removeUserSequenceSteps(int index) { + if (userSequenceStepsBuilder_ == null) { + ensureUserSequenceStepsIsMutable(); + userSequenceSteps_.remove(index); + onChanged(); + } else { + userSequenceStepsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public com.google.analytics.data.v1alpha.UserSequenceStep.Builder getUserSequenceStepsBuilder( + int index) { + return getUserSequenceStepsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder + getUserSequenceStepsOrBuilder(int index) { + if (userSequenceStepsBuilder_ == null) { + return userSequenceSteps_.get(index); + } else { + return userSequenceStepsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public java.util.List + getUserSequenceStepsOrBuilderList() { + if (userSequenceStepsBuilder_ != null) { + return userSequenceStepsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(userSequenceSteps_); + } + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public com.google.analytics.data.v1alpha.UserSequenceStep.Builder + addUserSequenceStepsBuilder() { + return getUserSequenceStepsFieldBuilder() + .addBuilder(com.google.analytics.data.v1alpha.UserSequenceStep.getDefaultInstance()); + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public com.google.analytics.data.v1alpha.UserSequenceStep.Builder addUserSequenceStepsBuilder( + int index) { + return getUserSequenceStepsFieldBuilder() + .addBuilder( + index, com.google.analytics.data.v1alpha.UserSequenceStep.getDefaultInstance()); + } + /** + * + * + *
+     * An ordered sequence of condition steps. A user's events must complete
+     * each step in order for the user to match the
+     * `UserSegmentSequenceGroup`.
+     * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * + */ + public java.util.List + getUserSequenceStepsBuilderList() { + return getUserSequenceStepsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSequenceStep, + com.google.analytics.data.v1alpha.UserSequenceStep.Builder, + com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder> + getUserSequenceStepsFieldBuilder() { + if (userSequenceStepsBuilder_ == null) { + userSequenceStepsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.analytics.data.v1alpha.UserSequenceStep, + com.google.analytics.data.v1alpha.UserSequenceStep.Builder, + com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder>( + userSequenceSteps_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + userSequenceSteps_ = null; + } + return userSequenceStepsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.UserSegmentSequenceGroup) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.UserSegmentSequenceGroup) + private static final com.google.analytics.data.v1alpha.UserSegmentSequenceGroup DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.UserSegmentSequenceGroup(); + } + + public static com.google.analytics.data.v1alpha.UserSegmentSequenceGroup getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UserSegmentSequenceGroup parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UserSegmentSequenceGroup(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.UserSegmentSequenceGroup getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroupOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroupOrBuilder.java new file mode 100644 index 00000000..b64578b4 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSegmentSequenceGroupOrBuilder.java @@ -0,0 +1,178 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface UserSegmentSequenceGroupOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.UserSegmentSequenceGroup) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * All sequence steps must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+   * one session for the user to match the sequence. `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return The enum numeric value on the wire for sequenceScoping. + */ + int getSequenceScopingValue(); + /** + * + * + *
+   * All sequence steps must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within
+   * one session for the user to match the sequence. `sequenceScoping =
+   * USER_CRITERIA_WITHIN_SAME_EVENT` is not supported.
+   * Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is
+   * used.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * + * @return The sequenceScoping. + */ + com.google.analytics.data.v1alpha.UserCriteriaScoping getSequenceScoping(); + + /** + * + * + *
+   * Defines the time period in which the whole sequence must occur; for
+   * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+   * of the endpoint at the microsecond granularity. For example a sequence
+   * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+   * seconds, but not 5 seconds and 1 microsecond.
+   * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+   * be completed in any time duration.
+   * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + * + * @return Whether the sequenceMaximumDuration field is set. + */ + boolean hasSequenceMaximumDuration(); + /** + * + * + *
+   * Defines the time period in which the whole sequence must occur; for
+   * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+   * of the endpoint at the microsecond granularity. For example a sequence
+   * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+   * seconds, but not 5 seconds and 1 microsecond.
+   * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+   * be completed in any time duration.
+   * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + * + * @return The sequenceMaximumDuration. + */ + com.google.protobuf.Duration getSequenceMaximumDuration(); + /** + * + * + *
+   * Defines the time period in which the whole sequence must occur; for
+   * example, 30 Minutes. `sequenceMaximumDuration` is inclusive
+   * of the endpoint at the microsecond granularity. For example a sequence
+   * with a maximum duration of 5 seconds can be completed at 4.9 or 5.0
+   * seconds, but not 5 seconds and 1 microsecond.
+   * `sequenceMaximumDuration` is optional, and if unspecified, sequences can
+   * be completed in any time duration.
+   * 
+ * + * .google.protobuf.Duration sequence_maximum_duration = 2; + */ + com.google.protobuf.DurationOrBuilder getSequenceMaximumDurationOrBuilder(); + + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + java.util.List getUserSequenceStepsList(); + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + com.google.analytics.data.v1alpha.UserSequenceStep getUserSequenceSteps(int index); + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + int getUserSequenceStepsCount(); + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + java.util.List + getUserSequenceStepsOrBuilderList(); + /** + * + * + *
+   * An ordered sequence of condition steps. A user's events must complete
+   * each step in order for the user to match the
+   * `UserSegmentSequenceGroup`.
+   * 
+ * + * repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder getUserSequenceStepsOrBuilder( + int index); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStep.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStep.java new file mode 100644 index 00000000..ce982040 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStep.java @@ -0,0 +1,1096 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +/** + * + * + *
+ * A condition that must occur in the specified step order for this user
+ * to match the sequence.
+ * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSequenceStep} + */ +public final class UserSequenceStep extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.analytics.data.v1alpha.UserSequenceStep) + UserSequenceStepOrBuilder { + private static final long serialVersionUID = 0L; + // Use UserSequenceStep.newBuilder() to construct. + private UserSequenceStep(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UserSequenceStep() { + stepScoping_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UserSequenceStep(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UserSequenceStep( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + isDirectlyFollowedBy_ = input.readBool(); + break; + } + case 16: + { + int rawValue = input.readEnum(); + + stepScoping_ = rawValue; + break; + } + case 26: + { + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder subBuilder = null; + if (segmentFilterExpression_ != null) { + subBuilder = segmentFilterExpression_.toBuilder(); + } + segmentFilterExpression_ = + input.readMessage( + com.google.analytics.data.v1alpha.SegmentFilterExpression.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(segmentFilterExpression_); + segmentFilterExpression_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSequenceStep_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSequenceStep_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSequenceStep.class, + com.google.analytics.data.v1alpha.UserSequenceStep.Builder.class); + } + + public static final int IS_DIRECTLY_FOLLOWED_BY_FIELD_NUMBER = 1; + private boolean isDirectlyFollowedBy_; + /** + * + * + *
+   * If true, the event satisfying this step must be the very next event
+   * after the event satifying the last step. If false, this step indirectly
+   * follows the prior step; for example, there may be events between the
+   * prior step and this step. `isDirectlyFollowedBy` must be false for
+   * the first step.
+   * 
+ * + * bool is_directly_followed_by = 1; + * + * @return The isDirectlyFollowedBy. + */ + @java.lang.Override + public boolean getIsDirectlyFollowedBy() { + return isDirectlyFollowedBy_; + } + + public static final int STEP_SCOPING_FIELD_NUMBER = 2; + private int stepScoping_; + /** + * + * + *
+   * This sequence step must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+   * session for the user to match the sequence. `stepScoping =
+   * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+   * ACROSS_ALL_SESSIONS`.
+   * Optional. If unspecified, `stepScoping` uses the same
+   * `UserCriteriaScoping` as the `sequenceScoping`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return The enum numeric value on the wire for stepScoping. + */ + @java.lang.Override + public int getStepScopingValue() { + return stepScoping_; + } + /** + * + * + *
+   * This sequence step must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+   * session for the user to match the sequence. `stepScoping =
+   * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+   * ACROSS_ALL_SESSIONS`.
+   * Optional. If unspecified, `stepScoping` uses the same
+   * `UserCriteriaScoping` as the `sequenceScoping`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return The stepScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserCriteriaScoping getStepScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserCriteriaScoping result = + com.google.analytics.data.v1alpha.UserCriteriaScoping.valueOf(stepScoping_); + return result == null + ? com.google.analytics.data.v1alpha.UserCriteriaScoping.UNRECOGNIZED + : result; + } + + public static final int SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER = 3; + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + /** + * + * + *
+   * A user matches this sequence step if their events match this
+   * expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + @java.lang.Override + public boolean hasSegmentFilterExpression() { + return segmentFilterExpression_ != null; + } + /** + * + * + *
+   * A user matches this sequence step if their events match this
+   * expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + * + * @return The segmentFilterExpression. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + /** + * + * + *
+   * A user matches this sequence step if their events match this
+   * expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + return getSegmentFilterExpression(); + } + + 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 (isDirectlyFollowedBy_ != false) { + output.writeBool(1, isDirectlyFollowedBy_); + } + if (stepScoping_ + != com.google.analytics.data.v1alpha.UserCriteriaScoping.USER_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, stepScoping_); + } + if (segmentFilterExpression_ != null) { + output.writeMessage(3, getSegmentFilterExpression()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (isDirectlyFollowedBy_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, isDirectlyFollowedBy_); + } + if (stepScoping_ + != com.google.analytics.data.v1alpha.UserCriteriaScoping.USER_CRITERIA_SCOPING_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, stepScoping_); + } + if (segmentFilterExpression_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, getSegmentFilterExpression()); + } + size += unknownFields.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.analytics.data.v1alpha.UserSequenceStep)) { + return super.equals(obj); + } + com.google.analytics.data.v1alpha.UserSequenceStep other = + (com.google.analytics.data.v1alpha.UserSequenceStep) obj; + + if (getIsDirectlyFollowedBy() != other.getIsDirectlyFollowedBy()) return false; + if (stepScoping_ != other.stepScoping_) return false; + if (hasSegmentFilterExpression() != other.hasSegmentFilterExpression()) return false; + if (hasSegmentFilterExpression()) { + if (!getSegmentFilterExpression().equals(other.getSegmentFilterExpression())) return false; + } + if (!unknownFields.equals(other.unknownFields)) 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) + IS_DIRECTLY_FOLLOWED_BY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIsDirectlyFollowedBy()); + hash = (37 * hash) + STEP_SCOPING_FIELD_NUMBER; + hash = (53 * hash) + stepScoping_; + if (hasSegmentFilterExpression()) { + hash = (37 * hash) + SEGMENT_FILTER_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getSegmentFilterExpression().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep 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.analytics.data.v1alpha.UserSequenceStep parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.analytics.data.v1alpha.UserSequenceStep 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A condition that must occur in the specified step order for this user
+   * to match the sequence.
+   * 
+ * + * Protobuf type {@code google.analytics.data.v1alpha.UserSequenceStep} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.analytics.data.v1alpha.UserSequenceStep) + com.google.analytics.data.v1alpha.UserSequenceStepOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSequenceStep_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSequenceStep_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.analytics.data.v1alpha.UserSequenceStep.class, + com.google.analytics.data.v1alpha.UserSequenceStep.Builder.class); + } + + // Construct using com.google.analytics.data.v1alpha.UserSequenceStep.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + isDirectlyFollowedBy_ = false; + + stepScoping_ = 0; + + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.analytics.data.v1alpha.ReportingApiProto + .internal_static_google_analytics_data_v1alpha_UserSequenceStep_descriptor; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSequenceStep getDefaultInstanceForType() { + return com.google.analytics.data.v1alpha.UserSequenceStep.getDefaultInstance(); + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSequenceStep build() { + com.google.analytics.data.v1alpha.UserSequenceStep result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.analytics.data.v1alpha.UserSequenceStep buildPartial() { + com.google.analytics.data.v1alpha.UserSequenceStep result = + new com.google.analytics.data.v1alpha.UserSequenceStep(this); + result.isDirectlyFollowedBy_ = isDirectlyFollowedBy_; + result.stepScoping_ = stepScoping_; + if (segmentFilterExpressionBuilder_ == null) { + result.segmentFilterExpression_ = segmentFilterExpression_; + } else { + result.segmentFilterExpression_ = segmentFilterExpressionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.analytics.data.v1alpha.UserSequenceStep) { + return mergeFrom((com.google.analytics.data.v1alpha.UserSequenceStep) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.analytics.data.v1alpha.UserSequenceStep other) { + if (other == com.google.analytics.data.v1alpha.UserSequenceStep.getDefaultInstance()) + return this; + if (other.getIsDirectlyFollowedBy() != false) { + setIsDirectlyFollowedBy(other.getIsDirectlyFollowedBy()); + } + if (other.stepScoping_ != 0) { + setStepScopingValue(other.getStepScopingValue()); + } + if (other.hasSegmentFilterExpression()) { + mergeSegmentFilterExpression(other.getSegmentFilterExpression()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.analytics.data.v1alpha.UserSequenceStep parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.analytics.data.v1alpha.UserSequenceStep) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private boolean isDirectlyFollowedBy_; + /** + * + * + *
+     * If true, the event satisfying this step must be the very next event
+     * after the event satifying the last step. If false, this step indirectly
+     * follows the prior step; for example, there may be events between the
+     * prior step and this step. `isDirectlyFollowedBy` must be false for
+     * the first step.
+     * 
+ * + * bool is_directly_followed_by = 1; + * + * @return The isDirectlyFollowedBy. + */ + @java.lang.Override + public boolean getIsDirectlyFollowedBy() { + return isDirectlyFollowedBy_; + } + /** + * + * + *
+     * If true, the event satisfying this step must be the very next event
+     * after the event satifying the last step. If false, this step indirectly
+     * follows the prior step; for example, there may be events between the
+     * prior step and this step. `isDirectlyFollowedBy` must be false for
+     * the first step.
+     * 
+ * + * bool is_directly_followed_by = 1; + * + * @param value The isDirectlyFollowedBy to set. + * @return This builder for chaining. + */ + public Builder setIsDirectlyFollowedBy(boolean value) { + + isDirectlyFollowedBy_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If true, the event satisfying this step must be the very next event
+     * after the event satifying the last step. If false, this step indirectly
+     * follows the prior step; for example, there may be events between the
+     * prior step and this step. `isDirectlyFollowedBy` must be false for
+     * the first step.
+     * 
+ * + * bool is_directly_followed_by = 1; + * + * @return This builder for chaining. + */ + public Builder clearIsDirectlyFollowedBy() { + + isDirectlyFollowedBy_ = false; + onChanged(); + return this; + } + + private int stepScoping_ = 0; + /** + * + * + *
+     * This sequence step must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+     * session for the user to match the sequence. `stepScoping =
+     * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+     * ACROSS_ALL_SESSIONS`.
+     * Optional. If unspecified, `stepScoping` uses the same
+     * `UserCriteriaScoping` as the `sequenceScoping`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return The enum numeric value on the wire for stepScoping. + */ + @java.lang.Override + public int getStepScopingValue() { + return stepScoping_; + } + /** + * + * + *
+     * This sequence step must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+     * session for the user to match the sequence. `stepScoping =
+     * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+     * ACROSS_ALL_SESSIONS`.
+     * Optional. If unspecified, `stepScoping` uses the same
+     * `UserCriteriaScoping` as the `sequenceScoping`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @param value The enum numeric value on the wire for stepScoping to set. + * @return This builder for chaining. + */ + public Builder setStepScopingValue(int value) { + + stepScoping_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * This sequence step must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+     * session for the user to match the sequence. `stepScoping =
+     * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+     * ACROSS_ALL_SESSIONS`.
+     * Optional. If unspecified, `stepScoping` uses the same
+     * `UserCriteriaScoping` as the `sequenceScoping`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return The stepScoping. + */ + @java.lang.Override + public com.google.analytics.data.v1alpha.UserCriteriaScoping getStepScoping() { + @SuppressWarnings("deprecation") + com.google.analytics.data.v1alpha.UserCriteriaScoping result = + com.google.analytics.data.v1alpha.UserCriteriaScoping.valueOf(stepScoping_); + return result == null + ? com.google.analytics.data.v1alpha.UserCriteriaScoping.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * This sequence step must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+     * session for the user to match the sequence. `stepScoping =
+     * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+     * ACROSS_ALL_SESSIONS`.
+     * Optional. If unspecified, `stepScoping` uses the same
+     * `UserCriteriaScoping` as the `sequenceScoping`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @param value The stepScoping to set. + * @return This builder for chaining. + */ + public Builder setStepScoping(com.google.analytics.data.v1alpha.UserCriteriaScoping value) { + if (value == null) { + throw new NullPointerException(); + } + + stepScoping_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * This sequence step must be satisfied in the scoping for the user to
+     * match the sequence. For example if `sequenceScoping =
+     * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+     * session for the user to match the sequence. `stepScoping =
+     * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+     * ACROSS_ALL_SESSIONS`.
+     * Optional. If unspecified, `stepScoping` uses the same
+     * `UserCriteriaScoping` as the `sequenceScoping`.
+     * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return This builder for chaining. + */ + public Builder clearStepScoping() { + + stepScoping_ = 0; + onChanged(); + return this; + } + + private com.google.analytics.data.v1alpha.SegmentFilterExpression segmentFilterExpression_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + segmentFilterExpressionBuilder_; + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + public boolean hasSegmentFilterExpression() { + return segmentFilterExpressionBuilder_ != null || segmentFilterExpression_ != null; + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + * + * @return The segmentFilterExpression. + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } else { + return segmentFilterExpressionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + segmentFilterExpression_ = value; + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + public Builder setSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder builderForValue) { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = builderForValue.build(); + onChanged(); + } else { + segmentFilterExpressionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + public Builder mergeSegmentFilterExpression( + com.google.analytics.data.v1alpha.SegmentFilterExpression value) { + if (segmentFilterExpressionBuilder_ == null) { + if (segmentFilterExpression_ != null) { + segmentFilterExpression_ = + com.google.analytics.data.v1alpha.SegmentFilterExpression.newBuilder( + segmentFilterExpression_) + .mergeFrom(value) + .buildPartial(); + } else { + segmentFilterExpression_ = value; + } + onChanged(); + } else { + segmentFilterExpressionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + public Builder clearSegmentFilterExpression() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpression_ = null; + onChanged(); + } else { + segmentFilterExpression_ = null; + segmentFilterExpressionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder + getSegmentFilterExpressionBuilder() { + + onChanged(); + return getSegmentFilterExpressionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + public com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder() { + if (segmentFilterExpressionBuilder_ != null) { + return segmentFilterExpressionBuilder_.getMessageOrBuilder(); + } else { + return segmentFilterExpression_ == null + ? com.google.analytics.data.v1alpha.SegmentFilterExpression.getDefaultInstance() + : segmentFilterExpression_; + } + } + /** + * + * + *
+     * A user matches this sequence step if their events match this
+     * expression. Expressions express criteria on dimension, metrics,
+     * and/or parameters.
+     * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder> + getSegmentFilterExpressionFieldBuilder() { + if (segmentFilterExpressionBuilder_ == null) { + segmentFilterExpressionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.analytics.data.v1alpha.SegmentFilterExpression, + com.google.analytics.data.v1alpha.SegmentFilterExpression.Builder, + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder>( + getSegmentFilterExpression(), getParentForChildren(), isClean()); + segmentFilterExpression_ = null; + } + return segmentFilterExpressionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.analytics.data.v1alpha.UserSequenceStep) + } + + // @@protoc_insertion_point(class_scope:google.analytics.data.v1alpha.UserSequenceStep) + private static final com.google.analytics.data.v1alpha.UserSequenceStep DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.analytics.data.v1alpha.UserSequenceStep(); + } + + public static com.google.analytics.data.v1alpha.UserSequenceStep getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UserSequenceStep parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UserSequenceStep(input, extensionRegistry); + } + }; + + 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.analytics.data.v1alpha.UserSequenceStep getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStepOrBuilder.java b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStepOrBuilder.java new file mode 100644 index 00000000..10774001 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/java/com/google/analytics/data/v1alpha/UserSequenceStepOrBuilder.java @@ -0,0 +1,126 @@ +/* + * Copyright 2020 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! +// source: google/analytics/data/v1alpha/data.proto + +package com.google.analytics.data.v1alpha; + +public interface UserSequenceStepOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.analytics.data.v1alpha.UserSequenceStep) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * If true, the event satisfying this step must be the very next event
+   * after the event satifying the last step. If false, this step indirectly
+   * follows the prior step; for example, there may be events between the
+   * prior step and this step. `isDirectlyFollowedBy` must be false for
+   * the first step.
+   * 
+ * + * bool is_directly_followed_by = 1; + * + * @return The isDirectlyFollowedBy. + */ + boolean getIsDirectlyFollowedBy(); + + /** + * + * + *
+   * This sequence step must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+   * session for the user to match the sequence. `stepScoping =
+   * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+   * ACROSS_ALL_SESSIONS`.
+   * Optional. If unspecified, `stepScoping` uses the same
+   * `UserCriteriaScoping` as the `sequenceScoping`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return The enum numeric value on the wire for stepScoping. + */ + int getStepScopingValue(); + /** + * + * + *
+   * This sequence step must be satisfied in the scoping for the user to
+   * match the sequence. For example if `sequenceScoping =
+   * WITHIN_SAME_SESSION`, this sequence steps must complete within one
+   * session for the user to match the sequence. `stepScoping =
+   * ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping =
+   * ACROSS_ALL_SESSIONS`.
+   * Optional. If unspecified, `stepScoping` uses the same
+   * `UserCriteriaScoping` as the `sequenceScoping`.
+   * 
+ * + * .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * + * @return The stepScoping. + */ + com.google.analytics.data.v1alpha.UserCriteriaScoping getStepScoping(); + + /** + * + * + *
+   * A user matches this sequence step if their events match this
+   * expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + * + * @return Whether the segmentFilterExpression field is set. + */ + boolean hasSegmentFilterExpression(); + /** + * + * + *
+   * A user matches this sequence step if their events match this
+   * expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + * + * @return The segmentFilterExpression. + */ + com.google.analytics.data.v1alpha.SegmentFilterExpression getSegmentFilterExpression(); + /** + * + * + *
+   * A user matches this sequence step if their events match this
+   * expression. Expressions express criteria on dimension, metrics,
+   * and/or parameters.
+   * 
+ * + * .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * + */ + com.google.analytics.data.v1alpha.SegmentFilterExpressionOrBuilder + getSegmentFilterExpressionOrBuilder(); +} diff --git a/proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/analytics_data_api.proto b/proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/analytics_data_api.proto new file mode 100644 index 00000000..64be8151 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/analytics_data_api.proto @@ -0,0 +1,166 @@ +// Copyright 2022 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. + +syntax = "proto3"; + +package google.analytics.data.v1alpha; + +import "google/analytics/data/v1alpha/data.proto"; +import "google/api/annotations.proto"; +import "google/api/client.proto"; + +option go_package = "google.golang.org/genproto/googleapis/analytics/data/v1alpha;data"; +option java_multiple_files = true; +option java_outer_classname = "AnalyticsDataApiProto"; +option java_package = "com.google.analytics.data.v1alpha"; + +// Google Analytics reporting data service. +service AlphaAnalyticsData { + option (google.api.default_host) = "analyticsdata.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/analytics," + "https://www.googleapis.com/auth/analytics.readonly"; + + // Returns a customized funnel report of your Google Analytics event data. The + // data returned from the API is as a table with columns for the requested + // dimensions and metrics. + // + // Funnel exploration lets you visualize the steps your users take to complete + // a task and quickly see how well they are succeeding or failing at each + // step. For example, how do prospects become shoppers and then become buyers? + // How do one time buyers become repeat buyers? With this information, you can + // improve inefficient or abandoned customer journeys. To learn more, see [GA4 + // Funnel Explorations](https://support.google.com/analytics/answer/9327974). + rpc RunFunnelReport(RunFunnelReportRequest) returns (RunFunnelReportResponse) { + option (google.api.http) = { + post: "/v1alpha/{property=properties/*}:runFunnelReport" + body: "*" + }; + } +} + +// The request for a funnel report. +message RunFunnelReportRequest { + // Controls the dimensions present in the funnel visualization sub report + // response. + enum FunnelVisualizationType { + // Unspecified type. + FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; + + // A standard (stepped) funnel. The funnel visualization sub report in the + // response will not contain date. + STANDARD_FUNNEL = 1; + + // A trended (line chart) funnel. The funnel visualization sub report in the + // response will contain the date dimension. + TRENDED_FUNNEL = 2; + } + + // A Google Analytics GA4 property identifier whose events are tracked. + // Specified in the URL path and not the body. To learn more, see [where to + // find your Property + // ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + // Within a batch request, this property should either be unspecified or + // consistent with the batch-level property. + // + // Example: properties/1234 + string property = 1; + + // Date ranges of data to read. If multiple date ranges are requested, each + // response row will contain a zero based date range index. If two date + // ranges overlap, the event data for the overlapping days is included in the + // response rows for both date ranges. + repeated DateRange date_ranges = 2; + + // The configuration of this request's funnel. This funnel configuration is + // required. + Funnel funnel = 3; + + // If specified, this breakdown adds a dimension to the funnel table sub + // report response. This breakdown dimension expands each funnel step to the + // unique values of the breakdown dimension. For example, a breakdown by the + // `deviceCategory` dimension will create rows for `mobile`, `tablet`, + // `desktop`, and the total. + FunnelBreakdown funnel_breakdown = 4; + + // If specified, next action adds a dimension to the funnel visualization sub + // report response. This next action dimension expands each funnel step to the + // unique values of the next action. For example a breakdown by the + // `eventName` dimension will create rows for several events (i.e. + // `session_start` & `click`) and the total. + FunnelNextAction funnel_next_action = 5; + + // The funnel visualization type controls the dimensions present in the funnel + // visualization sub report response. If not specified, `STANDARD_FUNNEL` is + // used. + FunnelVisualizationType funnel_visualization_type = 6; + + // The configurations of segments. Segments are subsets of a property's data. + // In a funnel report with segments, the funnel is evaluated in each segment. + // + // Each segment specified in this request + // produces a separate row in the response; in the response, each segment + // identified by its name. + // + // The segments parameter is optional. Requests are limited to 4 segments. + repeated Segment segments = 7; + + // The number of rows to return. If unspecified, 10,000 rows are returned. The + // API returns a maximum of 100,000 rows per request, no matter how many you + // ask for. `limit` must be positive. + // + // The API can also return fewer rows than the requested `limit`, if there + // aren't as many dimension values as the `limit`. + int64 limit = 9; + + // Dimension filters allow you to ask for only specific dimension values in + // the report. To learn more, see [Creating a Report: Dimension + // Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + // for examples. Metrics cannot be used in this filter. + FilterExpression dimension_filter = 10; + + // Toggles whether to return the current state of this Analytics Property's + // quota. Quota is returned in [PropertyQuota](#PropertyQuota). + bool return_property_quota = 12; +} + +// The funnel report response contains two sub reports. The two sub reports are +// different combinations of dimensions and metrics. +message RunFunnelReportResponse { + // The funnel table is a report with the funnel step, segment, breakdown + // dimension, active users, completion rate, abandonments, and abandonments + // rate. + // + // The segment dimension is only present in this response if a segment was + // requested. The breakdown dimension is only present in this response if it + // was requested. + FunnelSubReport funnel_table = 1; + + // The funnel visualization is a report with the funnel step, segment, date, + // next action dimension, and active users. + // + // The segment dimension is only present in this response if a segment was + // requested. The date dimension is only present in this response if it was + // requested via the `TRENDED_FUNNEL` funnel type. The next action dimension + // is only present in the response if it was requested. + FunnelSubReport funnel_visualization = 2; + + // This Analytics Property's quota state including this request. + PropertyQuota property_quota = 3; + + // Identifies what kind of resource this message is. This `kind` is always the + // fixed string "analyticsData#runFunnelReport". Useful to distinguish between + // response types in JSON. + string kind = 4; +} diff --git a/proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/data.proto b/proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/data.proto new file mode 100644 index 00000000..6c566e20 --- /dev/null +++ b/proto-google-analytics-data-v1alpha/src/main/proto/google/analytics/data/v1alpha/data.proto @@ -0,0 +1,1230 @@ +// Copyright 2022 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. + +syntax = "proto3"; + +package google.analytics.data.v1alpha; + +import "google/protobuf/duration.proto"; + +option go_package = "google.golang.org/genproto/googleapis/analytics/data/v1alpha;data"; +option java_multiple_files = true; +option java_outer_classname = "ReportingApiProto"; +option java_package = "com.google.analytics.data.v1alpha"; + +// A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests +// are allowed up to 4 date ranges. +message DateRange { + // The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot + // be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also + // accepted, and in that case, the date is inferred based on the property's + // reporting time zone. + string start_date = 1; + + // The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot + // be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is + // also accepted, and in that case, the date is inferred based on the + // property's reporting time zone. + string end_date = 2; + + // Assigns a name to this date range. The dimension `dateRange` is valued to + // this name in a report response. If set, cannot begin with `date_range_` or + // `RESERVED_`. If not set, date ranges are named by their zero based index in + // the request: `date_range_0`, `date_range_1`, etc. + string name = 3; +} + +// Dimensions are attributes of your data. For example, the dimension city +// indicates the city from which an event originates. Dimension values in report +// responses are strings; for example, the city could be "Paris" or "New York". +message Dimension { + // The name of the dimension. See the [API + // Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#dimensions) + // for the list of dimension names. + // + // If `dimensionExpression` is specified, `name` can be any string that you + // would like within the allowed character set. For example if a + // `dimensionExpression` concatenates `country` and `city`, you could call + // that dimension `countryAndCity`. Dimension names that you choose must match + // the regular expression `^[a-zA-Z0-9_]$`. + // + // Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`, + // `dimensionExpression`, and `pivots`. + string name = 1; + + // One dimension can be the result of an expression of multiple dimensions. + // For example, dimension "country, city": concatenate(country, ", ", city). + DimensionExpression dimension_expression = 2; +} + +// Used to express a dimension which is the result of a formula of multiple +// dimensions. Example usages: +// 1) lower_case(dimension) +// 2) concatenate(dimension1, symbol, dimension2). +message DimensionExpression { + // Used to convert a dimension value to a single case. + message CaseExpression { + // Name of a dimension. The name must refer back to a name in dimensions + // field of the request. + string dimension_name = 1; + } + + // Used to combine dimension values to a single dimension. + message ConcatenateExpression { + // Names of dimensions. The names must refer back to names in the dimensions + // field of the request. + repeated string dimension_names = 1; + + // The delimiter placed between dimension names. + // + // Delimiters are often single characters such as "|" or "," but can be + // longer strings. If a dimension value contains the delimiter, both will be + // present in response with no distinction. For example if dimension 1 value + // = "US,FR", dimension 2 value = "JP", and delimiter = ",", then the + // response will contain "US,FR,JP". + string delimiter = 2; + } + + // Specify one type of dimension expression for `DimensionExpression`. + oneof one_expression { + // Used to convert a dimension value to lower case. + CaseExpression lower_case = 4; + + // Used to convert a dimension value to upper case. + CaseExpression upper_case = 5; + + // Used to combine dimension values to a single dimension. + // For example, dimension "country, city": concatenate(country, ", ", city). + ConcatenateExpression concatenate = 6; + } +} + +// To express dimension or metric filters. The fields in the same +// FilterExpression need to be either all dimensions or all metrics. +message FilterExpression { + // Specify one type of filter expression for `FilterExpression`. + oneof expr { + // The FilterExpressions in and_group have an AND relationship. + FilterExpressionList and_group = 1; + + // The FilterExpressions in or_group have an OR relationship. + FilterExpressionList or_group = 2; + + // The FilterExpression is NOT of not_expression. + FilterExpression not_expression = 3; + + // A primitive filter. In the same FilterExpression, all of the filter's + // field names need to be either all dimensions or all metrics. + Filter filter = 4; + } +} + +// A list of filter expressions. +message FilterExpressionList { + // A list of filter expressions. + repeated FilterExpression expressions = 1; +} + +// An expression to filter dimension or metric values. +message Filter { + // The dimension name or metric name. Must be a name defined in dimensions + // or metrics. + string field_name = 1; + + // Specify one type of filter for `Filter`. + oneof one_filter { + // Strings related filter. + StringFilter string_filter = 2; + + // A filter for in list values. + InListFilter in_list_filter = 3; + + // A filter for numeric or date values. + NumericFilter numeric_filter = 4; + + // A filter for between two values. + BetweenFilter between_filter = 5; + } +} + +// The filter for string +message StringFilter { + // The match type of a string filter + enum MatchType { + // Unspecified + MATCH_TYPE_UNSPECIFIED = 0; + + // Exact match of the string value. + EXACT = 1; + + // Begins with the string value. + BEGINS_WITH = 2; + + // Ends with the string value. + ENDS_WITH = 3; + + // Contains the string value. + CONTAINS = 4; + + // Full match for the regular expression with the string value. + FULL_REGEXP = 5; + + // Partial match for the regular expression with the string value. + PARTIAL_REGEXP = 6; + } + + // The match type for this filter. + MatchType match_type = 1; + + // The string value used for the matching. + string value = 2; + + // If true, the string value is case sensitive. + bool case_sensitive = 3; +} + +// The result needs to be in a list of string values. +message InListFilter { + // The list of string values. + // Must be non-empty. + repeated string values = 1; + + // If true, the string value is case sensitive. + bool case_sensitive = 2; +} + +// Filters for numeric or date values. +message NumericFilter { + // The operation applied to a numeric filter + enum Operation { + // Unspecified. + OPERATION_UNSPECIFIED = 0; + + // Equal + EQUAL = 1; + + // Less than + LESS_THAN = 2; + + // Less than or equal + LESS_THAN_OR_EQUAL = 3; + + // Greater than + GREATER_THAN = 4; + + // Greater than or equal + GREATER_THAN_OR_EQUAL = 5; + } + + // The operation type for this filter. + Operation operation = 1; + + // A numeric value or a date value. + NumericValue value = 2; +} + +// To express that the result needs to be between two numbers (inclusive). +message BetweenFilter { + // Begins with this number. + NumericValue from_value = 1; + + // Ends with this number. + NumericValue to_value = 2; +} + +// To represent a number. +message NumericValue { + // One of a numeric value + oneof one_value { + // Integer value + int64 int64_value = 1; + + // Double value + double double_value = 2; + } +} + +// Describes a dimension column in the report. Dimensions requested in a report +// produce column entries within rows and DimensionHeaders. However, dimensions +// used exclusively within filters or expressions do not produce columns in a +// report; correspondingly, those dimensions do not produce headers. +message DimensionHeader { + // The dimension's name. + string name = 1; +} + +// Describes a metric column in the report. Visible metrics requested in a +// report produce column entries within rows and MetricHeaders. However, +// metrics used exclusively within filters or expressions do not produce columns +// in a report; correspondingly, those metrics do not produce headers. +message MetricHeader { + // The metric's name. + string name = 1; + + // The metric's data type. + MetricType type = 2; +} + +// Report data for each row. +// For example if RunReportRequest contains: +// +// ```none +// "dimensions": [ +// { +// "name": "eventName" +// }, +// { +// "name": "countryId" +// } +// ], +// "metrics": [ +// { +// "name": "eventCount" +// } +// ] +// ``` +// +// One row with 'in_app_purchase' as the eventName, 'JP' as the countryId, and +// 15 as the eventCount, would be: +// +// ```none +// "dimensionValues": [ +// { +// "value": "in_app_purchase" +// }, +// { +// "value": "JP" +// } +// ], +// "metricValues": [ +// { +// "value": "15" +// } +// ] +// ``` +message Row { + // List of requested dimension values. In a PivotReport, dimension_values + // are only listed for dimensions included in a pivot. + repeated DimensionValue dimension_values = 1; + + // List of requested visible metric values. + repeated MetricValue metric_values = 2; +} + +// The value of a dimension. +message DimensionValue { + // One kind of dimension value + oneof one_value { + // Value as a string if the dimension type is a string. + string value = 1; + } +} + +// The value of a metric. +message MetricValue { + // One of metric value + oneof one_value { + // Measurement value. See MetricHeader for type. + string value = 4; + } +} + +// Current state of all quotas for this Analytics Property. If any quota for a +// property is exhausted, all requests to that property will return Resource +// Exhausted errors. +message PropertyQuota { + // Standard Analytics Properties can use up to 25,000 tokens per day; + // Analytics 360 Properties can use 250,000 tokens per day. Most requests + // consume fewer than 10 tokens. + QuotaStatus tokens_per_day = 1; + + // Standard Analytics Properties can use up to 5,000 tokens per hour; + // Analytics 360 Properties can use 50,000 tokens per hour. An API request + // consumes a single number of tokens, and that number is deducted from both + // the hourly and daily quotas. + QuotaStatus tokens_per_hour = 2; + + // Standard Analytics Properties can send up to 10 concurrent requests; + // Analytics 360 Properties can use up to 50 concurrent requests. + QuotaStatus concurrent_requests = 3; + + // Standard Analytics Properties and cloud project pairs can have up to 10 + // server errors per hour; Analytics 360 Properties and cloud project pairs + // can have up to 50 server errors per hour. + QuotaStatus server_errors_per_project_per_hour = 4; + + // Analytics Properties can send up to 120 requests with potentially + // thresholded dimensions per hour. In a batch request, each report request + // is individually counted for this quota if the request contains potentially + // thresholded dimensions. + QuotaStatus potentially_thresholded_requests_per_hour = 5; +} + +// Current state for a particular quota group. +message QuotaStatus { + // Quota consumed by this request. + int32 consumed = 1; + + // Quota remaining after this request. + int32 remaining = 2; +} + +// Breakdowns add a dimension to the funnel table sub report response. +message FunnelBreakdown { + // The dimension column added to the funnel table sub report response. The + // breakdown dimension breaks down each funnel step. A valid + // `breakdownDimension` is required if `funnelBreakdown` is specified. + Dimension breakdown_dimension = 1; + + // The maximum number of distinct values of the breakdown dimension to return + // in the response. A `limit` of `5` is used if limit is not specified. Limit + // must exceed zero and cannot exceed 15. + optional int64 limit = 2; +} + +// Next actions state the value for a dimension after the user has achieved +// a step but before the same user has achieved the next step. For example if +// the `nextActionDimension` is `eventName`, then `nextActionDimension` in the +// `i`th funnel step row will return first event after the event that qualified +// the user into the `i`th funnel step but before the user achieved the `i+1`th +// funnel step. +message FunnelNextAction { + // The dimension column added to the funnel visualization sub report response. + // The next action dimension returns the next dimension value of this + // dimension after the user has attained the `i`th funnel step. + // `nextActionDimension` currently only supports the `eventName` dimension. + Dimension next_action_dimension = 1; + + // The maximum number of distinct values of the breakdown dimension to return + // in the response. A `limit` of `5` is used if limit is not specified. Limit + // must exceed zero and cannot exceed 5. + optional int64 limit = 2; +} + +// Configures the funnel in a funnel report request. A funnel reports on users +// as they pass through a sequence of steps. +// +// Funnel exploration lets you visualize the steps your users take to complete a +// task and quickly see how well they are succeeding or failing at each step. +// For example, how do prospects become shoppers and then become buyers? How do +// one time buyers become repeat buyers? With this information, you can improve +// inefficient or abandoned customer journeys. +message Funnel { + // In an open funnel, users can enter the funnel in any step, and in a closed + // funnel, users must enter the funnel in the first step. Optional. If + // unspecified, a closed funnel is used. + bool is_open_funnel = 1; + + // The sequential steps of this funnel. + repeated FunnelStep steps = 2; +} + +// Steps define the user journey you want to measure. Steps contain one or +// more conditions that your users must meet to be included in that step of +// the funnel journey. +message FunnelStep { + // The distinctive name for this step. If unspecified, steps will be named + // by a 1 based indexed name (i.e. "0. ", "1. ", etc.). This name defines + // string value returned by the `funnelStepName` dimension. For example, + // specifying `name = Purchase` in the request's third funnel step will + // produce `3. Purchase` in the funnel report response. + string name = 1; + + // If true, this step must directly follow the previous step. If false, + // there can be events between the previous step and this step. If + // unspecified, `isDirectlyFollowedBy` is treated as false. + bool is_directly_followed_by = 2; + + // If specified, this step must complete within this duration of the + // completion of the prior step. `withinDurationFromPriorStep` is inclusive + // of the endpoint at the microsecond granularity. For example a duration of + // 5 seconds can be completed at 4.9 or 5.0 seconds, but not 5 seconds and 1 + // microsecond. + // + // `withinDurationFromPriorStep` is optional, and if unspecified, steps may + // be separated by any time duration. + optional google.protobuf.Duration within_duration_from_prior_step = 3; + + // The condition that your users must meet to be included in this step of + // the funnel journey. + FunnelFilterExpression filter_expression = 4; +} + +// Funnel sub reports contain the dimension and metric data values. For example, +// 12 users reached the second step of the funnel. +message FunnelSubReport { + // Describes dimension columns. Funnel reports always include the funnel step + // dimension in sub report responses. Additional dimensions like breakdowns, + // dates, and next actions may be present in the response if requested. + repeated DimensionHeader dimension_headers = 1; + + // Describes metric columns. Funnel reports always include active users in sub + // report responses. The funnel table includes additional metrics like + // completion rate, abandonments, and abandonments rate. + repeated MetricHeader metric_headers = 2; + + // Rows of dimension value combinations and metric values in the report. + repeated Row rows = 3; + + // Metadata for the funnel report. + FunnelResponseMetadata metadata = 4; +} + +// User segments are subsets of users who engaged with your site or app. For +// example, users who have previously purchased; users who added items to their +// shopping carts, but didn’t complete a purchase. +message UserSegment { + // Defines which users are included in this segment. Optional. + UserSegmentCriteria user_inclusion_criteria = 1; + + // Defines which users are excluded in this segment. Optional. + UserSegmentExclusion exclusion = 2; +} + +// A user matches a criteria if the user's events meet the conditions in the +// criteria. +message UserSegmentCriteria { + // A user matches this criteria if the user matches each of these + // `andConditionGroups` and each of the `andSequenceGroups`. + // `andConditionGroups` may be empty if `andSequenceGroups` are specified. + repeated UserSegmentConditionGroup and_condition_groups = 1; + + // A user matches this criteria if the user matches each of these + // `andSequenceGroups` and each of the `andConditionGroups`. + // `andSequenceGroups` may be empty if `andConditionGroups` are specified. + repeated UserSegmentSequenceGroup and_sequence_groups = 2; +} + +// Scoping specifies which events are considered when evaluating if a user +// meets a criteria. +enum UserCriteriaScoping { + // Unspecified criteria scoping. Do not specify. + USER_CRITERIA_SCOPING_UNSPECIFIED = 0; + + // If the criteria is satisfied within one event, the user matches the + // criteria. + USER_CRITERIA_WITHIN_SAME_EVENT = 1; + + // If the criteria is satisfied within one session, the user matches the + // criteria. + USER_CRITERIA_WITHIN_SAME_SESSION = 2; + + // If the criteria is satisfied by any events for the user, the user + // matches the criteria. + USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; +} + +// Conditions tell Analytics what data to include in or exclude from the +// segment. +message UserSegmentConditionGroup { + // Data is included or excluded from the segment based on if it matches + // the condition group. This scoping defines how many events the + // `segmentFilterExpression` is evaluated on before the condition group + // is determined to be matched or not. For example if `conditionScoping = + // USER_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all + // events in a session, and then, the condition group is determined to be + // matched or not for this user. For example if `conditionScoping = + // USER_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a single + // event, and then, the condition group is determined to be matched or not for + // this user. + // + // Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is + // used. + UserCriteriaScoping condition_scoping = 1; + + // Data is included or excluded from the segment based on if it matches + // this expression. Expressions express criteria on dimension, metrics, + // and/or parameters. + SegmentFilterExpression segment_filter_expression = 2; +} + +// Define conditions that must occur in a specific order for the user to be +// a member of the segment. +message UserSegmentSequenceGroup { + // All sequence steps must be satisfied in the scoping for the user to + // match the sequence. For example if `sequenceScoping = + // USER_CRITERIA_WITHIN_SAME_SESSION`, all sequence steps must complete within + // one session for the user to match the sequence. `sequenceScoping = + // USER_CRITERIA_WITHIN_SAME_EVENT` is not supported. + // + // Optional. If unspecified, `conditionScoping = ACROSS_ALL_SESSIONS` is + // used. + UserCriteriaScoping sequence_scoping = 1; + + // Defines the time period in which the whole sequence must occur; for + // example, 30 Minutes. `sequenceMaximumDuration` is inclusive + // of the endpoint at the microsecond granularity. For example a sequence + // with a maximum duration of 5 seconds can be completed at 4.9 or 5.0 + // seconds, but not 5 seconds and 1 microsecond. + // + // `sequenceMaximumDuration` is optional, and if unspecified, sequences can + // be completed in any time duration. + google.protobuf.Duration sequence_maximum_duration = 2; + + // An ordered sequence of condition steps. A user's events must complete + // each step in order for the user to match the + // `UserSegmentSequenceGroup`. + repeated UserSequenceStep user_sequence_steps = 3; +} + +// A condition that must occur in the specified step order for this user +// to match the sequence. +message UserSequenceStep { + // If true, the event satisfying this step must be the very next event + // after the event satifying the last step. If false, this step indirectly + // follows the prior step; for example, there may be events between the + // prior step and this step. `isDirectlyFollowedBy` must be false for + // the first step. + bool is_directly_followed_by = 1; + + // This sequence step must be satisfied in the scoping for the user to + // match the sequence. For example if `sequenceScoping = + // WITHIN_SAME_SESSION`, this sequence steps must complete within one + // session for the user to match the sequence. `stepScoping = + // ACROSS_ALL_SESSIONS` is only allowed if the `sequenceScoping = + // ACROSS_ALL_SESSIONS`. + // + // Optional. If unspecified, `stepScoping` uses the same + // `UserCriteriaScoping` as the `sequenceScoping`. + UserCriteriaScoping step_scoping = 2; + + // A user matches this sequence step if their events match this + // expression. Expressions express criteria on dimension, metrics, + // and/or parameters. + SegmentFilterExpression segment_filter_expression = 3; +} + +// Specifies which users are excluded in this segment. +message UserSegmentExclusion { + // Specifies how long an exclusion will last if a user matches the + // `userExclusionCriteria`. + // + // Optional. If unspecified, `userExclusionDuration` of + // `USER_EXCLUSION_TEMPORARY` is used. + UserExclusionDuration user_exclusion_duration = 1; + + // If a user meets this condition, the user is excluded from membership in + // the segment for the `userExclusionDuration`. + UserSegmentCriteria user_exclusion_criteria = 2; +} + +// Enumerates options for how long an exclusion will last if a user matches +// the `userExclusionCriteria`. +enum UserExclusionDuration { + // Unspecified exclusion duration. Do not specify. + USER_EXCLUSION_DURATION_UNSPECIFIED = 0; + + // Temporarily exclude users from the segment during periods when the + // user meets the `userExclusionCriteria` condition. + USER_EXCLUSION_TEMPORARY = 1; + + // Permanently exclude users from the segment if the user ever meets the + // `userExclusionCriteria` condition. + USER_EXCLUSION_PERMANENT = 2; +} + +// Session segments are subsets of the sessions that occurred on your site or +// app: for example, all the sessions that originated from a particular +// advertising campaign. +message SessionSegment { + // Defines which sessions are included in this segment. Optional. + SessionSegmentCriteria session_inclusion_criteria = 1; + + // Defines which sessions are excluded in this segment. Optional. + SessionSegmentExclusion exclusion = 2; +} + +// A session matches a criteria if the session's events meet the conditions in +// the criteria. +message SessionSegmentCriteria { + // A session matches this criteria if the session matches each of these + // `andConditionGroups`. + repeated SessionSegmentConditionGroup and_condition_groups = 1; +} + +// Scoping specifies which events are considered when evaluating if a +// session meets a criteria. +enum SessionCriteriaScoping { + // Unspecified criteria scoping. Do not specify. + SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; + + // If the criteria is satisfied within one event, the session matches the + // criteria. + SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; + + // If the criteria is satisfied within one session, the session matches + // the criteria. + SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; +} + +// Conditions tell Analytics what data to include in or exclude from the +// segment. +message SessionSegmentConditionGroup { + // Data is included or excluded from the segment based on if it matches + // the condition group. This scoping defines how many events the + // `segmentFilterExpression` is evaluated on before the condition group + // is determined to be matched or not. For example if `conditionScoping = + // SESSION_CRITERIA_WITHIN_SAME_SESSION`, the expression is evaluated on all + // events in a session, and then, the condition group is determined to be + // matched or not for this session. For example if `conditionScoping = + // SESSION_CRITERIA_WITHIN_SAME_EVENT`, the expression is evaluated on a + // single event, and then, the condition group is determined to be matched or + // not for this session. + // + // Optional. If unspecified, a `conditionScoping` of `WITHIN_SAME_SESSION` + // is used. + SessionCriteriaScoping condition_scoping = 1; + + // Data is included or excluded from the segment based on if it matches + // this expression. Expressions express criteria on dimension, metrics, + // and/or parameters. + SegmentFilterExpression segment_filter_expression = 2; +} + +// Specifies which sessions are excluded in this segment. +message SessionSegmentExclusion { + // Specifies how long an exclusion will last if a session matches the + // `sessionExclusionCriteria`. + // + // Optional. If unspecified, a `sessionExclusionDuration` of + // `SESSION_EXCLUSION_TEMPORARY` is used. + SessionExclusionDuration session_exclusion_duration = 1; + + // If a session meets this condition, the session is excluded from + // membership in the segment for the `sessionExclusionDuration`. + SessionSegmentCriteria session_exclusion_criteria = 2; +} + +// Enumerates options for how long an exclusion will last if a session +// matches the `sessionExclusionCriteria`. +enum SessionExclusionDuration { + // Unspecified exclusion duration. Do not specify. + SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; + + // Temporarily exclude sessions from the segment during periods when the + // session meets the `sessionExclusionCriteria` condition. + SESSION_EXCLUSION_TEMPORARY = 1; + + // Permanently exclude sessions from the segment if the session ever meets + // the `sessionExclusionCriteria` condition. + SESSION_EXCLUSION_PERMANENT = 2; +} + +// Event segments are subsets of events that were triggered on your site or app. +// for example, all purchase events made in a particular location; app_exception +// events that occurred on a specific operating system. +message EventSegment { + // Defines which events are included in this segment. Optional. + EventSegmentCriteria event_inclusion_criteria = 1; + + // Defines which events are excluded in this segment. Optional. + EventSegmentExclusion exclusion = 2; +} + +// An event matches a criteria if the event meet the conditions in the +// criteria. +message EventSegmentCriteria { + // An event matches this criteria if the event matches each of these + // `andConditionGroups`. + repeated EventSegmentConditionGroup and_condition_groups = 1; +} + +// Scoping specifies which events are considered when evaluating if an event +// meets a criteria. +enum EventCriteriaScoping { + // Unspecified criteria scoping. Do not specify. + EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; + + // If the criteria is satisfied within one event, the event matches the + // criteria. + EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; +} + +// Conditions tell Analytics what data to include in or exclude from the +// segment. +message EventSegmentConditionGroup { + // `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. + // + // Optional. If unspecified, a `conditionScoping` of + // `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. + EventCriteriaScoping condition_scoping = 1; + + // Data is included or excluded from the segment based on if it matches + // this expression. Expressions express criteria on dimension, metrics, + // and/or parameters. + SegmentFilterExpression segment_filter_expression = 2; +} + +// Specifies which events are excluded in this segment. +message EventSegmentExclusion { + // `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. + // + // Optional. If unspecified, an `eventExclusionDuration` of + // `EVENT_EXCLUSION_PERMANENT` is used. + EventExclusionDuration event_exclusion_duration = 1; + + // If an event meets this condition, the event is excluded from membership + // in the segment for the `eventExclusionDuration`. + EventSegmentCriteria event_exclusion_criteria = 2; +} + +// Enumerates options for how long an exclusion will last if an event +// matches the `eventExclusionCriteria`. +enum EventExclusionDuration { + // Unspecified exclusion duration. Do not specify. + EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; + + // Permanently exclude events from the segment if the event ever meets + // the `eventExclusionCriteria` condition. + EVENT_EXCLUSION_PERMANENT = 1; +} + +// A segment is a subset of your Analytics data. For example, of your entire set +// of users, one segment might be users from a particular country or city. +// Another segment might be users who purchase a particular line of products or +// who visit a specific part of your site or trigger certain events in your app. +// +// To learn more, see [GA4 Segment +// Builder](https://support.google.com/analytics/answer/9304353). +message Segment { + // The name for this segment. If unspecified, segments are named "Segment". + // This name defines string value returned by the `segment` dimension. The + // `segment` dimension prefixes segment names by the 1-based index number of + // the segment in the request (i.e. "1. Segment", "2. Segment", etc.). + string name = 1; + + // A segment is specified in one scope. + oneof one_segment_scope { + // User segments are subsets of users who engaged with your site or app. + UserSegment user_segment = 2; + + // Session segments are subsets of the sessions that occurred on your site + // or app. + SessionSegment session_segment = 3; + + // Event segments are subsets of events that were triggered on your site or + // app. + EventSegment event_segment = 4; + } +} + +// Expresses combinations of segment filters. +message SegmentFilterExpression { + // Specify one type of filter for `SegmentFilterExpression`. + oneof expr { + // The SegmentFilterExpression in `andGroup` have an AND relationship. + SegmentFilterExpressionList and_group = 1; + + // The SegmentFilterExpression in `orGroup` have an OR relationship. + SegmentFilterExpressionList or_group = 2; + + // The SegmentFilterExpression is NOT of `notExpression`. + SegmentFilterExpression not_expression = 3; + + // A primitive segment filter. + SegmentFilter segment_filter = 4; + + // Creates a filter that matches events of a single event name. If a + // parameter filter expression is specified, only the subset of events that + // match both the single event name and the parameter filter expressions + // match this event filter. + SegmentEventFilter segment_event_filter = 5; + } +} + +// A list of segment filter expressions. +message SegmentFilterExpressionList { + // The list of segment filter expressions + repeated SegmentFilterExpression expressions = 1; +} + +// An expression to filter dimension or metric values. +message SegmentFilter { + // The dimension name or metric name. + string field_name = 1; + + // Specify one type of filter for `Filter`. + oneof one_filter { + // Strings related filter. + StringFilter string_filter = 4; + + // A filter for in list values. + InListFilter in_list_filter = 5; + + // A filter for numeric or date values. + NumericFilter numeric_filter = 6; + + // A filter for between two values. + BetweenFilter between_filter = 7; + } + + // Specifies the scope for the filter. + SegmentFilterScoping filter_scoping = 8; +} + +// Scopings specify how the dimensions & metrics of multiple events +// should be considered when evaluating a segment filter. +message SegmentFilterScoping { + // If `atAnyPointInTime` is true, this filter evaluates to true for all + // events if it evaluates to true for any event in the date range of the + // request. + // + // This `atAnyPointInTime` parameter does not extend the date range of + // events in the report. If `atAnyPointInTime` is true, only events within + // the report's date range are considered when evaluating this filter. + // + // This `atAnyPointInTime` is only able to be specified if the criteria + // scoping is `ACROSS_ALL_SESSIONS` and is not able to be specified in + // sequences. + // + // If the criteria scoping is `ACROSS_ALL_SESSIONS`, `atAnyPointInTime` = + // false is used if unspecified. + optional bool at_any_point_in_time = 1; +} + +// Creates a filter that matches events of a single event name. If a parameter +// filter expression is specified, only the subset of events that match both the +// single event name and the parameter filter expressions match this event +// filter. +message SegmentEventFilter { + // This filter matches events of this single event name. Event name is + // required. + optional string event_name = 1; + + // If specified, this filter matches events that match both the single event + // name and the parameter filter expressions. + // + // Inside the parameter filter expression, only parameter filters are + // available. + optional SegmentParameterFilterExpression segment_parameter_filter_expression = 2; +} + +// Expresses combinations of segment filter on parameters. +message SegmentParameterFilterExpression { + // Specify one type of filter for `SegmentParameterFilterExpression`. + oneof expr { + // The SegmentParameterFilterExpression in `andGroup` have an AND + // relationship. + SegmentParameterFilterExpressionList and_group = 1; + + // The SegmentParameterFilterExpression in `orGroup` have an OR + // relationship. + SegmentParameterFilterExpressionList or_group = 2; + + // The SegmentParameterFilterExpression is NOT of `notExpression`. + SegmentParameterFilterExpression not_expression = 3; + + // A primitive segment parameter filter. + SegmentParameterFilter segment_parameter_filter = 4; + } +} + +// A list of segment parameter filter expressions. +message SegmentParameterFilterExpressionList { + // The list of segment parameter filter expressions. + repeated SegmentParameterFilterExpression expressions = 1; +} + +// An expression to filter parameter values in a segment. +message SegmentParameterFilter { + // The field that is being filtered. + oneof one_parameter { + // This filter will be evaluated on the specified event parameter. Event + // parameters are logged as parameters of the event. Event parameters + // include fields like "firebase_screen" & "currency". + // + // Event parameters can only be used in segments & funnels and can only be + // used in a descendent filter from an EventFilter. In a descendent filter + // from an EventFilter either event or item parameters should be used. + string event_parameter_name = 1; + + // This filter will be evaluated on the specified item parameter. Item + // parameters are logged as parameters in the item array. Item parameters + // include fields like "item_name" & "item_category". + // + // Item parameters can only be used in segments & funnels and can only be + // used in a descendent filter from an EventFilter. In a descendent filter + // from an EventFilter either event or item parameters should be used. + // + // Item parameters are only available in ecommerce events. To learn more + // about ecommerce events, see the [Measure ecommerce] + // (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce) + // guide. + string item_parameter_name = 2; + } + + // Specify one type of filter. + oneof one_filter { + // Strings related filter. + StringFilter string_filter = 4; + + // A filter for in list values. + InListFilter in_list_filter = 5; + + // A filter for numeric or date values. + NumericFilter numeric_filter = 6; + + // A filter for between two values. + BetweenFilter between_filter = 7; + } + + // Specifies the scope for the filter. + SegmentParameterFilterScoping filter_scoping = 8; +} + +// Scopings specify how multiple events should be considered when evaluating a +// segment parameter filter. +message SegmentParameterFilterScoping { + // Accumulates the parameter over the specified period of days before + // applying the filter. Only supported if criteria scoping is + // `ACROSS_ALL_SESSIONS` or `WITHIN_SAME_SESSION`. Only supported if the + // parameter is `event_count`. + // + // For example if `inAnyNDayPeriod` is 3, the event_name is "purchase", + // the event parameter is "event_count", and the Filter's criteria is + // greater than 5, this filter will accumulate the event count of purchase + // events over every 3 consecutive day period in the report's date range; a + // user will pass this Filter's criteria to be included in this segment if + // their count of purchase events exceeds 5 in any 3 consecutive day period. + // For example, the periods 2021-11-01 to 2021-11-03, 2021-11-02 to + // 2021-11-04, 2021-11-03 to 2021-11-05, and etc. will be considered. + // + // The date range is not extended for the purpose of having a full N day + // window near the start of the date range. For example if a report is for + // 2021-11-01 to 2021-11-10 and `inAnyNDayPeriod` = 3, the first two day + // period will be effectively shortened because no event data outside the + // report's date range will be read. For example, the first four periods + // will effectively be: 2021-11-01 to 2021-11-01, 2021-11-01 to 2021-11-02, + // 2021-11-01 to 2021-11-03, and 2021-11-02 to 2021-11-04. + // + // `inAnyNDayPeriod` is optional. If not specified, the + // `segmentParameterFilter` is applied to each event individually. + optional int64 in_any_n_day_period = 1; +} + +// Expresses combinations of funnel filters. +message FunnelFilterExpression { + // Specify one type of filter for `FunnelFilterExpression`. + oneof expr { + // The FunnelFilterExpression in `andGroup` have an AND relationship. + FunnelFilterExpressionList and_group = 1; + + // The FunnelFilterExpression in `orGroup` have an OR relationship. + FunnelFilterExpressionList or_group = 2; + + // The FunnelFilterExpression is NOT of `notExpression`. + FunnelFilterExpression not_expression = 3; + + // A primitive funnel filter. + FunnelFilter funnel_filter = 4; + + // Creates a filter that matches events of a single event name. If a + // parameter filter expression is specified, only the subset of events that + // match both the single event name and the parameter filter expressions + // match this event filter. + FunnelEventFilter funnel_event_filter = 5; + } +} + +// A list of funnel filter expressions. +message FunnelFilterExpressionList { + // The list of funnel filter expressions. + repeated FunnelFilterExpression expressions = 1; +} + +// An expression to filter dimension or metric values. +message FunnelFilter { + // The dimension name or metric name. + string field_name = 1; + + // Specify one type of filter. + oneof one_filter { + // Strings related filter. + StringFilter string_filter = 4; + + // A filter for in list values. + InListFilter in_list_filter = 5; + + // A filter for numeric or date values. + NumericFilter numeric_filter = 6; + + // A filter for between two values. + BetweenFilter between_filter = 7; + } +} + +// Creates a filter that matches events of a single event name. If a parameter +// filter expression is specified, only the subset of events that match both the +// single event name and the parameter filter expressions match this event +// filter. +message FunnelEventFilter { + // This filter matches events of this single event name. Event name is + // required. + optional string event_name = 1; + + // If specified, this filter matches events that match both the single event + // name and the parameter filter expressions. + // + // Inside the parameter filter expression, only parameter filters are + // available. + optional FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; +} + +// Expresses combinations of funnel filters on parameters. +message FunnelParameterFilterExpression { + // Specify one type of filter for `FunnelParameterFilterExpression`. + oneof expr { + // The FunnelParameterFilterExpression in `andGroup` have an AND + // relationship. + FunnelParameterFilterExpressionList and_group = 1; + + // The FunnelParameterFilterExpression in `orGroup` have an OR + // relationship. + FunnelParameterFilterExpressionList or_group = 2; + + // The FunnelParameterFilterExpression is NOT of `notExpression`. + FunnelParameterFilterExpression not_expression = 3; + + // A primitive funnel parameter filter. + FunnelParameterFilter funnel_parameter_filter = 4; + } +} + +// A list of funnel parameter filter expressions. +message FunnelParameterFilterExpressionList { + // The list of funnel parameter filter expressions. + repeated FunnelParameterFilterExpression expressions = 1; +} + +// An expression to filter parameter values in a funnel. +message FunnelParameterFilter { + // The field that is being filtered. + oneof one_parameter { + // This filter will be evaluated on the specified event parameter. Event + // parameters are logged as parameters of the event. Event parameters + // include fields like "firebase_screen" & "currency". + // + // Event parameters can only be used in segments & funnels and can only be + // used in a descendent filter from an EventFilter. In a descendent filter + // from an EventFilter either event or item parameters should be used. + string event_parameter_name = 1; + + // This filter will be evaluated on the specified item parameter. Item + // parameters are logged as parameters in the item array. Item parameters + // include fields like "item_name" & "item_category". + // + // Item parameters can only be used in segments & funnels and can only be + // used in a descendent filter from an EventFilter. In a descendent filter + // from an EventFilter either event or item parameters should be used. + // + // Item parameters are only available in ecommerce events. To learn more + // about ecommerce events, see the [Measure ecommerce] + // (https://developers.google.com/analytics/devguides/collection/ga4/ecommerce) + // guide. + string item_parameter_name = 2; + } + + // Specify one type of filter. + oneof one_filter { + // Strings related filter. + StringFilter string_filter = 4; + + // A filter for in list values. + InListFilter in_list_filter = 5; + + // A filter for numeric or date values. + NumericFilter numeric_filter = 6; + + // A filter for between two values. + BetweenFilter between_filter = 7; + } +} + +// The funnel report's response metadata carries additional information about +// the funnel report. +message FunnelResponseMetadata { + // If funnel report results are + // [sampled](https://support.google.com/analytics/answer/2637192), this + // describes what percentage of events were used in this funnel report. One + // `samplingMetadatas` is populated for each date range. Each + // `samplingMetadatas` corresponds to a date range in order that date ranges + // were specified in the request. + // + // However if the results are not sampled, this field will not be defined. + repeated SamplingMetadata sampling_metadatas = 1; +} + +// If funnel report results are +// [sampled](https://support.google.com/analytics/answer/2637192), this +// metadata describes what percentage of events were used in this funnel +// report for a date range. Sampling is the practice of analyzing a subset of +// all data in order to uncover the meaningful information in the larger data +// set. +message SamplingMetadata { + // The total number of events read in this sampled report for a date range. + // This is the size of the subset this property's data that was analyzed in + // this funnel report. + int64 samples_read_count = 1; + + // The total number of events present in this property's data that could + // have been analyzed in this funnel report for a date range. Sampling + // uncovers the meaningful information about the larger data set, and this + // is the size of the larger data set. + // + // To calculate the percentage of available data that was used in this + // funnel report, compute `samplesReadCount/samplingSpaceSize`. + int64 sampling_space_size = 2; +} + +// A metric's value type. +enum MetricType { + // Unspecified type. + METRIC_TYPE_UNSPECIFIED = 0; + + // Integer type. + TYPE_INTEGER = 1; + + // Floating point type. + TYPE_FLOAT = 2; + + // A duration of seconds; a special floating point type. + TYPE_SECONDS = 4; + + // A duration in milliseconds; a special floating point type. + TYPE_MILLISECONDS = 5; + + // A duration in minutes; a special floating point type. + TYPE_MINUTES = 6; + + // A duration in hours; a special floating point type. + TYPE_HOURS = 7; + + // A custom metric of standard type; a special floating point type. + TYPE_STANDARD = 8; + + // An amount of money; a special floating point type. + TYPE_CURRENCY = 9; + + // A length in feet; a special floating point type. + TYPE_FEET = 10; + + // A length in miles; a special floating point type. + TYPE_MILES = 11; + + // A length in meters; a special floating point type. + TYPE_METERS = 12; + + // A length in kilometers; a special floating point type. + TYPE_KILOMETERS = 13; +} diff --git a/versions.txt b/versions.txt index 99fc3526..9d8530da 100644 --- a/versions.txt +++ b/versions.txt @@ -4,3 +4,5 @@ google-analytics-data:0.11.10:0.11.10 grpc-google-analytics-data-v1beta:0.11.10:0.11.10 proto-google-analytics-data-v1beta:0.11.10:0.11.10 +proto-google-analytics-data-v1alpha:0.11.10:0.11.10 +grpc-google-analytics-data-v1alpha:0.11.10:0.11.10 From 9dbe3e30f84dcf143a66b68a68ca95d50c4699c5 Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 09:48:33 -0400 Subject: [PATCH 10/21] samples: add Java samples for date ranges (#470) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Fixes linting * Fixes linting violations * Style changes on comment * Makes review based changes to comments * Adds a comment explaining print method * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 2 + .../RunReportWithDateRangesSample.java | 76 ++++++++++++++++ .../RunReportWithNamedDateRangesSample.java | 88 +++++++++++++++++++ .../RunReportWithDateRangesSampleTest.java | 54 ++++++++++++ .../RunReportWithNamedDateRangesTest.java | 54 ++++++++++++ 5 files changed, 274 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithDateRangesSampleTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithNamedDateRangesTest.java diff --git a/README.md b/README.md index 93d148ce..2449af8f 100644 --- a/README.md +++ b/README.md @@ -84,6 +84,8 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Run Report Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportSample.java) | | Run Report With Aggregations Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | | Run Report With Cohorts Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | +| Run Report With Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | +| Run Report With Named Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java new file mode 100644 index 00000000..42459294 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java @@ -0,0 +1,76 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of +date ranges in a report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.date_ranges +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithDateRangesSample" + */ + +// [START analyticsdata_run_report_with_date_ranges] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithDateRangesSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithDateRanges(propertyId); + } + + // Runs a report using two date ranges. + static void sampleRunReportWithDateRanges(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDateRanges( + DateRange.newBuilder().setStartDate("2019-08-01").setEndDate("2019-08-14")) + .addDateRanges( + DateRange.newBuilder().setStartDate("2020-08-01").setEndDate("2020-08-14")) + .addDimensions(Dimension.newBuilder().setName("platform")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_date_ranges] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java new file mode 100644 index 00000000..9bdcce18 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java @@ -0,0 +1,88 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the creation +of a basic report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithNamedDateRangesSample" + */ + +// [START analyticsdata_run_report_with_named_date_ranges] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithNamedDateRangesSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithNamedDateRanges(propertyId); + } + + // Runs a report using named date ranges. + static void sampleRunReportWithNamedDateRanges(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + + DateRange yearAgo = + DateRange.newBuilder() + .setStartDate("2020-01-01") + .setEndDate("2020-01-31") + .setName("year_ago") + .build(); + DateRange currentYear = + DateRange.newBuilder() + .setStartDate("2021-01-01") + .setEndDate("2021-01-31") + .setName("current_year") + .build(); + + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDateRanges(yearAgo) + .addDateRanges(currentYear) + .addDimensions(Dimension.newBuilder().setName("country")) + .addMetrics(Metric.newBuilder().setName("sessions")) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_named_date_ranges] diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithDateRangesSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDateRangesSampleTest.java new file mode 100644 index 00000000..bfb69a20 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDateRangesSampleTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithDateRanges sample. */ +@RunWith(JUnit4.class) +public class RunReportWithDateRangesSampleTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithDateRangesSample.sampleRunReportWithDateRanges(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithDateRanges() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithNamedDateRangesTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithNamedDateRangesTest.java new file mode 100644 index 00000000..5a37e3a5 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithNamedDateRangesTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithNamedDateRanges sample. */ +@RunWith(JUnit4.class) +public class RunReportWithNamedDateRangesTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithNamedDateRangesSample.sampleRunReportWithNamedDateRanges(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithNamedDateRanges() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} From c325846927723a0b8c35c3e4f7c197cf92e335fb Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 10:17:50 -0400 Subject: [PATCH 11/21] samples: add Java samples for ordering, pagination, property quota (#471) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Adds 3 java samples * Fixes linting * Fixes linting violations * Style change on comment * Modifies comment describing client creation * Changes to comments on samples * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 3 + .../RunReportWithOrderingSample.java | 80 +++++++++++++ .../RunReportWithPaginationSample.java | 105 ++++++++++++++++++ .../RunReportWithPropertyQuotaSample.java | 96 ++++++++++++++++ .../analytics/RunReportWithOrderingTest.java | 54 +++++++++ .../RunReportWithPaginationTest.java | 54 +++++++++ .../RunReportWithPropertyQuotaTest.java | 54 +++++++++ 7 files changed, 446 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithPropertyQuotaSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithOrderingTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithPaginationTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithPropertyQuotaTest.java diff --git a/README.md b/README.md index 2449af8f..6b48dc7e 100644 --- a/README.md +++ b/README.md @@ -86,6 +86,9 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Run Report With Cohorts Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | | Run Report With Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | | Run Report With Named Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | +| Run Report With Ordering Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java) | +| Run Report With Pagination Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java) | +| Run Report With Property Quota Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithPropertyQuotaSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithPropertyQuotaSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java new file mode 100644 index 00000000..d1ec79c9 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java @@ -0,0 +1,80 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the ordering of report rows. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.order_bys +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithOrderingSample" + */ + +// [START analyticsdata_run_report_with_ordering] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.OrderBy; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithOrderingSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithOrdering(propertyId); + } + + // Runs a report of active users grouped by three dimensions, ordered by the total revenue in + // descending order. + static void sampleRunReportWithOrdering(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("date")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addMetrics(Metric.newBuilder().setName("newUsers")) + .addMetrics(Metric.newBuilder().setName("totalRevenue")) + .addDateRanges(DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("today")) + .addOrderBys( + OrderBy.newBuilder() + .setMetric(OrderBy.MetricOrderBy.newBuilder().setMetricName("totalRevenue")) + .setDesc(true)) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_ordering] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java new file mode 100644 index 00000000..3bd59726 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java @@ -0,0 +1,105 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the use of pagination to retrieve +large result sets. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.offset +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithPaginationSample" + */ + +// [START analyticsdata_run_report_with_pagination] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithPaginationSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithPagination(propertyId); + } + + // Runs a report several times, each time retrieving a portion of result using pagination. + static void sampleRunReportWithPagination(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + // [START analyticsdata_run_report_with_pagination_page1] + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDateRanges( + DateRange.newBuilder().setStartDate("365daysAgo").setEndDate("yesterday")) + .addDimensions(Dimension.newBuilder().setName("firstUserSource")) + .addDimensions(Dimension.newBuilder().setName("firstUserMedium")) + .addDimensions(Dimension.newBuilder().setName("firstUserCampaignName")) + .addMetrics(Metric.newBuilder().setName("sessions")) + .addMetrics(Metric.newBuilder().setName("conversions")) + .addMetrics(Metric.newBuilder().setName("totalRevenue")) + .setLimit(100000) + .setOffset(0) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + RunReportSample.printRunResponseResponse(response); + // [END analyticsdata_run_report_with_pagination_page1] + + // Run the same report with a different offset value to retrieve the second page of a + // response. + // [START analyticsdata_run_report_with_pagination_page2] + request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDateRanges( + DateRange.newBuilder().setStartDate("365daysAgo").setEndDate("yesterday")) + .addDimensions(Dimension.newBuilder().setName("firstUserSource")) + .addDimensions(Dimension.newBuilder().setName("firstUserMedium")) + .addDimensions(Dimension.newBuilder().setName("firstUserCampaignName")) + .addMetrics(Metric.newBuilder().setName("sessions")) + .addMetrics(Metric.newBuilder().setName("conversions")) + .addMetrics(Metric.newBuilder().setName("totalRevenue")) + .setLimit(100000) + .setOffset(100000) + .build(); + + // Make the request. + response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + // [END analyticsdata_run_report_with_pagination_page2] + } + } +} +// [END analyticsdata_run_report_with_pagination] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithPropertyQuotaSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithPropertyQuotaSample.java new file mode 100644 index 00000000..03d7f3d2 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithPropertyQuotaSample.java @@ -0,0 +1,96 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of property quota metadata. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.return_property_quota +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithPropertyQuotaSample" + */ + +// [START analyticsdata_run_report_with_property_quota] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithPropertyQuotaSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithPropertyQuota(propertyId); + } + + // Runs a report and prints property quota information. + static void sampleRunReportWithPropertyQuota(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .setReturnPropertyQuota(true) + .addDimensions(Dimension.newBuilder().setName("country")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addDateRanges(DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("today")) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + + // [START analyticsdata_run_report_with_property_quota_print_response] + if (response.hasPropertyQuota()) { + System.out.printf( + "Tokens per day quota consumed: %d, remaining: %d.%n", + response.getPropertyQuota().getTokensPerDay().getConsumed(), + response.getPropertyQuota().getTokensPerDay().getRemaining()); + System.out.printf( + "Tokens per hour quota consumed: %d, remaining: %d.%n", + response.getPropertyQuota().getTokensPerHour().getConsumed(), + response.getPropertyQuota().getTokensPerHour().getRemaining()); + System.out.printf( + "Concurrent requests quota consumed: %d, remaining: %d.%n", + response.getPropertyQuota().getConcurrentRequests().getConsumed(), + response.getPropertyQuota().getConcurrentRequests().getRemaining()); + System.out.printf( + "Server errors per project per hour quota consumed: %d, remaining: %d.%n", + response.getPropertyQuota().getServerErrorsPerProjectPerHour().getConsumed(), + response.getPropertyQuota().getServerErrorsPerProjectPerHour().getRemaining()); + System.out.printf( + "Potentially thresholded requests per hour quota consumed: %d, remaining: %d.%n", + response.getPropertyQuota().getPotentiallyThresholdedRequestsPerHour().getConsumed(), + response.getPropertyQuota().getPotentiallyThresholdedRequestsPerHour().getRemaining()); + } + // [END analyticsdata_run_report_with_property_quota_print_response] + } + } +} +// [END analyticsdata_run_report_with_property_quota] diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithOrderingTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithOrderingTest.java new file mode 100644 index 00000000..c64eb210 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithOrderingTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithOrdering sample. */ +@RunWith(JUnit4.class) +public class RunReportWithOrderingTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithOrderingSample.sampleRunReportWithOrdering(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithOrdering() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithPaginationTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithPaginationTest.java new file mode 100644 index 00000000..7202313a --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithPaginationTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithPagination sample. */ +@RunWith(JUnit4.class) +public class RunReportWithPaginationTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithPaginationSample.sampleRunReportWithPagination(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithPagination() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithPropertyQuotaTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithPropertyQuotaTest.java new file mode 100644 index 00000000..55e71287 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithPropertyQuotaTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithPropertyQuota sample. */ +@RunWith(JUnit4.class) +public class RunReportWithPropertyQuotaTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithPropertyQuotaSample.sampleRunReportWithPropertyQuota(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithPropertyQuota() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Tokens per day quota consumed"); + } +} From 47ce0e206372226faa6a46cd4c46e2ba8ec74d79 Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 13:00:38 -0400 Subject: [PATCH 12/21] samples: add Java samples for dimension in list filter and multiple dimension filters (#473) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Fixes linting * Fixes linting violations * Adds java samples with multiple metrics/dimensions * Fixes lines in README * Adds Java samples for dimension filters * Style changes on comment * Comment changes in samples * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 2 + ...ReportWithDimensionInListFilterSample.java | 97 +++++++++++++++++ ...ortWithMultipleDimensionFiltersSample.java | 101 ++++++++++++++++++ ...unReportWithDimensionInListFilterTest.java | 55 ++++++++++ ...eportWithMultipleDimensionFiltersTest.java | 55 ++++++++++ 5 files changed, 310 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionInListFilterTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionFiltersTest.java diff --git a/README.md b/README.md index 6b48dc7e..adfc60f5 100644 --- a/README.md +++ b/README.md @@ -85,6 +85,8 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Run Report With Aggregations Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | | Run Report With Cohorts Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | | Run Report With Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | +| Run Report With Dimension In List Filter Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java) | +| Run Report With Multiple Dimension Filters Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java) | | Run Report With Named Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | | Run Report With Ordering Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java) | | Run Report With Pagination Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java new file mode 100644 index 00000000..2d97e12a --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java @@ -0,0 +1,97 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of +dimension and metric filters in a report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.dimension_filter +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithDimensionInListFilterSample" + */ + +// [START analyticsdata_run_report_with_dimension_in_list_filter] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Filter; +import com.google.analytics.data.v1beta.FilterExpression; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; +import java.util.ArrayList; + +public class RunReportWithDimensionInListFilterSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithDimensionInListFilter(propertyId); + } + + // Runs a report using a dimension filter with `in_list_filter` expression. The filter selects for + // when `eventName` is set to one of three event names specified in the query. + // This sample uses relative date range values. + // See https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/DateRange + // for more information. + static void sampleRunReportWithDimensionInListFilter(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("eventName")) + .addMetrics(Metric.newBuilder().setName("sessions")) + .addDateRanges( + DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("yesterday")) + .setDimensionFilter( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("eventName") + .setInListFilter( + Filter.InListFilter.newBuilder() + .addAllValues( + new ArrayList() { + { + add("purchase"); + add("in_app_purchase"); + add("app_store_subscription_renew"); + } + }) + .build()))) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_dimension_in_list_filter] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java new file mode 100644 index 00000000..65e969bf --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java @@ -0,0 +1,101 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of +dimension and metric filters in a report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.dimension_filter +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithMultipleDimensionFiltersSample" + */ + +// [START analyticsdata_run_report_with_multiple_dimension_filters] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Filter; +import com.google.analytics.data.v1beta.FilterExpression; +import com.google.analytics.data.v1beta.FilterExpressionList; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithMultipleDimensionFiltersSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithMultipleDimensionFilters(propertyId); + } + + // Runs a report using multiple dimension filters joined as `and_group` expression. The filter + // selects for when both `browser` is `Chrome` and `countryId` is `US`. + // This sample uses relative date range values. + // See https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/DateRange + // for more information. + static void sampleRunReportWithMultipleDimensionFilters(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("browser")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addDateRanges( + DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("yesterday")) + .setDimensionFilter( + FilterExpression.newBuilder() + .setAndGroup( + FilterExpressionList.newBuilder() + .addExpressions( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("browser") + .setStringFilter( + Filter.StringFilter.newBuilder() + .setValue("Chrome")))) + .addExpressions( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("countryId") + .setStringFilter( + Filter.StringFilter.newBuilder() + .setValue("US")))))) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_multiple_dimension_filters] diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionInListFilterTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionInListFilterTest.java new file mode 100644 index 00000000..84d64aec --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionInListFilterTest.java @@ -0,0 +1,55 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithDimensionInListFilter sample. */ +@RunWith(JUnit4.class) +public class RunReportWithDimensionInListFilterTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithDimensionInListFilterSample.sampleRunReportWithDimensionInListFilter( + ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithDimensionInListFilter() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionFiltersTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionFiltersTest.java new file mode 100644 index 00000000..3f3e55b3 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionFiltersTest.java @@ -0,0 +1,55 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithMultipleDimensionFilters sample. */ +@RunWith(JUnit4.class) +public class RunReportWithMultipleDimensionFiltersTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithMultipleDimensionFiltersSample.sampleRunReportWithMultipleDimensionFilters( + ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithMultipleDimensionFilters() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} From 69e2d967f9442194e471307d5f114f7ac0340f80 Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 13:16:31 -0400 Subject: [PATCH 13/21] samples: add Java samples for to dimension filters (#474) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Fixes linting * Fixes linting violations * Adds java samples with multiple metrics/dimensions * Fixes lines in README * Adds Java samples for dimension filters * Adds java samples related to dimension filters * Style changes on comment * Comment changes to samples * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 3 + ...rtWithDimensionAndMetricFiltersSample.java | 112 ++++++++++++++++++ ...eportWithDimensionExcludeFilterSample.java | 90 ++++++++++++++ .../RunReportWithDimensionFilterSample.java | 87 ++++++++++++++ ...thDimensionAndMetricFiltersSampleTest.java | 55 +++++++++ ...tWithDimensionExcludeFilterSampleTest.java | 55 +++++++++ .../RunReportWithDimensionFilterTest.java | 54 +++++++++ 7 files changed, 456 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionExcludeFilterSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSampleTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionExcludeFilterSampleTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionFilterTest.java diff --git a/README.md b/README.md index adfc60f5..4c38ad07 100644 --- a/README.md +++ b/README.md @@ -85,6 +85,9 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Run Report With Aggregations Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | | Run Report With Cohorts Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | | Run Report With Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDateRangesSample.java) | +| Run Report With Dimension And Metric Filters Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSample.java) | +| Run Report With Dimension Exclude Filter Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionExcludeFilterSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionExcludeFilterSample.java) | +| Run Report With Dimension Filter Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java) | | Run Report With Dimension In List Filter Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java) | | Run Report With Multiple Dimension Filters Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java) | | Run Report With Named Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSample.java new file mode 100644 index 00000000..76cdb45e --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSample.java @@ -0,0 +1,112 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of +dimension and metric filters in a report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.dimension_filter +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithDimensionAndMetricFiltersSample" + */ + +// [START analyticsdata_run_report_with_dimension_and_metric_filters] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Filter; +import com.google.analytics.data.v1beta.FilterExpression; +import com.google.analytics.data.v1beta.FilterExpressionList; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.NumericValue; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithDimensionAndMetricFiltersSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithDimensionAndMetricFilters(propertyId); + } + + // Runs a report using both metric and dimension filters. A dimension filter limits the report to + // include only users who made an in-app purchase using Android platform. A metric filter + // specifies that only users with session counts larger than 1,000 should be included. + static void sampleRunReportWithDimensionAndMetricFilters(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("city")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addDateRanges(DateRange.newBuilder().setStartDate("2020-03-31").setEndDate("today")) + .setDimensionFilter( + FilterExpression.newBuilder() + .setAndGroup( + FilterExpressionList.newBuilder() + .addExpressions( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("platform") + .setStringFilter( + Filter.StringFilter.newBuilder() + .setMatchType( + Filter.StringFilter.MatchType.EXACT) + .setValue("Android")))) + .addExpressions( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("eventName") + .setStringFilter( + Filter.StringFilter.newBuilder() + .setMatchType( + Filter.StringFilter.MatchType.EXACT) + .setValue("in_app_purchase")))))) + .setMetricFilter( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("sessions") + .setNumericFilter( + Filter.NumericFilter.newBuilder() + .setOperation(Filter.NumericFilter.Operation.GREATER_THAN) + .setValue(NumericValue.newBuilder().setInt64Value(1000))))) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_dimension_and_metric_filters] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionExcludeFilterSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionExcludeFilterSample.java new file mode 100644 index 00000000..89999e60 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionExcludeFilterSample.java @@ -0,0 +1,90 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of +dimension and metric filters in a report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.dimension_filter +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithDimensionExcludeFilterSample" + */ + +// [START analyticsdata_run_report_with_dimension_exclude_filter] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Filter; +import com.google.analytics.data.v1beta.FilterExpression; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithDimensionExcludeFilterSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithDimensionExcludeFilter(propertyId); + } + + // Runs a report using a filter with `not_expression`. The dimension filter selects for when + // `pageTitle` is not `My Homepage`. + // This sample uses relative date range values. + // See https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/DateRange + // for more information. + static void sampleRunReportWithDimensionExcludeFilter(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("pageTitle")) + .addMetrics(Metric.newBuilder().setName("sessions")) + .addDateRanges( + DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("yesterday")) + .setDimensionFilter( + FilterExpression.newBuilder() + .setNotExpression( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("pageTitle") + .setStringFilter( + Filter.StringFilter.newBuilder() + .setValue("My Homepage"))))) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_dimension_exclude_filter] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java new file mode 100644 index 00000000..2e2ae79c --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java @@ -0,0 +1,87 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the usage of +dimension and metric filters in a report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport#body.request_body.FIELDS.dimension_filter +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithDimensionFilterSample" + */ + +// [START analyticsdata_run_report_with_dimension_filter] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Filter; +import com.google.analytics.data.v1beta.FilterExpression; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithDimensionFilterSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithDimensionFilter(propertyId); + } + + // Runs a report using a dimension filter. The call returns a time series report of `eventCount` + // when `eventName` is `first_open` for each date. + // This sample uses relative date range values. + // See https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/DateRange + // for more information. + static void sampleRunReportWithDimensionFilter(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("date")) + .addMetrics(Metric.newBuilder().setName("eventCount")) + .addDateRanges( + DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("yesterday")) + .setDimensionFilter( + FilterExpression.newBuilder() + .setFilter( + Filter.newBuilder() + .setFieldName("eventName") + .setStringFilter( + Filter.StringFilter.newBuilder().setValue("first_open")))) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_dimension_filter] diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSampleTest.java new file mode 100644 index 00000000..afe83cfb --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionAndMetricFiltersSampleTest.java @@ -0,0 +1,55 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithDimensionAndMetricFilters sample. */ +@RunWith(JUnit4.class) +public class RunReportWithDimensionAndMetricFiltersSampleTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithDimensionAndMetricFiltersSample.sampleRunReportWithDimensionAndMetricFilters( + ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportDimensionAndMetricFilters() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionExcludeFilterSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionExcludeFilterSampleTest.java new file mode 100644 index 00000000..9ee6dacf --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionExcludeFilterSampleTest.java @@ -0,0 +1,55 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithDimensionExcludeFilter sample. */ +@RunWith(JUnit4.class) +public class RunReportWithDimensionExcludeFilterSampleTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithDimensionExcludeFilterSample.sampleRunReportWithDimensionExcludeFilter( + ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithDimensionExcludeFilter() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionFilterTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionFilterTest.java new file mode 100644 index 00000000..c8fb2ad3 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithDimensionFilterTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithDimensionFilter sample. */ +@RunWith(JUnit4.class) +public class RunReportWithDimensionFilterTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithDimensionFilterSample.sampleRunReportWithDimensionFilter(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithDimensionFilter() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} From 83b6bc2ea3ce2014090721df1322eedcf1a7062d Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 13:31:37 -0400 Subject: [PATCH 14/21] samples: add Java samples with multiple dimensions/metrics (#472) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Fixes linting * Fixes linting violations * Adds java samples with multiple metrics/dimensions * Fixes lines in README * Style changes on comment * Comment changes on samples * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 2 + ...RunReportWithMultipleDimensionsSample.java | 75 +++++++++++++++++++ .../RunReportWithMultipleMetricsSample.java | 75 +++++++++++++++++++ .../RunReportWithMultipleDimensionsTest.java | 54 +++++++++++++ .../RunReportWithMultipleMetricsTest.java | 54 +++++++++++++ 5 files changed, 260 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionsSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleMetricsSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionsTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleMetricsTest.java diff --git a/README.md b/README.md index 4c38ad07..e8c28bac 100644 --- a/README.md +++ b/README.md @@ -90,6 +90,8 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Run Report With Dimension Filter Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionFilterSample.java) | | Run Report With Dimension In List Filter Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithDimensionInListFilterSample.java) | | Run Report With Multiple Dimension Filters Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionFiltersSample.java) | +| Run Report With Multiple Dimensions Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionsSample.java) | +| Run Report With Multiple Metrics Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleMetricsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleMetricsSample.java) | | Run Report With Named Date Ranges Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithNamedDateRangesSample.java) | | Run Report With Ordering Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithOrderingSample.java) | | Run Report With Pagination Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithPaginationSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionsSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionsSample.java new file mode 100644 index 00000000..506bd55b --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleDimensionsSample.java @@ -0,0 +1,75 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the creation +of a basic report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithMultipleDimensionsSample" + */ + +// [START analyticsdata_run_report_with_multiple_dimensions] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithMultipleDimensionsSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithMultipleDimensions(propertyId); + } + + // Runs a report of active users grouped by three dimensions. + static void sampleRunReportWithMultipleDimensions(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("country")) + .addDimensions(Dimension.newBuilder().setName("region")) + .addDimensions(Dimension.newBuilder().setName("city")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addDateRanges(DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("today")) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_multiple_dimensions] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleMetricsSample.java b/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleMetricsSample.java new file mode 100644 index 00000000..20c8c6be --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunReportWithMultipleMetricsSample.java @@ -0,0 +1,75 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the creation +of a basic report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runReport +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunReportWithMultipleMetricsSample" + */ + +// [START analyticsdata_run_report_with_multiple_metrics] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunReportWithMultipleMetricsSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunReportWithMultipleMetrics(propertyId); + } + + // Runs a report of active users, new users and total revenue grouped by date dimension. + static void sampleRunReportWithMultipleMetrics(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunReportRequest request = + RunReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDimensions(Dimension.newBuilder().setName("date")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addMetrics(Metric.newBuilder().setName("newUsers")) + .addMetrics(Metric.newBuilder().setName("totalRevenue")) + .addDateRanges(DateRange.newBuilder().setStartDate("7daysAgo").setEndDate("today")) + .build(); + + // Make the request. + RunReportResponse response = analyticsData.runReport(request); + // Prints the response using a method in RunReportSample.java + RunReportSample.printRunResponseResponse(response); + } + } +} +// [END analyticsdata_run_report_with_multiple_metrics] diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionsTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionsTest.java new file mode 100644 index 00000000..84784104 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleDimensionsTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithMultipleDimensions sample. */ +@RunWith(JUnit4.class) +public class RunReportWithMultipleDimensionsTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithMultipleDimensionsSample.sampleRunReportWithMultipleDimensions(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithMultipleDimensions() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleMetricsTest.java b/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleMetricsTest.java new file mode 100644 index 00000000..b2da9c39 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunReportWithMultipleMetricsTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunReportWithMultipleMetrics sample. */ +@RunWith(JUnit4.class) +public class RunReportWithMultipleMetricsTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunReportWithMultipleMetricsSample.sampleRunReportWithMultipleMetrics(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunReportWithMultipleMetrics() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} From 7339374f298ba5089473bd1bca1851c5faa4d8e3 Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 13:44:30 -0400 Subject: [PATCH 15/21] samples: add Java samples for metadata (#476) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Fixes linting * Fixes linting violations * Adds java samples with multiple metrics/dimensions * Fixes lines in README * Adds Java samples for dimension filters * Adds java samples related to dimension filters * Adds Java samples for RunRealtimeReport * Add Java samples for metadata * Fixes linting error with mismatched filename * Style changes on comment * Changes comments * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 2 + .../analytics/GetCommonMetadataSample.java | 96 +++++++++++++++++++ .../GetMetadataByPropertyIdSample.java | 67 +++++++++++++ .../GetCommonMetadataSampleTest.java | 51 ++++++++++ .../GetMetadataByPropertyIdSampleTest.java | 54 +++++++++++ 5 files changed, 270 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/GetCommonMetadataSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/GetCommonMetadataSampleTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/GetMetadataByPropertyIdSampleTest.java diff --git a/README.md b/README.md index e8c28bac..cea912b4 100644 --- a/README.md +++ b/README.md @@ -79,6 +79,8 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Sample | Source Code | Try it | | --------------------------- | --------------------------------- | ------ | +| Get Common Metadata Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/GetCommonMetadataSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/GetCommonMetadataSample.java) | +| Get Metadata By Property Id Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java) | | Quickstart Json Credentials Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/QuickstartJsonCredentialsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/QuickstartJsonCredentialsSample.java) | | Quickstart Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/QuickstartSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/QuickstartSample.java) | | Run Report Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/GetCommonMetadataSample.java b/samples/snippets/src/main/java/com/example/analytics/GetCommonMetadataSample.java new file mode 100644 index 00000000..5f57cc2d --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/GetCommonMetadataSample.java @@ -0,0 +1,96 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application retrieving dimension and metrics +metadata. + +See https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/getMetadata +for more information. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.GetCommonMetadataSample" + */ + +// [START analyticsdata_get_common_metadata] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DimensionMetadata; +import com.google.analytics.data.v1beta.GetMetadataRequest; +import com.google.analytics.data.v1beta.Metadata; +import com.google.analytics.data.v1beta.MetricMetadata; + +public class GetCommonMetadataSample { + + public static void main(String... args) throws Exception { + // Runs the sample. + sampleGetCommonMetadata(); + } + + // Retrieves dimensions and metrics available for all Google Analytics 4 properties. + static void sampleGetCommonMetadata() throws Exception { + // Set the Property ID to 0 for dimensions and metrics common to all properties. In this special + // mode, this method will not return custom dimensions and metrics. + String propertyId = "0"; + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + GetMetadataRequest request = + GetMetadataRequest.newBuilder().setName("properties/" + propertyId + "/metadata").build(); + + // Make the request. + Metadata response = analyticsData.getMetadata(request); + + System.out.println("Dimensions and metrics available for all Google Analytics 4 properties:"); + printGetMetadataResponse(response); + } + } + + // Prints results of the getMetadata call. + static void printGetMetadataResponse(Metadata response) { + // [START analyticsdata_print_get_metadata_response] + for (DimensionMetadata dimension : response.getDimensionsList()) { + System.out.println("DIMENSION"); + System.out.printf( + "%s (%s): %s%n", + dimension.getApiName(), dimension.getUiName(), dimension.getDescription()); + System.out.printf("custom definition: %s%n", dimension.getCustomDefinition()); + if (dimension.getDeprecatedApiNamesList() != null + && !dimension.getDeprecatedApiNamesList().isEmpty()) { + System.out.printf("Deprecated API names: %s%n", dimension.getDeprecatedApiNamesList()); + } + System.out.println(); + } + for (MetricMetadata metric : response.getMetricsList()) { + System.out.println("METRIC"); + System.out.printf( + "%s (%s): %s%n", metric.getApiName(), metric.getUiName(), metric.getDescription()); + System.out.printf("custom definition: %s%n", metric.getCustomDefinition()); + System.out.printf("Type: %s%n", metric.getType()); + if (metric.getDeprecatedApiNamesList() != null + && !metric.getDeprecatedApiNamesList().isEmpty()) { + System.out.printf("Deprecated API names: %s%n", metric.getDeprecatedApiNamesList()); + } + System.out.println(); + } + // [END analyticsdata_print_get_metadata_response] + } +} +// [END analyticsdata_get_common_metadata] diff --git a/samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java b/samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java new file mode 100644 index 00000000..f9be5f8d --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java @@ -0,0 +1,67 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application retrieving dimension and metrics +metadata. + +See https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/getMetadata +for more information. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.GetMetadataByPropertyIdSample" + */ + +// [START analyticsdata_get_metadata_by_property_id] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.GetMetadataRequest; +import com.google.analytics.data.v1beta.Metadata; + +public class GetMetadataByPropertyIdSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleGetMetadataByPropertyId(propertyId); + } + + // Retrieves dimensions and metrics available for a Google Analytics 4 property, including custom + // fields. + static void sampleGetMetadataByPropertyId(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + GetMetadataRequest request = + GetMetadataRequest.newBuilder().setName("properties/" + propertyId + "/metadata").build(); + + // Make the request. + Metadata response = analyticsData.getMetadata(request); + + System.out.printf( + "Dimensions and metrics available for Google Analytics 4 property %s " + + "(including custom fields):", + propertyId); + // Prints the response using a method in GetCommonMetadataSample.java + GetCommonMetadataSample.printGetMetadataResponse(response); + } + } +} +// [END analyticsdata_get_metadata_by_property_id] diff --git a/samples/snippets/src/test/java/com/example/analytics/GetCommonMetadataSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/GetCommonMetadataSampleTest.java new file mode 100644 index 00000000..5acd05b6 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/GetCommonMetadataSampleTest.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the GetCommonMetadata sample. */ +@RunWith(JUnit4.class) +public class GetCommonMetadataSampleTest { + + private String runSample() throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + GetCommonMetadataSample.sampleGetCommonMetadata(); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testGetCommonMetadata() throws Exception { + // Act + String out = runSample(); + + // Assert + assertThat(out).contains("Dimensions and metrics"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/GetMetadataByPropertyIdSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/GetMetadataByPropertyIdSampleTest.java new file mode 100644 index 00000000..fb19f524 --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/GetMetadataByPropertyIdSampleTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the GetMetadataByPropertyId sample. */ +@RunWith(JUnit4.class) +public class GetMetadataByPropertyIdSampleTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + GetMetadataByPropertyIdSample.sampleGetMetadataByPropertyId(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testGetMetadataByPropertyId() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Dimensions and metrics"); + } +} From fd8247dc99532d4ad0eaf2cf75a9610f054a0eff Mon Sep 17 00:00:00 2001 From: Anwesha Date: Tue, 17 May 2022 13:57:41 -0400 Subject: [PATCH 16/21] samples: add Java samples for batch and pivot reports (#477) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * A copy sample to test fork process * Adds sample RunReportSample * Modifies runReport sample to have headers printed * Addresses comment differences inbetween python and java sample * Changes println to printf for consistency * Test for run report * Fixes a matching tag * Fixes checkstyle violation * -Another commit to fix checkstyle violations * Changes to linting * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Adds samples related to date ranges for java * Removes spaces in readme * Fixes spacing * Fixes linting * Fixes linting violations * Adds java samples with multiple metrics/dimensions * Fixes lines in README * Adds Java samples for dimension filters * Adds java samples related to dimension filters * Adds Java samples for RunRealtimeReport * Add Java samples for metadata * Add Java samples for batch and pivot reports * Adds updated files * Style changes on comment * Changes comments * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot Co-authored-by: ikuleshov --- README.md | 2 + .../analytics/RunBatchReportSample.java | 95 +++++++++++++++ .../analytics/RunPivotReportSample.java | 114 ++++++++++++++++++ .../analytics/RunBatchReportSampleTest.java | 54 +++++++++ .../analytics/RunPivotReportSampleTest.java | 54 +++++++++ 5 files changed, 319 insertions(+) create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunBatchReportSample.java create mode 100644 samples/snippets/src/main/java/com/example/analytics/RunPivotReportSample.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunBatchReportSampleTest.java create mode 100644 samples/snippets/src/test/java/com/example/analytics/RunPivotReportSampleTest.java diff --git a/README.md b/README.md index cea912b4..5b3b0674 100644 --- a/README.md +++ b/README.md @@ -83,6 +83,8 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-analytics-dat | Get Metadata By Property Id Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/GetMetadataByPropertyIdSample.java) | | Quickstart Json Credentials Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/QuickstartJsonCredentialsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/QuickstartJsonCredentialsSample.java) | | Quickstart Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/QuickstartSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/QuickstartSample.java) | +| Run Batch Report Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunBatchReportSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunBatchReportSample.java) | +| Run Pivot Report Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunPivotReportSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunPivotReportSample.java) | | Run Report Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportSample.java) | | Run Report With Aggregations Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithAggregationsSample.java) | | Run Report With Cohorts Sample | [source code](https://github.com/googleapis/java-analytics-data/blob/main/samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-analytics-data&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/analytics/RunReportWithCohortsSample.java) | diff --git a/samples/snippets/src/main/java/com/example/analytics/RunBatchReportSample.java b/samples/snippets/src/main/java/com/example/analytics/RunBatchReportSample.java new file mode 100644 index 00000000..273ebf0a --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunBatchReportSample.java @@ -0,0 +1,95 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the batch creation +of multiple reports. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/batchRunReports +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunBatchReportSample" + */ + +// [START analyticsdata_run_batch_report] + +import com.google.analytics.data.v1beta.BatchRunReportsRequest; +import com.google.analytics.data.v1beta.BatchRunReportsResponse; +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.RunReportRequest; +import com.google.analytics.data.v1beta.RunReportResponse; + +public class RunBatchReportSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunBatchReport(propertyId); + } + + // Runs a batch report on a Google Analytics 4 property. + static void sampleRunBatchReport(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + + BatchRunReportsRequest request = + BatchRunReportsRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addRequests( + RunReportRequest.newBuilder() + .addDimensions(Dimension.newBuilder().setName("country")) + .addDimensions(Dimension.newBuilder().setName("region")) + .addDimensions(Dimension.newBuilder().setName("city")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addDateRanges( + DateRange.newBuilder() + .setStartDate("2021-01-03") + .setEndDate("2021-01-09"))) + .addRequests( + RunReportRequest.newBuilder() + .addDimensions(Dimension.newBuilder().setName("browser")) + .addMetrics(Metric.newBuilder().setName("activeUsers")) + .addDateRanges( + DateRange.newBuilder() + .setStartDate("2021-01-01") + .setEndDate("2021-01-31"))) + .build(); + + // Make the request. + BatchRunReportsResponse response = analyticsData.batchRunReports(request); + + // Prints the response using a method in RunReportSample.java + System.out.println("Batch report results:"); + for (RunReportResponse report : response.getReportsList()) { + RunReportSample.printRunResponseResponse(report); + } + } + } +} +// [END analyticsdata_run_batch_report] diff --git a/samples/snippets/src/main/java/com/example/analytics/RunPivotReportSample.java b/samples/snippets/src/main/java/com/example/analytics/RunPivotReportSample.java new file mode 100644 index 00000000..9170d18e --- /dev/null +++ b/samples/snippets/src/main/java/com/example/analytics/RunPivotReportSample.java @@ -0,0 +1,114 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +/* Google Analytics Data API sample application demonstrating the creation of +a pivot report. + +See +https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties/runPivotReport +for more information. + +Before you start the application, please review the comments starting with +"TODO(developer)" and update the code to use correct values. + +To run this sample using Maven: + cd java-analytics-data/samples/snippets + mvn compile + mvn exec:java -Dexec.mainClass="com.example.analytics.RunPivotReportSample" + */ + +// [START analyticsdata_run_pivot_report] + +import com.google.analytics.data.v1beta.BetaAnalyticsDataClient; +import com.google.analytics.data.v1beta.DateRange; +import com.google.analytics.data.v1beta.Dimension; +import com.google.analytics.data.v1beta.DimensionValue; +import com.google.analytics.data.v1beta.Metric; +import com.google.analytics.data.v1beta.MetricValue; +import com.google.analytics.data.v1beta.OrderBy; +import com.google.analytics.data.v1beta.Pivot; +import com.google.analytics.data.v1beta.Row; +import com.google.analytics.data.v1beta.RunPivotReportRequest; +import com.google.analytics.data.v1beta.RunPivotReportResponse; + +public class RunPivotReportSample { + + public static void main(String... args) throws Exception { + // TODO(developer): Replace with your Google Analytics 4 property ID before running the sample. + String propertyId = "YOUR-GA4-PROPERTY-ID"; + sampleRunPivotReport(propertyId); + } + + // Runs a pivot query to build a report of session counts by country, pivoted by the browser + // dimension + static void sampleRunPivotReport(String propertyId) throws Exception { + // Initialize client that will be used to send requests. This client only needs to be created + // once, and can be reused for multiple requests. After completing all of your requests, call + // the "close" method on the client to safely clean up any remaining background resources. + try (BetaAnalyticsDataClient analyticsData = BetaAnalyticsDataClient.create()) { + RunPivotReportRequest request = + RunPivotReportRequest.newBuilder() + .setProperty("properties/" + propertyId) + .addDateRanges( + DateRange.newBuilder().setStartDate("2021-01-01").setEndDate("2021-01-30")) + .addPivots( + Pivot.newBuilder() + .addFieldNames("country") + .setLimit(250) + .addOrderBys( + OrderBy.newBuilder() + .setDimension( + OrderBy.DimensionOrderBy.newBuilder() + .setDimensionName("country")))) + .addPivots( + Pivot.newBuilder() + .addFieldNames("browser") + .setOffset(3) + .setLimit(3) + .addOrderBys( + OrderBy.newBuilder() + .setMetric( + OrderBy.MetricOrderBy.newBuilder().setMetricName("sessions")) + .setDesc(true))) + .addMetrics(Metric.newBuilder().setName("sessions")) + .addDimensions(Dimension.newBuilder().setName("country")) + .addDimensions(Dimension.newBuilder().setName("browser")) + .build(); + + // Make the request. + RunPivotReportResponse response = analyticsData.runPivotReport(request); + printRunPivotReportResponse(response); + } + } + + // Prints results of a runPivotReport call. + static void printRunPivotReportResponse(RunPivotReportResponse response) { + // [START analyticsdata_print_run_pivot_report_response] + System.out.println("Report result:"); + for (Row row : response.getRowsList()) { + for (DimensionValue dimensionValue : row.getDimensionValuesList()) { + System.out.println(dimensionValue.getValue()); + } + for (MetricValue metricValue : row.getMetricValuesList()) { + System.out.println(metricValue.getValue()); + } + } + // [END analyticsdata_print_run_pivot_report_response] + } +} +// [END analyticsdata_run_pivot_report] diff --git a/samples/snippets/src/test/java/com/example/analytics/RunBatchReportSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/RunBatchReportSampleTest.java new file mode 100644 index 00000000..d029a05e --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunBatchReportSampleTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunBatchReport sample. */ +@RunWith(JUnit4.class) +public class RunBatchReportSampleTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunBatchReportSample.sampleRunBatchReport(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunBatchReport() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Batch report result"); + } +} diff --git a/samples/snippets/src/test/java/com/example/analytics/RunPivotReportSampleTest.java b/samples/snippets/src/test/java/com/example/analytics/RunPivotReportSampleTest.java new file mode 100644 index 00000000..6c422c7c --- /dev/null +++ b/samples/snippets/src/test/java/com/example/analytics/RunPivotReportSampleTest.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 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. + */ + +package com.example.analytics; + +import static com.google.common.truth.Truth.assertThat; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +/** Tests for the RunPivotReport sample. */ +@RunWith(JUnit4.class) +public class RunPivotReportSampleTest { + + private String ga4PropertyId = + System.getProperty("analyticsdata.quickstart.ga4PropertyId", "222596558"); + + private String runSample(String ga4PropertyId) throws Exception { + PrintStream stdOut = System.out; + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + PrintStream out = new PrintStream(bout); + System.setOut(out); + + // Run the test using default system credentials. + RunPivotReportSample.sampleRunPivotReport(ga4PropertyId); + System.setOut(stdOut); + return bout.toString(); + } + + @Test + public void testRunPivotReport() throws Exception { + // Act + String out = runSample(ga4PropertyId); + + // Assert + assertThat(out).contains("Report result:"); + } +} From f885083c94af5ab4a9079d74021a6ce536bdc688 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Thu, 19 May 2022 15:00:17 +0000 Subject: [PATCH 17/21] chore(main): release 0.11.11-SNAPSHOT (#494) :robot: I have created a release *beep* *boop* --- ### Updating meta-information for bleeding-edge SNAPSHOT release. --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- google-analytics-data-bom/pom.xml | 12 ++++++------ google-analytics-data/pom.xml | 4 ++-- grpc-google-analytics-data-v1alpha/pom.xml | 4 ++-- grpc-google-analytics-data-v1beta/pom.xml | 4 ++-- pom.xml | 12 ++++++------ proto-google-analytics-data-v1alpha/pom.xml | 4 ++-- proto-google-analytics-data-v1beta/pom.xml | 4 ++-- samples/snapshot/pom.xml | 2 +- versions.txt | 10 +++++----- 9 files changed, 28 insertions(+), 28 deletions(-) diff --git a/google-analytics-data-bom/pom.xml b/google-analytics-data-bom/pom.xml index cee94a05..9e53f41d 100644 --- a/google-analytics-data-bom/pom.xml +++ b/google-analytics-data-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.analytics google-analytics-data-bom - 0.11.10 + 0.11.11-SNAPSHOT pom com.google.cloud @@ -56,27 +56,27 @@ com.google.analytics google-analytics-data - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc grpc-google-analytics-data-v1beta - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc grpc-google-analytics-data-v1alpha - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc proto-google-analytics-data-v1beta - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc proto-google-analytics-data-v1alpha - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/google-analytics-data/pom.xml b/google-analytics-data/pom.xml index ae68608d..a96a6fba 100644 --- a/google-analytics-data/pom.xml +++ b/google-analytics-data/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.analytics google-analytics-data - 0.11.10 + 0.11.11-SNAPSHOT jar Google Analytics Data https://github.com/googleapis/java-analytics-data @@ -11,7 +11,7 @@ com.google.analytics google-analytics-data-parent - 0.11.10 + 0.11.11-SNAPSHOT google-analytics-data diff --git a/grpc-google-analytics-data-v1alpha/pom.xml b/grpc-google-analytics-data-v1alpha/pom.xml index 921a9180..112ee641 100644 --- a/grpc-google-analytics-data-v1alpha/pom.xml +++ b/grpc-google-analytics-data-v1alpha/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-analytics-data-v1alpha - 0.11.10 + 0.11.11-SNAPSHOT grpc-google-analytics-data-v1alpha GRPC library for google-analytics-data com.google.analytics google-analytics-data-parent - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/grpc-google-analytics-data-v1beta/pom.xml b/grpc-google-analytics-data-v1beta/pom.xml index 42ef8430..0acb27d7 100644 --- a/grpc-google-analytics-data-v1beta/pom.xml +++ b/grpc-google-analytics-data-v1beta/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-analytics-data-v1beta - 0.11.10 + 0.11.11-SNAPSHOT grpc-google-analytics-data-v1beta GRPC library for grpc-google-analytics-data-v1beta com.google.analytics google-analytics-data-parent - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/pom.xml b/pom.xml index 7c72eb5e..c0f466fa 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.analytics google-analytics-data-parent pom - 0.11.10 + 0.11.11-SNAPSHOT Google Analytics Data Parent https://github.com/googleapis/java-analytics-data @@ -61,27 +61,27 @@ com.google.analytics google-analytics-data - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc proto-google-analytics-data-v1alpha - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc grpc-google-analytics-data-v1alpha - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc proto-google-analytics-data-v1beta - 0.11.10 + 0.11.11-SNAPSHOT com.google.api.grpc grpc-google-analytics-data-v1beta - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/proto-google-analytics-data-v1alpha/pom.xml b/proto-google-analytics-data-v1alpha/pom.xml index 99eeea6d..6beef72c 100644 --- a/proto-google-analytics-data-v1alpha/pom.xml +++ b/proto-google-analytics-data-v1alpha/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-analytics-data-v1alpha - 0.11.10 + 0.11.11-SNAPSHOT proto-google-analytics-data-v1alpha Proto library for google-analytics-data com.google.analytics google-analytics-data-parent - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/proto-google-analytics-data-v1beta/pom.xml b/proto-google-analytics-data-v1beta/pom.xml index f965f54e..2b03c6f4 100644 --- a/proto-google-analytics-data-v1beta/pom.xml +++ b/proto-google-analytics-data-v1beta/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-analytics-data-v1beta - 0.11.10 + 0.11.11-SNAPSHOT proto-google-analytics-data-v1beta PROTO library for proto-google-analytics-data-v1beta com.google.analytics google-analytics-data-parent - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index c2122821..75185d0b 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -40,7 +40,7 @@ com.google.analytics google-analytics-data - 0.11.10 + 0.11.11-SNAPSHOT diff --git a/versions.txt b/versions.txt index 9d8530da..d60db8e9 100644 --- a/versions.txt +++ b/versions.txt @@ -1,8 +1,8 @@ # Format: # module:released-version:current-version -google-analytics-data:0.11.10:0.11.10 -grpc-google-analytics-data-v1beta:0.11.10:0.11.10 -proto-google-analytics-data-v1beta:0.11.10:0.11.10 -proto-google-analytics-data-v1alpha:0.11.10:0.11.10 -grpc-google-analytics-data-v1alpha:0.11.10:0.11.10 +google-analytics-data:0.11.10:0.11.11-SNAPSHOT +grpc-google-analytics-data-v1beta:0.11.10:0.11.11-SNAPSHOT +proto-google-analytics-data-v1beta:0.11.10:0.11.11-SNAPSHOT +proto-google-analytics-data-v1alpha:0.11.10:0.11.11-SNAPSHOT +grpc-google-analytics-data-v1alpha:0.11.10:0.11.11-SNAPSHOT From 964ce12c5a663cf5a754a1899a1e5501d81d01d9 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 19 May 2022 17:13:11 +0200 Subject: [PATCH 18/21] chore(deps): update dependency com.google.cloud:libraries-bom to v25.3.0 (#491) --- samples/snapshot/pom.xml | 2 +- samples/snippets/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index 75185d0b..f9461f19 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -28,7 +28,7 @@ com.google.cloud libraries-bom - 25.2.0 + 25.3.0 pom import diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index f906f874..7081ec37 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -28,7 +28,7 @@ com.google.cloud libraries-bom - 25.2.0 + 25.3.0 pom import From c09d6a3e7bba0ec26ac02e4d1ea928bd7ab64bcb Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 19 May 2022 17:14:13 +0200 Subject: [PATCH 19/21] deps: update dependency com.google.auth:google-auth-library-oauth2-http to v1.7.0 (#492) --- samples/install-without-bom/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml index 071d4296..220f484c 100644 --- a/samples/install-without-bom/pom.xml +++ b/samples/install-without-bom/pom.xml @@ -35,7 +35,7 @@ com.google.auth google-auth-library-oauth2-http - 1.6.0 + 1.7.0 From 5e5cc70bf5ae8d30061a46b50d37347b576650f7 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 19 May 2022 17:18:14 +0200 Subject: [PATCH 20/21] deps: update dependency com.google.cloud:google-cloud-shared-dependencies to v2.11.0 (#493) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-shared-dependencies](https://togithub.com/googleapis/java-shared-dependencies) | `2.10.0` -> `2.11.0` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/2.11.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/2.11.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/2.11.0/compatibility-slim/2.10.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/2.11.0/confidence-slim/2.10.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-shared-dependencies ### [`v2.11.0`](https://togithub.com/googleapis/java-shared-dependencies/blob/HEAD/CHANGELOG.md#​2110-httpsgithubcomgoogleapisjava-shared-dependenciescomparev2100v2110-2022-05-18) [Compare Source](https://togithub.com/googleapis/java-shared-dependencies/compare/v2.10.0...v2.11.0) ##### Features - next release from main branch is 2.11.0 ([#​674](https://togithub.com/googleapis/java-shared-dependencies/issues/674)) ([611e3b7](https://togithub.com/googleapis/java-shared-dependencies/commit/611e3b7c50108a71efc94415166b85d2bf8647e5)) ##### Dependencies - update dependency com.fasterxml.jackson:jackson-bom to v2.13.3 ([#​689](https://togithub.com/googleapis/java-shared-dependencies/issues/689)) ([03897e3](https://togithub.com/googleapis/java-shared-dependencies/commit/03897e30a71f8f1aa37233da2433ee5afccc1d61)) - update dependency com.google.api-client:google-api-client-bom to v1.34.1 ([#​685](https://togithub.com/googleapis/java-shared-dependencies/issues/685)) ([9bc0557](https://togithub.com/googleapis/java-shared-dependencies/commit/9bc0557d8ce2f3d8dc7c8ffafdd36fd4c03e2df5)) - update dependency com.google.api:api-common to v2.2.0 ([#​690](https://togithub.com/googleapis/java-shared-dependencies/issues/690)) ([47a8736](https://togithub.com/googleapis/java-shared-dependencies/commit/47a87365e51f73132b15b054d85f8c9baa8e89f6)) - update dependency com.google.auth:google-auth-library-bom to v1.7.0 ([#​691](https://togithub.com/googleapis/java-shared-dependencies/issues/691)) ([ec6aab7](https://togithub.com/googleapis/java-shared-dependencies/commit/ec6aab72eaed43574efe47a696bba6a612f161bb)) - update dependency com.google.errorprone:error_prone_annotations to v2.13.1 ([#​672](https://togithub.com/googleapis/java-shared-dependencies/issues/672)) ([8c7e530](https://togithub.com/googleapis/java-shared-dependencies/commit/8c7e530d3c7170b2fb76cc27a05164524ba4e00b)) - update dependency com.google.http-client:google-http-client-bom to v1.41.8 ([#​684](https://togithub.com/googleapis/java-shared-dependencies/issues/684)) ([1305356](https://togithub.com/googleapis/java-shared-dependencies/commit/1305356775247dbb641b60654ac56da43513088e)) - update dependency com.google.protobuf:protobuf-bom to v3.20.1 ([#​678](https://togithub.com/googleapis/java-shared-dependencies/issues/678)) ([3e6d4a1](https://togithub.com/googleapis/java-shared-dependencies/commit/3e6d4a1a8e5d45723071a62c99bb1ab87d2b2b84)) - update dependency io.grpc:grpc-bom to v1.46.0 ([#​680](https://togithub.com/googleapis/java-shared-dependencies/issues/680)) ([b8a052b](https://togithub.com/googleapis/java-shared-dependencies/commit/b8a052b75a1bc2703500b4f31c5c6dac887ab8be)) - update dependency org.checkerframework:checker-qual to v3.22.0 ([#​683](https://togithub.com/googleapis/java-shared-dependencies/issues/683)) ([b0a30cd](https://togithub.com/googleapis/java-shared-dependencies/commit/b0a30cdecae8dcfb3a6d36e3f194c39a0086673e)) - update gax.version to v2.17.0 ([#​687](https://togithub.com/googleapis/java-shared-dependencies/issues/687)) ([e0e89ea](https://togithub.com/googleapis/java-shared-dependencies/commit/e0e89eade481effc723c9c7261f2ebf4e5883621)) - update gax.version to v2.18.0 ([#​692](https://togithub.com/googleapis/java-shared-dependencies/issues/692)) ([9536612](https://togithub.com/googleapis/java-shared-dependencies/commit/9536612c77af1e4d912c5b63515ea6f750e53810)) - update google.core.version to v2.6.1 ([#​671](https://togithub.com/googleapis/java-shared-dependencies/issues/671)) ([e3d1aeb](https://togithub.com/googleapis/java-shared-dependencies/commit/e3d1aebed31f8e91109d5865afd9525ac3595c90)) - update google.core.version to v2.7.0 ([#​693](https://togithub.com/googleapis/java-shared-dependencies/issues/693)) ([2171677](https://togithub.com/googleapis/java-shared-dependencies/commit/2171677e16190de9f37dc16c924d829ea8ccd86c)) - update iam.version to v1.3.2 ([#​673](https://togithub.com/googleapis/java-shared-dependencies/issues/673)) ([9882baa](https://togithub.com/googleapis/java-shared-dependencies/commit/9882baa3ecc8d7584788af1916f0d8c5ec670b5c)) - update iam.version to v1.3.3 ([#​679](https://togithub.com/googleapis/java-shared-dependencies/issues/679)) ([9fe34c8](https://togithub.com/googleapis/java-shared-dependencies/commit/9fe34c89eabed5eeebad986bffeeeb64dbbc38c1)) - update iam.version to v1.3.4 ([#​686](https://togithub.com/googleapis/java-shared-dependencies/issues/686)) ([4e95b3a](https://togithub.com/googleapis/java-shared-dependencies/commit/4e95b3a1d4302812338c220df316391c19ef7473)) - update opencensus.version to v0.31.1 ([#​682](https://togithub.com/googleapis/java-shared-dependencies/issues/682)) ([5d25746](https://togithub.com/googleapis/java-shared-dependencies/commit/5d25746bc6c9329b240204cbe7b83e2fee4c6cb3))
--- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-analytics-data). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index c0f466fa..8bad0041 100644 --- a/pom.xml +++ b/pom.xml @@ -87,7 +87,7 @@ com.google.cloud google-cloud-shared-dependencies - 2.10.0 + 2.11.0 pom import From 61db1a99d03bc98c3e83d96ee0cfc1f55bfd0bdd Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Thu, 19 May 2022 15:28:11 +0000 Subject: [PATCH 21/21] chore(main): release 0.12.0 (#495) :robot: I have created a release *beep* *boop* --- ## [0.12.0](https://github.com/googleapis/java-analytics-data/compare/v0.11.10...v0.12.0) (2022-05-19) ### Features * add `runFunnelReport` method to the Alpha version of the Data API ([#490](https://github.com/googleapis/java-analytics-data/issues/490)) ([1969fee](https://github.com/googleapis/java-analytics-data/commit/1969feecac73306525a79e39b7098fdb2a5a05d2)) ### Dependencies * update dependency com.google.auth:google-auth-library-oauth2-http to v1.7.0 ([#492](https://github.com/googleapis/java-analytics-data/issues/492)) ([c09d6a3](https://github.com/googleapis/java-analytics-data/commit/c09d6a3e7bba0ec26ac02e4d1ea928bd7ab64bcb)) * update dependency com.google.cloud:google-cloud-shared-dependencies to v2.11.0 ([#493](https://github.com/googleapis/java-analytics-data/issues/493)) ([5e5cc70](https://github.com/googleapis/java-analytics-data/commit/5e5cc70bf5ae8d30061a46b50d37347b576650f7)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 13 +++++++++++++ google-analytics-data-bom/pom.xml | 12 ++++++------ google-analytics-data/pom.xml | 4 ++-- grpc-google-analytics-data-v1alpha/pom.xml | 4 ++-- grpc-google-analytics-data-v1beta/pom.xml | 4 ++-- pom.xml | 12 ++++++------ proto-google-analytics-data-v1alpha/pom.xml | 4 ++-- proto-google-analytics-data-v1beta/pom.xml | 4 ++-- samples/snapshot/pom.xml | 2 +- versions.txt | 10 +++++----- 10 files changed, 41 insertions(+), 28 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6d15450b..c3b6551a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,18 @@ # Changelog +## [0.12.0](https://github.com/googleapis/java-analytics-data/compare/v0.11.10...v0.12.0) (2022-05-19) + + +### Features + +* add `runFunnelReport` method to the Alpha version of the Data API ([#490](https://github.com/googleapis/java-analytics-data/issues/490)) ([1969fee](https://github.com/googleapis/java-analytics-data/commit/1969feecac73306525a79e39b7098fdb2a5a05d2)) + + +### Dependencies + +* update dependency com.google.auth:google-auth-library-oauth2-http to v1.7.0 ([#492](https://github.com/googleapis/java-analytics-data/issues/492)) ([c09d6a3](https://github.com/googleapis/java-analytics-data/commit/c09d6a3e7bba0ec26ac02e4d1ea928bd7ab64bcb)) +* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.11.0 ([#493](https://github.com/googleapis/java-analytics-data/issues/493)) ([5e5cc70](https://github.com/googleapis/java-analytics-data/commit/5e5cc70bf5ae8d30061a46b50d37347b576650f7)) + ### [0.11.10](https://github.com/googleapis/java-analytics-data/compare/v0.11.9...v0.11.10) (2022-04-15) diff --git a/google-analytics-data-bom/pom.xml b/google-analytics-data-bom/pom.xml index 9e53f41d..242e9f13 100644 --- a/google-analytics-data-bom/pom.xml +++ b/google-analytics-data-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.analytics google-analytics-data-bom - 0.11.11-SNAPSHOT + 0.12.0 pom com.google.cloud @@ -56,27 +56,27 @@ com.google.analytics google-analytics-data - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc grpc-google-analytics-data-v1beta - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc grpc-google-analytics-data-v1alpha - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc proto-google-analytics-data-v1beta - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc proto-google-analytics-data-v1alpha - 0.11.11-SNAPSHOT + 0.12.0
diff --git a/google-analytics-data/pom.xml b/google-analytics-data/pom.xml index a96a6fba..f57c591f 100644 --- a/google-analytics-data/pom.xml +++ b/google-analytics-data/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.analytics google-analytics-data - 0.11.11-SNAPSHOT + 0.12.0 jar Google Analytics Data https://github.com/googleapis/java-analytics-data @@ -11,7 +11,7 @@ com.google.analytics google-analytics-data-parent - 0.11.11-SNAPSHOT + 0.12.0 google-analytics-data diff --git a/grpc-google-analytics-data-v1alpha/pom.xml b/grpc-google-analytics-data-v1alpha/pom.xml index 112ee641..faa46e55 100644 --- a/grpc-google-analytics-data-v1alpha/pom.xml +++ b/grpc-google-analytics-data-v1alpha/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-analytics-data-v1alpha - 0.11.11-SNAPSHOT + 0.12.0 grpc-google-analytics-data-v1alpha GRPC library for google-analytics-data com.google.analytics google-analytics-data-parent - 0.11.11-SNAPSHOT + 0.12.0 diff --git a/grpc-google-analytics-data-v1beta/pom.xml b/grpc-google-analytics-data-v1beta/pom.xml index 0acb27d7..630bc699 100644 --- a/grpc-google-analytics-data-v1beta/pom.xml +++ b/grpc-google-analytics-data-v1beta/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-analytics-data-v1beta - 0.11.11-SNAPSHOT + 0.12.0 grpc-google-analytics-data-v1beta GRPC library for grpc-google-analytics-data-v1beta com.google.analytics google-analytics-data-parent - 0.11.11-SNAPSHOT + 0.12.0 diff --git a/pom.xml b/pom.xml index 8bad0041..dea69757 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.analytics google-analytics-data-parent pom - 0.11.11-SNAPSHOT + 0.12.0 Google Analytics Data Parent https://github.com/googleapis/java-analytics-data @@ -61,27 +61,27 @@ com.google.analytics google-analytics-data - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc proto-google-analytics-data-v1alpha - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc grpc-google-analytics-data-v1alpha - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc proto-google-analytics-data-v1beta - 0.11.11-SNAPSHOT + 0.12.0 com.google.api.grpc grpc-google-analytics-data-v1beta - 0.11.11-SNAPSHOT + 0.12.0 diff --git a/proto-google-analytics-data-v1alpha/pom.xml b/proto-google-analytics-data-v1alpha/pom.xml index 6beef72c..c7cc06d2 100644 --- a/proto-google-analytics-data-v1alpha/pom.xml +++ b/proto-google-analytics-data-v1alpha/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-analytics-data-v1alpha - 0.11.11-SNAPSHOT + 0.12.0 proto-google-analytics-data-v1alpha Proto library for google-analytics-data com.google.analytics google-analytics-data-parent - 0.11.11-SNAPSHOT + 0.12.0 diff --git a/proto-google-analytics-data-v1beta/pom.xml b/proto-google-analytics-data-v1beta/pom.xml index 2b03c6f4..fa5818d2 100644 --- a/proto-google-analytics-data-v1beta/pom.xml +++ b/proto-google-analytics-data-v1beta/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-analytics-data-v1beta - 0.11.11-SNAPSHOT + 0.12.0 proto-google-analytics-data-v1beta PROTO library for proto-google-analytics-data-v1beta com.google.analytics google-analytics-data-parent - 0.11.11-SNAPSHOT + 0.12.0 diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index f9461f19..919f440a 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -40,7 +40,7 @@ com.google.analytics google-analytics-data - 0.11.11-SNAPSHOT + 0.12.0 diff --git a/versions.txt b/versions.txt index d60db8e9..07efafa6 100644 --- a/versions.txt +++ b/versions.txt @@ -1,8 +1,8 @@ # Format: # module:released-version:current-version -google-analytics-data:0.11.10:0.11.11-SNAPSHOT -grpc-google-analytics-data-v1beta:0.11.10:0.11.11-SNAPSHOT -proto-google-analytics-data-v1beta:0.11.10:0.11.11-SNAPSHOT -proto-google-analytics-data-v1alpha:0.11.10:0.11.11-SNAPSHOT -grpc-google-analytics-data-v1alpha:0.11.10:0.11.11-SNAPSHOT +google-analytics-data:0.12.0:0.12.0 +grpc-google-analytics-data-v1beta:0.12.0:0.12.0 +proto-google-analytics-data-v1beta:0.12.0:0.12.0 +proto-google-analytics-data-v1alpha:0.12.0:0.12.0 +grpc-google-analytics-data-v1alpha:0.12.0:0.12.0